Package ghidra.program.model.data
Interface ICategory
public interface ICategory
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddDataType
(DataType dt, DataTypeConflictHandler handler) copyCategory
(Category category, DataTypeConflictHandler handler, TaskMonitor monitor) Make a new subcategory from the given category.createCategory
(String name) Create a category with the given name.Category[]
Get all categories in this category.getCategory
(String name) Get a category with the given name.Get the fully qualified name for this category.getDataType
(String name) Get a data type with the given name.Get the data type manager associated with this category.DataType[]
Get all data types in this category.getName()
Get the name of this category.Return this category's parent; return null if this is the root category.getRoot()
Get the root category.boolean
isRoot()
void
moveCategory
(Category category, TaskMonitor monitor) Move the given category to this category; category is removed from its original parent category.void
moveDataType
(DataType type, DataTypeConflictHandler handler) boolean
remove
(DataType type, TaskMonitor monitor) boolean
removeCategory
(String name, TaskMonitor monitor) Remove the named category from this category.void
-
Field Details
-
DELIMITER_CHAR
static final char DELIMITER_CHAR- See Also:
-
NAME_DELIMITER
- See Also:
-
DELIMITER_STRING
- See Also:
-
-
Method Details
-
getName
String getName()Get the name of this category. -
setName
-
getCategories
Category[] getCategories()Get all categories in this category.- Returns:
- zero-length array if there are no categories
-
getDataTypes
DataType[] getDataTypes()Get all data types in this category.- Returns:
- zero-length array if there are no data types
-
addDataType
-
getCategory
Get a category with the given name.- Parameters:
name
- the name of the category- Returns:
- null if there is no category by this name
-
getCategoryPath
CategoryPath getCategoryPath() -
getDataType
Get a data type with the given name.- Parameters:
name
- the name of the data type- Returns:
- null if there is no data type by this name
-
createCategory
Create a category with the given name.- Parameters:
name
- the category name- Throws:
DuplicateNameException
- if this category already contains a category or data type with the given nameInvalidNameException
- if name has invalid characters
-
removeCategory
Remove the named category from this category.- Parameters:
name
- the name of the category to removemonitor
- the task monitor- Returns:
- true if the category was removed
-
moveCategory
Move the given category to this category; category is removed from its original parent category.- Parameters:
category
- the category to move- Throws:
DuplicateNameException
- if this category already contains a category or data type with the same name as the category param.
-
copyCategory
Make a new subcategory from the given category.- Parameters:
category
- the category to copy into this category- Returns:
- category that is added to this category
-
getParent
Category getParent()Return this category's parent; return null if this is the root category. -
isRoot
boolean isRoot() -
getCategoryPathName
String getCategoryPathName()Get the fully qualified name for this category. -
getRoot
Category getRoot()Get the root category. -
getDataTypeManager
DataTypeManager getDataTypeManager()Get the data type manager associated with this category. -
moveDataType
void moveDataType(DataType type, DataTypeConflictHandler handler) throws DataTypeDependencyException - Parameters:
type
-- Throws:
DataTypeDependencyException
-
remove
- Parameters:
type
-
-