Class BitVectorVariable

All Implemented Interfaces:
IVariable<BitVectorVariable>, INodeWithNumber

public class BitVectorVariable extends AbstractVariable<BitVectorVariable>
A bit vector variable for dataflow analysis.
  • Constructor Details

    • BitVectorVariable

      public BitVectorVariable()
  • Method Details

    • copyState

      public void copyState(@Nullable BitVectorVariable other)
      Description copied from interface: IVariable
      Set this variable to have the same state as another one
      See Also:
    • addAll

      public void addAll(BitVector B)
      Add all the bits in B to this bit vector
    • addAll

      public void addAll(BitVectorVariable other)
      Add all the bits from other to this bit vector
    • sameValue

      public boolean sameValue(BitVectorVariable other)
      Does this variable have the same value as another?
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • set

      public void set(int b)
      Set a particular bit
      Parameters:
      b - the bit to set
    • get

      public boolean get(int b)
      Is a particular bit set?
      Parameters:
      b - the bit to check
    • getValue

      public @Nullable IntSet getValue()
      Returns:
      the value of this variable as a bit vector ... null if the bit vector is empty.
    • clear

      public void clear(int i)
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class AbstractVariable<BitVectorVariable>
    • populationCount

      public int populationCount()