Class SerializedTypeDefinition
- Namespace
- AsmResolver.DotNet.Serialized
- Assembly
- AsmResolver.DotNet.dll
Represents a lazily initialized implementation of TypeDefinition that is read from a .NET metadata image.
public class SerializedTypeDefinition : TypeDefinition, ITypeDefOrRef, ITypeDescriptor, IMemberRefParent, IHasCustomAttribute, IHasGenericParameters, IMemberDefinition, IMemberDescriptor, IFullNameProvider, IModuleProvider, IImportable, IHasSecurityDeclaration, IMetadataDefinition, INameProvider, IOwnedCollectionElement<ITypeOwner>, ITypeOwner, IMetadataMember
- Inheritance
-
SerializedTypeDefinition
- Implements
- Inherited Members
- Extension Methods
Constructors
SerializedTypeDefinition(ModuleReaderContext, MetadataToken, in TypeDefinitionRow)
Creates a type definition from a type metadata row.
public SerializedTypeDefinition(ModuleReaderContext context, MetadataToken token, in TypeDefinitionRow row)
Parameters
contextModuleReaderContextThe reader context.
tokenMetadataTokenThe token to initialize the type for.
rowTypeDefinitionRowThe metadata table row to base the type definition on.
Properties
HasCustomAttributes
Gets a value indicating whether the member is assigned custom attributes.
public override bool HasCustomAttributes { get; }
Property Value
HasEvents
Gets a value indicating whether the type defines events.
public override bool HasEvents { get; }
Property Value
HasFields
Gets a value indicating whether the type defines fields.
public override bool HasFields { get; }
Property Value
HasGenericParameters
Gets a value indicating whether the member defines generic parameters.
public override bool HasGenericParameters { get; }
Property Value
HasInterfaces
Gets a value indicating whether the type implements interfaces.
public override bool HasInterfaces { get; }
Property Value
HasMethodImplementations
Gets a value indicating whether the type explicitly implements interface methods.
public override bool HasMethodImplementations { get; }
Property Value
HasMethods
Gets a value indicating whether the type defines methods.
public override bool HasMethods { get; }
Property Value
HasNestedTypes
Gets a value indicating whether the type defines nested types.
public override bool HasNestedTypes { get; }
Property Value
HasProperties
Gets a value indicating whether the type defines properties.
public override bool HasProperties { get; }
Property Value
HasSecurityDeclarations
Gets a value indicating whether the member is assigned security declarations.
public override bool HasSecurityDeclarations { get; }
Property Value
Methods
GetBaseType()
Obtains the base type of the type definition.
protected override ITypeDefOrRef? GetBaseType()
Returns
- ITypeDefOrRef
The namespace.
Remarks
This method is called upon initialization of the BaseType property.
GetClassLayout()
Obtains the class layout of this type.
protected override ClassLayout? GetClassLayout()
Returns
- ClassLayout
The class layout.
Remarks
This method is called upon initialization of the ClassLayout property.
GetCustomAttributes()
Obtains the list of custom attributes assigned to the member.
protected override IList<CustomAttribute> GetCustomAttributes()
Returns
- IList<CustomAttribute>
The attributes
Remarks
This method is called upon initialization of the CustomAttributes property.
GetDeclaringType()
Obtains the enclosing class of the type definition if available.
protected override TypeDefinition? GetDeclaringType()
Returns
- TypeDefinition
The enclosing type.
Remarks
This method is called upon initialization of the DeclaringType property.
GetEvents()
Obtains the collection of events that this type defines.
protected override IList<EventDefinition> GetEvents()
Returns
- IList<EventDefinition>
The events.
Remarks
This method is called upon initialization of the Events property.
GetFields()
Obtains the collection of fields that this type defines.
protected override IList<FieldDefinition> GetFields()
Returns
- IList<FieldDefinition>
The fields.
Remarks
This method is called upon initialization of the Fields property.
GetGenericParameters()
Obtains the list of generic parameters this member declares.
protected override IList<GenericParameter> GetGenericParameters()
Returns
- IList<GenericParameter>
The generic parameters
Remarks
This method is called upon initialization of the GenericParameters property.
GetInterfaces()
Obtains the list of interfaces this type implements.
protected override IList<InterfaceImplementation> GetInterfaces()
Returns
- IList<InterfaceImplementation>
The interfaces.
Remarks
This method is called upon initialization of the Interfaces property.
GetMethodImplementations()
Obtains the list of methods this type implements.
protected override IList<MethodImplementation> GetMethodImplementations()
Returns
- IList<MethodImplementation>
The method implementations.
Remarks
This method is called upon initialization of the MethodImplementations property.
GetMethods()
Obtains the collection of methods that this type defines.
protected override IList<MethodDefinition> GetMethods()
Returns
- IList<MethodDefinition>
The methods.
Remarks
This method is called upon initialization of the Methods property.
GetName()
Obtains the name of the type definition.
protected override Utf8String? GetName()
Returns
- Utf8String
The name.
Remarks
This method is called upon initialization of the Name property.
GetNamespace()
Obtains the namespace of the type definition.
protected override Utf8String? GetNamespace()
Returns
- Utf8String
The namespace.
Remarks
This method is called upon initialization of the Namespace property.
GetNestedTypes()
Obtains the list of nested types that this type defines.
protected override IList<TypeDefinition> GetNestedTypes()
Returns
- IList<TypeDefinition>
The nested types.
Remarks
This method is called upon initialization of the NestedTypes property.
GetProperties()
Obtains the collection of properties that this type defines.
protected override IList<PropertyDefinition> GetProperties()
Returns
- IList<PropertyDefinition>
The properties.
Remarks
This method is called upon initialization of the Properties property.
GetSecurityDeclarations()
Obtains the list of security declarations assigned to the member.
protected override IList<SecurityDeclaration> GetSecurityDeclarations()
Returns
- IList<SecurityDeclaration>
The security declarations
Remarks
This method is called upon initialization of the SecurityDeclarations property.