Java源码示例:org.apache.calcite.schema.Statistics

示例1
private Statistic buildStatistic() {
  if (stats != null || primaryKey == -1) {
    return stats;
  }
  Direction dir = primaryKeyMonotonicity == INCREASING ? ASCENDING : DESCENDING;
  RelFieldCollation collation = new RelFieldCollation(primaryKey, dir, NullDirection.UNSPECIFIED);
  return Statistics.of(fields.size(), ImmutableList.of(ImmutableBitSet.of(primaryKey)),
      ImmutableList.of(RelCollations.of(collation)));
}
 
示例2
@Override
public Statistic getStatistic() {
    int counter = 0;
    for (IThreadStack threadStack : getThreadStacks()) {
        counter += threadStack.getStackFrames().length;
    }
    return Statistics.of(counter, ImmutableList.of(ImmutableBitSet.of(0, 1)));
}
 
示例3
public Statistic getStatistic() {
  final List<ImmutableBitSet> keys = new ArrayList<>();
  final Content content = supplier.get();
  for (Ord<Column> ord : Ord.zip(content.columns)) {
    if (ord.e.cardinality == content.size) {
      keys.add(ImmutableBitSet.of(ord.i));
    }
  }
  return Statistics.of(content.size, keys, content.collations);
}
 
示例4
@Override public Statistic getStatistic() {
  List<RelFieldCollation> collationFields = new ArrayList<>();
  for (Integer key : pkColumns) {
    collationFields.add(
        new RelFieldCollation(
            key,
            RelFieldCollation.Direction.ASCENDING,
            RelFieldCollation.NullDirection.LAST));
  }
  return Statistics.of(data.size(), ImmutableList.of(pkColumns),
      ImmutableList.of(RelCollations.of(collationFields)));
}
 
示例5
public Statistic getStatistic() {
  return Statistics.UNKNOWN;
}
 
示例6
@Override
public Statistic getStatistic() {
  return Statistics.UNKNOWN;
}
 
示例7
@Override
public Statistic getStatistic() {
  return Statistics.UNKNOWN;
}
 
示例8
@Override
public Statistic getStatistic() {
    List<ImmutableBitSet> keys = new ArrayList<ImmutableBitSet>();
    return Statistics.of(100, keys);
}
 
示例9
@Override
public Statistic getStatistic() {
    return Statistics.UNKNOWN;
}
 
示例10
public Statistic getStatistic() {
  return Statistics.UNKNOWN;
}
 
示例11
FieldTable(Field field, Type elementType, Supplier< Enumerable> enumerable) {
  this(field, elementType, enumerable, Statistics.UNKNOWN);
}
 
示例12
@Override
public Statistic getStatistic() {
  return Statistics.UNKNOWN;
}
 
示例13
@Override
public Statistic getStatistic() {
    return Statistics.of(tableManager.getStats().getTablesize(),
            keys);
}
 
示例14
@Override
public Statistic getStatistic()
{
  return Statistics.of(100d, ImmutableList.<ImmutableBitSet>of(), RelCollations.createSingleton(0));
}
 
示例15
public Statistic getStatistic() {
  return Statistics.of(0d, ImmutableList.<ImmutableBitSet>of());
}
 
示例16
public Statistic getStatistic() {
  return Statistics.of(0d, ImmutableList.<ImmutableBitSet>of());
}
 
示例17
@Override
public Statistic getStatistic() {
    List<ImmutableBitSet> keys = new ArrayList<ImmutableBitSet>();
    return Statistics.of(100, keys);
}
 
示例18
@Override
public Statistic getStatistic() {
    return Statistics.of(values.size(), unique ? UNIQUE_KEYS_STATISTICS : NON_UNIQUE_KEYS_STATISTICS);
}
 
示例19
@Override
public Statistic getStatistic() {
    List<ImmutableBitSet> uniqueKeys = ImmutableList.of(ImmutableBitSet.of(0));
    return Statistics.of(classesList.getTotalObjects(), uniqueKeys);
}
 
示例20
@Override
public Statistic getStatistic() {
    List<ImmutableBitSet> uniqueKeys = ImmutableList.of(ImmutableBitSet.of(0));
    return Statistics.of(classesList.getTotalObjects(), uniqueKeys);
}
 
示例21
@Override
public Statistic getStatistic() {
    return Statistics.of(references.size(), NON_UNIQUE_KEYS_STATISTICS);
}
 
示例22
public Statistic getStatistic() {
  return Statistics.UNKNOWN;
}
 
示例23
public Statistic getStatistic() {
  return Statistics.UNKNOWN;
}
 
示例24
public Statistic getStatistic() {
  return Statistics.UNKNOWN;
}
 
示例25
FieldTable(Field field, Type elementType, Enumerable<T> enumerable) {
  this(field, elementType, enumerable, Statistics.UNKNOWN);
}
 
示例26
public Statistic getStatistic() {
  return Statistics.of(list.size(), ImmutableList.of());
}
 
示例27
public Statistic getStatistic() {
  return Statistics.UNKNOWN;
}
 
示例28
public Statistic getStatistic() {
  return Statistics.of(15D,
      ImmutableList.of(ImmutableBitSet.of(0)),
      ImmutableList.of());
}
 
示例29
public Statistic getStatistic() {
  return Statistics.of(100d, ImmutableList.of(),
    RelCollations.createSingleton(0));
}
 
示例30
public Statistic getStatistic() {
  return Statistics.of(200d, ImmutableList.of());
}