Class BitSetBitmapFactory
java.lang.Object
org.apache.druid.collections.bitmap.BitSetBitmapFactory
- All Implemented Interfaces:
BitmapFactory
BitSetBitmapFactory implements BitmapFactory as a wrapper for java.util.BitSet
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncomplement(ImmutableBitmap b, int length) Compute the intersection (bitwise-AND) of a set of bitmaps.Create a new empty bitmapmakeImmutableBitmap(MutableBitmap mutableBitmap) Given a ByteBuffer pointing at a serialized version of a bitmap, instantiate an immutable mapped bitmap.Compute the union (bitwise-OR) of a set of bitmaps.
-
Constructor Details
-
BitSetBitmapFactory
public BitSetBitmapFactory()
-
-
Method Details
-
makeEmptyMutableBitmap
Description copied from interface:BitmapFactoryCreate a new empty bitmap- Specified by:
makeEmptyMutableBitmapin interfaceBitmapFactory- Returns:
- the new bitmap
-
makeEmptyImmutableBitmap
- Specified by:
makeEmptyImmutableBitmapin interfaceBitmapFactory
-
makeImmutableBitmap
- Specified by:
makeImmutableBitmapin interfaceBitmapFactory
-
mapImmutableBitmap
Description copied from interface:BitmapFactoryGiven a ByteBuffer pointing at a serialized version of a bitmap, instantiate an immutable mapped bitmap. When using RoaringBitmap (with the RoaringBitmapFactory class), it is not necessary for b.limit() to indicate the end of the serialized content whereas it is critical to set b.limit() appropriately with ConciseSet (with the ConciseBitmapFactory).- Specified by:
mapImmutableBitmapin interfaceBitmapFactory- Parameters:
b- the input byte buffer- Returns:
- the new bitmap
-
union
Description copied from interface:BitmapFactoryCompute the union (bitwise-OR) of a set of bitmaps. They are assumed to be instances of of the proper WrappedConciseBitmap otherwise a ClassCastException is thrown.- Specified by:
unionin interfaceBitmapFactory- Parameters:
b- input ImmutableGenericBitmap objects- Returns:
- the union.
-
intersection
Description copied from interface:BitmapFactoryCompute the intersection (bitwise-AND) of a set of bitmaps. They are assumed to be instances of the proper WrappedConciseBitmap otherwise a ClassCastException is thrown.- Specified by:
intersectionin interfaceBitmapFactory- Parameters:
b- input ImmutableGenericBitmap objects- Returns:
- the union.
-
complement
- Specified by:
complementin interfaceBitmapFactory
-