Class ConstantSymbol
- Namespace
- AsmResolver.Symbols.Pdb.Records
- Assembly
- AsmResolver.Symbols.Pdb.dll
Represents a single constant symbol.
public class ConstantSymbol : CodeViewSymbol, ICodeViewSymbol
- Inheritance
-
ConstantSymbol
- Implements
- Derived
- Inherited Members
Constructors
ConstantSymbol()
Initializes a named constant
protected ConstantSymbol()
ConstantSymbol(Utf8String, CodeViewTypeRecord, ushort)
Defines a new named constant.
public ConstantSymbol(Utf8String name, CodeViewTypeRecord type, ushort value)
Parameters
name
Utf8StringThe name of the type.
type
CodeViewTypeRecordThe type.
value
ushortThe value to assign to the constant.
Properties
CodeViewSymbolType
Gets the type of symbol this record encodes.
public override CodeViewSymbolType CodeViewSymbolType { get; }
Property Value
Name
Gets or sets the name of the constant.
public Utf8String Name { get; set; }
Property Value
Type
Gets or sets the value type of the constant.
public CodeViewTypeRecord Type { get; set; }
Property Value
Value
Gets or sets the numerical value assigned to the constant.
public ushort Value { get; set; }
Property Value
Methods
GetConstantType()
Obtains the value type of the constant.
protected virtual CodeViewTypeRecord? GetConstantType()
Returns
- CodeViewTypeRecord
The name.
Remarks
This method is called upon initialization of the Type property.
GetName()
Obtains the name of the constant.
protected virtual Utf8String GetName()
Returns
- Utf8String
The name.
Remarks
This method is called upon initialization of the Name property.
ToString()
Returns a string that represents the current object.
public override string ToString()
Returns
- string
A string that represents the current object.