Java.Util.BitSet Members

The members of Java.Util.BitSet are listed below.

See Also: Inherited members from Java.Lang.Object

Public Constructors

Creates a new BitSet with size equal to 64 bits.
Creates a new BitSet with size equal to bitCount, rounded up to a multiple of 64.

Protected Constructors

A constructor used when creating managed representations of JNI objects; called by the runtime.

Public Properties

[read-only]
IsEmptybool. Returns true if all the bits in this BitSet are set to false, false otherwise.

Protected Properties

[read-only]
override
ThresholdClassIntPtr. This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.
[read-only]
override
ThresholdTypeType. This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

Public Methods

And(BitSet)
Logically ands the bits of this BitSet with bs.
AndNot(BitSet)
Clears all bits in this BitSet which are also set in bs.
Cardinality() : int
Returns the number of bits that are true in this BitSet.
Clear()
Clears all the bits in this BitSet.
Clear(int)
Clears the bit at index index.
Clear(int, int)
Clears the range of bits [fromIndex, toIndex).
Clone() : Java.Lang.Object
Creates and returns a copy of this Object.
Flip(int)
Flips the bit at index index.
Flip(int, int)
Flips the range of bits [fromIndex, toIndex).
Get(int) : bool
Returns the bit at index index.
Get(int, int) : BitSet
Returns a new BitSet containing the range of bits [fromIndex, toIndex), shifted down so that the bit at fromIndex is at bit 0 in the new BitSet.
Intersects(BitSet) : bool
Returns true if this.and(bs) is non-empty, but may be faster than computing that.
Length() : int
Returns the number of bits up to and including the highest bit set.
NextClearBit(int) : int
Returns the index of the first bit that is clear on or after index.
NextSetBit(int) : int
Returns the index of the first bit that is set on or after index, or -1 if no higher bits are set.
Or(BitSet)
Logically ors the bits of this BitSet with bs.
PreviousClearBit(int) : int
Returns the index of the first bit that is clear on or before index, or -1 if no lower bits are clear or index == -1.
PreviousSetBit(int) : int
Returns the index of the first bit that is set on or before index, or -1 if no lower bits are set or index == -1.
Set(int)
Sets the bit at index index to true.
Set(int, bool)
Sets the bit at index index to state.
Set(int, int)
Sets the range of bits [fromIndex, toIndex).
Set(int, int, bool)
Sets the range of bits [fromIndex, toIndex) to state.
Size() : int
Returns the capacity in bits of the array implementing this BitSet.
ToByteArray() : byte[]
Returns a new byte[] containing a little-endian representation the bits of this BitSet, suitable for passing to valueOf to reconstruct this BitSet.
ToLongArray() : long[]
Returns a new long[] containing a little-endian representation of the bits of this BitSet, suitable for passing to valueOf to reconstruct this BitSet.
static
ValueOf(Java.Nio.ByteBuffer) : BitSet
Returns a BitSet corresponding to byteBuffer, interpreted as a little-endian sequence of bits.
static
ValueOf(Java.Nio.LongBuffer) : BitSet
Returns a BitSet corresponding to longBuffer, interpreted as a little-endian sequence of bits.
static
ValueOf(byte[]) : BitSet
Equivalent to BitSet.valueOf(ByteBuffer.wrap(bytes)).
static
ValueOf(long[]) : BitSet
Equivalent to BitSet.valueOf(LongBuffer.wrap(longs)), but likely to be faster.
Xor(BitSet)
Logically xors the bits of this BitSet with bs.