Interface ImmutableBitmap

All Known Subinterfaces:
MutableBitmap
All Known Implementing Classes:
WrappedBitSetBitmap, WrappedConciseBitmap, WrappedImmutableBitSetBitmap, WrappedImmutableConciseBitmap, WrappedImmutableRoaringBitmap, WrappedRoaringBitmap

public interface ImmutableBitmap
This class is meant to represent a simple wrapper around an immutable bitmap class.
  • Method Details

    • iterator

      org.roaringbitmap.IntIterator iterator()
      Returns:
      an iterator over the set bits of this bitmap
    • peekableIterator

      default org.roaringbitmap.PeekableIntIterator peekableIterator()
      Returns:
      a peekable iterator which can skip to a position
    • batchIterator

      default org.roaringbitmap.BatchIterator batchIterator()
      Returns:
      a batched iterator over the set bits of this bitmap
    • size

      int size()
      Returns:
      The number of bits set to true in this bitmap
    • toBytes

      byte[] toBytes()
    • isEmpty

      boolean isEmpty()
      Returns:
      True if this bitmap is empty (contains no set bit)
    • get

      boolean get(int value)
      Returns true if the bit at position value is set
      Parameters:
      value - the position to check
      Returns:
      true if bit is set
    • intersection

      ImmutableBitmap intersection(ImmutableBitmap otherBitmap)
      Compute the bitwise-and of this bitmap with another bitmap. A new bitmap is generated. Note that the other bitmap should be of the same class instance.
      Parameters:
      otherBitmap - other bitmap
    • union

      ImmutableBitmap union(ImmutableBitmap otherBitmap)
      Compute the bitwise-or of this bitmap with another bitmap. A new bitmap is generated. Note that the other bitmap should be of the same class instance.
      Parameters:
      otherBitmap - other bitmap