java.lang.Object
com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.VarSrc

@Ser public class VarSrc extends Object
Variable-source object, that is, specify the variable(s) behind a variable-copy. A copy may be a duplicate, a pair, or a slice.
  • Method Details

    • toString

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

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

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

      public static VarSrc dup(int srcid)
    • pair

      public static VarSrc pair(int srcidLo, int srcidHi)
    • slice

      public static VarSrc slice(int srcid, int bitbegin, Integer bitend)
    • truncated

      public static VarSrc truncated(int srcid, int bitplit)
    • getSource

      public List<VarSrc.E> getSource()
    • isDuplicate

      public boolean isDuplicate()
    • getAsDuplicate

      public int getAsDuplicate()
    • isPair

      public boolean isPair()
      special case of merge: 2 elements
    • getAsPair

      public Couple<Integer,Integer> getAsPair()
      Returns:
      a tuple (src_id_lo, src_id_hi)
    • isSlice

      public boolean isSlice()
    • getAsSlice

      public Couple<Integer,Couple<Integer,Integer>> getAsSlice()
      Returns:
      a tuple (src_id, (bitbegin, bitend))
    • isTruncated

      public boolean isTruncated()
      special case of slice: [0, x)
    • getAsTruncated

      public Couple<Integer,Integer> getAsTruncated()
      Returns:
      a tuple (src_id, bitsize)
    • containsSourceId

      public boolean containsSourceId(int id)
    • collectSourceIds

      public void collectSourceIds(Collection<Integer> sink)
    • getSourceIds

      public List<Integer> getSourceIds()
    • collectSourceIds

      public void collectSourceIds(Collection<Integer> sink, Collection<Integer> exclusions)
      Parameters:
      sink -
      exclusions - optional