use of io.druid.segment.data.BitmapCompressedIndexedInts in project druid by druid-io.
the class QueryableIndexIndexableAdapter method getBitmapIndex.
@Override
public IndexedInts getBitmapIndex(String dimension, int dictId) {
final Column column = input.getColumn(dimension);
if (column == null) {
return EmptyIndexedInts.EMPTY_INDEXED_INTS;
}
final BitmapIndex bitmaps = column.getBitmapIndex();
if (bitmaps == null) {
return EmptyIndexedInts.EMPTY_INDEXED_INTS;
}
if (dictId >= 0) {
return new BitmapCompressedIndexedInts(bitmaps.getBitmap(dictId));
} else {
return EmptyIndexedInts.EMPTY_INDEXED_INTS;
}
}
use of io.druid.segment.data.BitmapCompressedIndexedInts in project druid by druid-io.
the class QueryableIndexIndexableAdapter method getBitmapIndex.
@VisibleForTesting
IndexedInts getBitmapIndex(String dimension, String value) {
final Column column = input.getColumn(dimension);
if (column == null) {
return EmptyIndexedInts.EMPTY_INDEXED_INTS;
}
final BitmapIndex bitmaps = column.getBitmapIndex();
if (bitmaps == null) {
return EmptyIndexedInts.EMPTY_INDEXED_INTS;
}
return new BitmapCompressedIndexedInts(bitmaps.getBitmap(bitmaps.getIndex(value)));
}
Aggregations