com.ibm.wala.cast.ir.ssa
Class AbstractReflectiveGet

java.lang.Object
  extended by com.ibm.wala.ssa.SSAInstruction
      extended by com.ibm.wala.ssa.ReflectiveMemberAccess
          extended by com.ibm.wala.cast.ir.ssa.AbstractReflectiveGet
All Implemented Interfaces:
IInstruction
Direct Known Subclasses:
JavaScriptPropertyRead

public abstract class AbstractReflectiveGet
extends ReflectiveMemberAccess

This abstract class represents field (a.k.a property) reads in which the field name is not a constant, but rather a computed value. This is common in scripting languages, and so this base class is shared across all languages that need such accesses.


Nested Class Summary
 
Nested classes/interfaces inherited from class com.ibm.wala.ssa.SSAInstruction
SSAInstruction.IVisitor, SSAInstruction.Visitor
 
Field Summary
 
Fields inherited from class com.ibm.wala.ssa.ReflectiveMemberAccess
memberRef, objectRef
 
Constructor Summary
AbstractReflectiveGet(int result, int objectRef, int memberRef)
           
 
Method Summary
 int getDef()
           
 int getDef(int i)
           
 int getNumberOfDefs()
           
 int getNumberOfUses()
          Method getNumberOfUses.
 boolean hasDef()
          Does this instruction define a normal value, as distinct from a set of exceptions possibly thrown by it (e.g.
 java.lang.String toString(SymbolTable symbolTable, ValueDecorator d)
          Method toString.
 
Methods inherited from class com.ibm.wala.ssa.ReflectiveMemberAccess
getMemberRef, getObjectRef, getUse, hashCode, isFallThrough
 
Methods inherited from class com.ibm.wala.ssa.SSAInstruction
copyForSSA, equals, getExceptionTypes, getValueString, isPEI, toString, visit
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AbstractReflectiveGet

public AbstractReflectiveGet(int result,
                             int objectRef,
                             int memberRef)
Method Detail

toString

public java.lang.String toString(SymbolTable symbolTable,
                                 ValueDecorator d)
Description copied from class: SSAInstruction
Method toString.

Overrides:
toString in class ReflectiveMemberAccess
Returns:
Object

hasDef

public boolean hasDef()
Description copied from class: SSAInstruction
Does this instruction define a normal value, as distinct from a set of exceptions possibly thrown by it (e.g. for invoke instructions).

Overrides:
hasDef in class SSAInstruction
Returns:
true if the instruction does define a proper value.
See Also:
com.ibm.wala.ssa.Instruction#getDef()

getDef

public int getDef()
Overrides:
getDef in class SSAInstruction

getDef

public int getDef(int i)
Overrides:
getDef in class SSAInstruction

getNumberOfUses

public int getNumberOfUses()
Description copied from class: SSAInstruction
Method getNumberOfUses.

Overrides:
getNumberOfUses in class SSAInstruction
Returns:
int
See Also:
com.ibm.wala.ssa.Instruction#getNumberOfUses()

getNumberOfDefs

public int getNumberOfDefs()
Overrides:
getNumberOfDefs in class SSAInstruction