daikon.chicory
Class DaikonClassInfo

Object
  extended by DaikonVariableInfo
      extended by DaikonClassInfo
All Implemented Interfaces:
Comparable<DaikonVariableInfo>, Iterable<DaikonVariableInfo>

public class DaikonClassInfo
extends DaikonVariableInfo

The DaikonClassInfo class is a subtype of DaikonVariableInfo used for variables which represent the runtime type of a variable (ie, ".getClass()" variables).


Field Summary
 
Fields inherited from class DaikonVariableInfo
children, class_suffix, classClassName, compareInfoString, declShouldPrint, dkconfig_constant_infer, dtraceShouldPrint, dtraceShouldPrintChildren, isArray, ppt_statics, repTypeName, std_visibility, stringClassName, typeName
 
Constructor Summary
DaikonClassInfo(String theName, boolean isArr)
          Constructs a DaikonClassInfo object
 
Method Summary
 String get_relative_name()
          Returns the name of this field
 EnumSet<VarFlags> get_var_flags()
          Returns the variable flags for this variable.
 VarKind get_var_kind()
          Returns function since essentially this is a call to a pure function
 String getDTraceValueString(Object val)
          Returns a String representation of this object suitable for a .dtrace file
 Object getMyValFromParentVal(Object value)
          Given an object value corresponding to the parent of this DaikonVariableInfo variable, return the value (of the corresponding value in the target application) of this DaikonVariableInfo variable.
 String getValueStringNonArr(Object val)
          Get a String representation of the given Object's runtime type and the corresponding "modified" value
 
Methods inherited from class DaikonVariableInfo
addChild, addChildNodes, addClassVars, addDeclVar, addDeclVar, addParameters, addPureMethodDecl, array_child, checkForDerivedVariables, checkForListDecl, checkForRuntimeClass, compareTo, declShouldPrint, dTraceShouldPrint, dTraceShouldPrintChildren, get_const_val, getCompareString, getName, getRepName, getRepTypeName, getRepTypeNameOnly, getTypeName, getTypeNameOnly, getValueStringOfList, getValueStringOfObjectWithMod, implementsList, isArray, isFieldVisible, isHashcode, isHashcodeArray, isInt, isStatic, iterator, shouldAddRuntimeClass, stdClassName, systemClass, toString, tree_as_list, treeString
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DaikonClassInfo

public DaikonClassInfo(String theName,
                       boolean isArr)
Constructs a DaikonClassInfo object

Parameters:
theName - The name of the variable
isArr - True iff the variable represents an array of runtime classes
Method Detail

getMyValFromParentVal

public Object getMyValFromParentVal(Object value)
Description copied from class: DaikonVariableInfo
Given an object value corresponding to the parent of this DaikonVariableInfo variable, return the value (of the corresponding value in the target application) of this DaikonVariableInfo variable. For instance, if the variable a has a field b, then calling getMyValParentVal(val_of_a) will return the value of a.b

Specified by:
getMyValFromParentVal in class DaikonVariableInfo
Parameters:
value - The parent object. Can be null for static fields. (Are there any other circumstances where it can be null?)

getDTraceValueString

public String getDTraceValueString(Object val)
Description copied from class: DaikonVariableInfo
Returns a String representation of this object suitable for a .dtrace file

Overrides:
getDTraceValueString in class DaikonVariableInfo
Parameters:
val - The object whose value to print

getValueStringNonArr

public String getValueStringNonArr(Object val)
Get a String representation of the given Object's runtime type and the corresponding "modified" value

Parameters:
val - The Object whose runtime class we wish to get a String representation of
Returns:
String representation (suitable for a .dtrace file) of the given Object's runtime type, and the "modified" value (modbit)

get_var_kind

public VarKind get_var_kind()
Returns function since essentially this is a call to a pure function

Specified by:
get_var_kind in class DaikonVariableInfo

get_relative_name

public String get_relative_name()
Returns the name of this field

Overrides:
get_relative_name in class DaikonVariableInfo

get_var_flags

public EnumSet<VarFlags> get_var_flags()
Description copied from class: DaikonVariableInfo
Returns the variable flags for this variable. Subclasses should call super() and or in any flags that they add

Overrides:
get_var_flags in class DaikonVariableInfo