public class ImmutableFixedLengthBitSet
extends java.lang.Object
BitSet
with fixed length. Objects
of this class are immutable.Constructor and Description |
---|
ImmutableFixedLengthBitSet(int length)
Constructs a new
ImmutableFixedLengthBitSet for the given length. |
Modifier and Type | Method and Description |
---|---|
java.util.ArrayList<java.lang.Integer> |
getNonzeroPositions() |
int |
getNumOfZeroBits() |
int |
getValue() |
ImmutableFixedLengthBitSet |
inc()
Returns a new
ImmutableFixedLengthBitSet with a value incremented
by one compared to this ImmutableFixedLengthBitSet . |
ImmutableFixedLengthBitSet |
setToValue(int value)
Sets this
ImmutableFixedLengthBitSet to the given value. |
java.lang.String |
toString() |
public ImmutableFixedLengthBitSet(int length)
ImmutableFixedLengthBitSet
for the given length.
All bits are set to zero (so the ImmutableFixedLengthBitSet
represents the number 0).length
- The length of the new ImmutableFixedLengthBitSet
.public int getValue()
ImmutableFixedLengthBitSet
.public ImmutableFixedLengthBitSet setToValue(int value)
ImmutableFixedLengthBitSet
to the given value.value
- Value to set the ImmutableFixedLengthBitSet
to.public ImmutableFixedLengthBitSet inc()
ImmutableFixedLengthBitSet
with a value incremented
by one compared to this ImmutableFixedLengthBitSet
.public int getNumOfZeroBits()
ImmutableFixedLengthBitSet
set
to zero.public java.util.ArrayList<java.lang.Integer> getNonzeroPositions()
ImmutableFixedLengthBitSet
.public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2003-2019 The KeY-Project.