Class DWARFNameInfo
- java.lang.Object
-
- ghidra.app.util.bin.format.dwarf4.next.DWARFNameInfo
-
public class DWARFNameInfo extends java.lang.Object
A immutable hierarchical path based name implementation that can be viewed as eithernamespaces
orcategorypaths
.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description CategoryPath
asCategoryPath()
Converts this object into an equivCategoryPath
.DataTypePath
asDataTypePath()
Converts this object into an equivDataTypePath
.Namespace
asNamespace(Program program)
Converts this object into an equiv GhidraNamespace
, omitting the organizational category path (which only applies to DataTypes).DWARFNameInfo
createChild(java.lang.String childOriginalName, java.lang.String childName, SymbolType childType)
static DWARFNameInfo
createRoot(CategoryPath rootCategory)
boolean
equals(java.lang.Object obj)
static DWARFNameInfo
fromDataType(DataType dataType)
static DWARFNameInfo
fromList(DWARFNameInfo parent, java.util.List<java.lang.String> names)
java.lang.String
getName()
NamespacePath
getNamespacePath()
CategoryPath
getOrganizationalCategoryPath()
java.lang.String
getOriginalName()
DWARFNameInfo
getParent()
CategoryPath
getParentCP()
Namespace
getParentNamespace(Program program)
SymbolType
getType()
int
hashCode()
boolean
isAnon()
boolean
isNameModified()
boolean
isRoot()
DWARFNameInfo
replaceName(java.lang.String newName, java.lang.String newOriginalName)
DWARFNameInfo
replaceType(SymbolType newType)
java.lang.String
toString()
-
-
-
Method Detail
-
createRoot
public static DWARFNameInfo createRoot(CategoryPath rootCategory)
-
fromDataType
public static DWARFNameInfo fromDataType(DataType dataType)
-
fromList
public static DWARFNameInfo fromList(DWARFNameInfo parent, java.util.List<java.lang.String> names)
-
getParent
public DWARFNameInfo getParent()
-
isRoot
public boolean isRoot()
-
getOrganizationalCategoryPath
public CategoryPath getOrganizationalCategoryPath()
-
getNamespacePath
public NamespacePath getNamespacePath()
-
getParentCP
public CategoryPath getParentCP()
-
getName
public java.lang.String getName()
-
replaceName
public DWARFNameInfo replaceName(java.lang.String newName, java.lang.String newOriginalName)
-
replaceType
public DWARFNameInfo replaceType(SymbolType newType)
-
getType
public SymbolType getType()
-
asCategoryPath
public CategoryPath asCategoryPath()
Converts this object into an equivCategoryPath
.- Returns:
CategoryPath
: "/organizational_cat_path/namespace1/namespace2/obj_name"
-
asDataTypePath
public DataTypePath asDataTypePath()
Converts this object into an equivDataTypePath
.- Returns:
DataTypePath
: { "/organizational_cat_path/namespace1/namespace2", "obj_name" }
-
asNamespace
public Namespace asNamespace(Program program)
Converts this object into an equiv GhidraNamespace
, omitting the organizational category path (which only applies to DataTypes).
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
isAnon
public boolean isAnon()
-
getOriginalName
public java.lang.String getOriginalName()
-
isNameModified
public boolean isNameModified()
- Returns:
-
createChild
public DWARFNameInfo createChild(java.lang.String childOriginalName, java.lang.String childName, SymbolType childType)
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
-