Class IdRanges

java.lang.Object
com.pnfsoftware.jeb.core.units.code.IdRanges

@Ser public class IdRanges extends Object
A collection of var-id ranges.
  • Constructor Details

    • IdRanges

      public IdRanges()
    • IdRanges

      public IdRanges(IdRanges o)
  • Method Details

    • clear

      public void clear()
    • bsize

      public int bsize()
    • size

      public int size()
      Provide the number of accessed variables.
    • isEmpty

      public boolean isEmpty()
    • remove

      public void remove(IVariable var)
    • remove

      public void remove(int varId)
    • addAll

      public void addAll(Collection<? extends IVariable> vars, Collection<? extends IVariable> exclusions)
    • addAll

      public void addAll(Collection<? extends IVariable> vars, IdRanges exclusions)
    • addAll

      public void addAll(Collection<? extends IVariable> vars)
    • add

      public void add(IVariable var)
    • add

      public void add(IVariable var, int beg, int len)
    • add

      public void add(int varid, int bitsize)
    • containsVarPart

      public boolean containsVarPart(IVariable var)
    • containsVarFull

      public boolean containsVarFull(int varid, int bitsize)
    • containsVarFull

      public boolean containsVarFull(int varid)
    • getVarIds

      public List<Integer> getVarIds()
      Generate a list (modifiable copy) containing the variable ids stored in this object. Not all variables may be accessed fully.
      Returns:
    • collectVarIds

      public void collectVarIds(Collection<Integer> r)
    • getBits

      public List<Integer> getBits()
    • collectBits

      public void collectBits(List<Integer> r)
    • intersection

      public IdRanges intersection(IdRanges other)
      Return common range between current range and the other range.
      Parameters:
      other - other range
      Returns:
      intersection
    • hasIntersection

      public boolean hasIntersection(IdRanges other)
      Check if there is common range between current range and the other range.
      Parameters:
      other - other range
      Returns:
      true if there is a non empty intersection
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object