Package ghidra.program.model.gclass
Class ClassUtils
java.lang.Object
ghidra.program.model.gclass.ClassUtils
Utility class for Class-related software modeling.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
Standard field name for a virtual base table pointer found within a classstatic final String
Standard field name for a virtual function table pointer found within a classstatic final PointerDataType
-
Method Summary
Modifier and TypeMethodDescriptionstatic DataTypePath
getBaseClassDataTypePath
(Composite composite) Returns the data type path for a suitable base classstatic CategoryPath
getClassInternalsPath
(CategoryPath path, String className) Returns the category for class internalsstatic CategoryPath
getClassInternalsPath
(Composite composite) Returns the category for class internalsstatic CategoryPath
Returns the category for class internals for the ClassIDstatic Composite
getSelfBaseType
(Composite composite) Returns the "self-base" composite for the specified class composite.static String
getSpecialVxTableName
(long ptrOffsetInClass) Provides the standard special name for a virtual table (e.g., vbtable, vftable) that is keyed off of by the Decompiler during flattening and replacing of types within a class structure.static DataType
static int
static DataType
static int
static boolean
Indicates whether a label satisfies the format of a vxtable label
-
Field Details
-
VBPTR
Standard field name for a virtual base table pointer found within a class- See Also:
-
VFPTR
Standard field name for a virtual function table pointer found within a class- See Also:
-
VXPTR_TYPE
-
-
Method Details
-
getClassInternalsPath
Returns the category for class internals- Parameters:
composite
- the class composite- Returns:
- the category path
-
getClassInternalsPath
Returns the category for class internals for the ClassID- Parameters:
id
- the class ID- Returns:
- the category path
-
getClassInternalsPath
Returns the category for class internals- Parameters:
path
- the category path of the class compositeclassName
- the name of the class- Returns:
- the category path
-
getBaseClassDataTypePath
Returns the data type path for a suitable base class- Parameters:
composite
- the class composite- Returns:
- the base class data type path
-
getSelfBaseType
Returns the "self-base" composite for the specified class composite. This could be the composite argument itself of could be a component of it- Parameters:
composite
- the main class type- Returns:
- the self-base composite
-
getSpecialVxTableName
Provides the standard special name for a virtual table (e.g., vbtable, vftable) that is keyed off of by the Decompiler during flattening and replacing of types within a class structure. More details to come- Parameters:
ptrOffsetInClass
- the offset of the special field within the class- Returns:
- the special name
-
isVTable
Indicates whether a label satisfies the format of a vxtable label- Parameters:
type
- the data type- Returns:
true
if is a vxtable label format
-
getVftDefaultEntry
-
getVbtDefaultEntry
-
getVftEntrySize
-
getVbtEntrySize
-