Package ghidra.program.model.data
Class SignedCharDataType
- java.lang.Object
-
- ghidra.program.model.data.DataTypeImpl
-
- ghidra.program.model.data.BuiltIn
-
- ghidra.program.model.data.AbstractIntegerDataType
-
- ghidra.program.model.data.CharDataType
-
- ghidra.program.model.data.SignedCharDataType
-
- All Implemented Interfaces:
ArrayStringable,BuiltInDataType,DataType,DataTypeWithCharset,ExtensionPoint,java.io.Serializable,java.util.EventListener,javax.swing.event.ChangeListener
public class SignedCharDataType extends CharDataType
Provides a definition of a primitive signed char data type. While in most environment the size is one 8-bit byte, this can vary based upon data organization imposed by the associated data type manager.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface ghidra.util.classfinder.ExtensionPoint
ExtensionPoint.Exclude, ExtensionPoint.Util
-
-
Field Summary
Fields Modifier and Type Field Description static SignedCharDataTypedataType-
Fields inherited from class ghidra.program.model.data.AbstractIntegerDataType
ENDIAN, MNEMONIC, PADDING
-
Fields inherited from class ghidra.program.model.data.DataTypeImpl
categoryPath, defaultSettings, name
-
Fields inherited from interface ghidra.program.model.data.DataType
CONFLICT_SUFFIX, DEFAULT, NO_LAST_CHANGE_TIME, NO_SOURCE_SYNC_TIME, VOID
-
-
Constructor Summary
Constructors Constructor Description SignedCharDataType()Constructs a new signed char datatype.SignedCharDataType(DataTypeManager dtm)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DataTypeclone(DataTypeManager dtm)Returns a new instance of this DataType with its universalID and SourceArchive identity retained.java.lang.StringgetCDeclaration()Returns the C style data-type declaration for this data-type.java.lang.StringgetCTypeDeclaration(DataOrganization dataOrganization)Returns null for FactoryDataType (which should never be used) and Dynamic types which should generally be replaced by a primitive array (e.g., char[5]) or, a primitive pointer (e.g., char *).java.lang.StringgetDefaultLabelPrefix()Returns the appropriate string to use as the default label prefix in the absence of any data.java.lang.StringgetDescription()Get a String briefly describing this DataType.-
Methods inherited from class ghidra.program.model.data.CharDataType
getBuiltInSettingsDefinitions, getCharsetName, getDefaultLabelPrefix, getFormatSettingsDefinition, getLength, getOppositeSignednessDataType, getValue, getValueClass, isDynamicallySized
-
Methods inherited from class ghidra.program.model.data.AbstractIntegerDataType
getArrayDefaultLabelPrefix, getArrayDefaultOffcutLabelPrefix, getAssemblyMnemonic, getCMnemonic, getMnemonic, getRepresentation, getSignedDataType, getSignedDataTypes, getUnsignedDataType, getUnsignedDataTypes, hasStringValue, isEquivalent, isSigned
-
Methods inherited from class ghidra.program.model.data.BuiltIn
addParent, copy, dataTypeDeleted, dataTypeNameChanged, dataTypeReplaced, dataTypeSizeChanged, dependsOn, getCTypeDeclaration, getCTypeDeclaration, getCTypeDeclaration, getDecompilerDisplayName, getLastChangeTime, getSettingsDefinitions, getUniversalID, removeParent, setCategoryPath, setName, setNameAndCategory
-
Methods inherited from class ghidra.program.model.data.DataTypeImpl
equals, getAlignment, getCategoryPath, getDataOrganization, getDataTypeManager, getDataTypePath, getDefaultAbbreviatedLabelPrefix, getDefaultOffcutLabelPrefix, getDefaultSettings, getDisplayName, getDocs, getLastChangeTimeInSourceArchive, getName, getParents, getPathName, getSourceArchive, hashCode, isDeleted, isNotYetDefined, notifyDeleted, notifyNameChanged, notifyReplaced, notifySizeChanged, replaceWith, setDefaultSettings, setDescription, setLastChangeTime, setLastChangeTimeInSourceArchive, setSourceArchive, stateChanged, toString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface ghidra.program.model.data.ArrayStringable
getArrayRepresentation, getArrayString, getStringDataInstance
-
Methods inherited from interface ghidra.program.model.data.DataType
addParent, copy, dataTypeDeleted, dataTypeNameChanged, dataTypeReplaced, dataTypeSizeChanged, dependsOn, getAlignment, getCategoryPath, getDataTypeManager, getDataTypePath, getDefaultAbbreviatedLabelPrefix, getDefaultOffcutLabelPrefix, getDefaultSettings, getDisplayName, getDocs, getLastChangeTime, getLastChangeTimeInSourceArchive, getMnemonic, getName, getParents, getPathName, getRepresentation, getSettingsDefinitions, getSourceArchive, getUniversalID, isDeleted, isEquivalent, isNotYetDefined, removeParent, replaceWith, setCategoryPath, setDefaultSettings, setDescription, setLastChangeTime, setLastChangeTimeInSourceArchive, setName, setNameAndCategory, setSourceArchive
-
-
-
-
Field Detail
-
dataType
public static final SignedCharDataType dataType
-
-
Constructor Detail
-
SignedCharDataType
public SignedCharDataType()
Constructs a new signed char datatype.
-
SignedCharDataType
public SignedCharDataType(DataTypeManager dtm)
-
-
Method Detail
-
getDescription
public java.lang.String getDescription()
Description copied from interface:DataTypeGet a String briefly describing this DataType.- Specified by:
getDescriptionin interfaceDataType- Overrides:
getDescriptionin classCharDataType- Returns:
- a one-liner describing this DataType.
-
clone
public DataType clone(DataTypeManager dtm)
Description copied from interface:DataTypeReturns a new instance of this DataType with its universalID and SourceArchive identity retained. Note: for built-in DataType's, clone and copy should have the same affect.- Specified by:
clonein interfaceDataType- Overrides:
clonein classCharDataType- Parameters:
dtm- the data-type manager instance whose data-organization should apply.
-
getDefaultLabelPrefix
public java.lang.String getDefaultLabelPrefix()
Description copied from interface:DataTypeReturns the appropriate string to use as the default label prefix in the absence of any data.- Specified by:
getDefaultLabelPrefixin interfaceDataType- Overrides:
getDefaultLabelPrefixin classCharDataType- Returns:
- the default label prefix or null if none specified.
-
getCDeclaration
public java.lang.String getCDeclaration()
Description copied from class:CharDataTypeReturns the C style data-type declaration for this data-type. Null is returned if no appropriate declaration exists.- Overrides:
getCDeclarationin classCharDataType
-
getCTypeDeclaration
public java.lang.String getCTypeDeclaration(DataOrganization dataOrganization)
Description copied from class:BuiltInReturns null for FactoryDataType (which should never be used) and Dynamic types which should generally be replaced by a primitive array (e.g., char[5]) or, a primitive pointer (e.g., char *). For other types an appropriately sized unsigned integer typedef is returned.- Specified by:
getCTypeDeclarationin interfaceBuiltInDataType- Overrides:
getCTypeDeclarationin classCharDataType- Parameters:
dataOrganization- or null for default- Returns:
- definition C-statement (e.g., #define or typedef) or null if type name is a standard C-primitive name or if type is FactoryDataType or Dynamic.
- See Also:
BuiltInDataType.getCTypeDeclaration(ghidra.program.model.data.DataOrganization)
-
-