Class JNewMultiArrayExpr

java.lang.Object
sootup.core.jimple.common.expr.JNewMultiArrayExpr
All Implemented Interfaces:
EquivTo, Value, Expr, Acceptor<ExprVisitor>

public final class JNewMultiArrayExpr extends Object implements Expr
Like JNewArrayExpr, but for multi-dimensional arrays.
  • Constructor Details

    • JNewMultiArrayExpr

      public JNewMultiArrayExpr(@NonNull ArrayType type, @NonNull List<Immediate> sizes)
      Initiates a JNewMultiArrayExpr.
      Parameters:
      type - the type of the array
      sizes - the sizes
  • Method Details

    • equivTo

      public boolean equivTo(Object o, @NonNull JimpleComparator comparator)
      Description copied from interface: EquivTo
      Returns true if this object is equivalent to o according to the given comparator.
      Specified by:
      equivTo in interface EquivTo
    • equivHashCode

      public int equivHashCode()
      Returns a hash code for this object, consistent with structural equality.
      Specified by:
      equivHashCode in interface EquivTo
    • toString

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

      public void toString(@NonNull StmtPrinter up)
      Specified by:
      toString in interface Value
    • getBaseType

      public ArrayType getBaseType()
    • getSize

      public Immediate getSize(int index)
    • getSizeCount

      public int getSizeCount()
    • getSizes

      public List<Immediate> getSizes()
      Returns a list of Values.
    • getUses

      public @NonNull Stream<Value> getUses()
      Description copied from interface: Value
      Returns a List of Locals,FieldRefs,ArrayRefs which are used by (ie contained within) this Expression or Reference.
      Specified by:
      getUses in interface Value
      Returns:
    • getType

      public @NonNull Type getType()
      Description copied from interface: Value
      Returns the Soot type of this Value.
      Specified by:
      getType in interface Value
    • accept

      public <V extends ExprVisitor> V accept(@NonNull V v)
      Description copied from interface: Acceptor
      Called when this object is visited.
      Specified by:
      accept in interface Acceptor<ExprVisitor>
    • withBaseType

      public @NonNull JNewMultiArrayExpr withBaseType(@NonNull ArrayType baseType)
    • withSizes

      public @NonNull JNewMultiArrayExpr withSizes(@NonNull List<Immediate> sizes)
    • isArrayOfPrimitives

      public boolean isArrayOfPrimitives()