Table of Contents

Class SerializedFieldDefinition

Namespace
AsmResolver.DotNet.Serialized
Assembly
AsmResolver.DotNet.dll

Represents a lazily initialized implementation of FieldDefinition that is read from a .NET metadata image.

public class SerializedFieldDefinition : FieldDefinition, IMemberDefinition, IFieldDescriptor, IHasCustomAttribute, IHasConstant, IMemberForwarded, IMemberDescriptor, IFullNameProvider, IImportable, IHasFieldMarshal, IMetadataMember, INameProvider, IModuleProvider, IOwnedCollectionElement<TypeDefinition>
Inheritance
SerializedFieldDefinition
Implements
Inherited Members
Extension Methods

Constructors

SerializedFieldDefinition(ModuleReaderContext, MetadataToken, in FieldDefinitionRow)

Creates a field definition from a field metadata row.

public SerializedFieldDefinition(ModuleReaderContext context, MetadataToken token, in FieldDefinitionRow row)

Parameters

context ModuleReaderContext

The reader context.

token MetadataToken

The token to initialize the field for.

row FieldDefinitionRow

The metadata table row to base the field definition on.

Methods

GetConstant()

Obtains the constant value assigned to the field definition.

protected override Constant? GetConstant()

Returns

Constant

The constant.

Remarks

This method is called upon initialization of the Constant 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 declaring type of the field definition.

protected override TypeDefinition? GetDeclaringType()

Returns

TypeDefinition

The declaring type.

Remarks

This method is called upon initialization of the DeclaringType property.

GetFieldOffset()

Obtains the offset of the field as defined in the field layout.

protected override int? GetFieldOffset()

Returns

int?

The field offset.

Remarks

This method is called upon initialization of the FieldOffset property.

GetFieldRva()

Obtains the initial value of the field.

protected override ISegment? GetFieldRva()

Returns

ISegment

The initial value.

Remarks

This method is called upon initialization of the FieldRva property.

GetImplementationMap()

Obtains the platform invoke information assigned to the field.

protected override ImplementationMap? GetImplementationMap()

Returns

ImplementationMap

The mapping.

Remarks

This method is called upon initialization of the ImplementationMap property.

GetMarshalDescriptor()

Obtains the marshal descriptor value assigned to the field definition.

protected override MarshalDescriptor? GetMarshalDescriptor()

Returns

MarshalDescriptor

The marshal descriptor.

Remarks

This method is called upon initialization of the MarshalDescriptor property.

GetName()

Obtains the name of the field definition.

protected override Utf8String? GetName()

Returns

Utf8String

The name.

Remarks

This method is called upon initialization of the Name property.

GetSignature()

Obtains the signature of the field definition.

protected override FieldSignature? GetSignature()

Returns

FieldSignature

The signature.

Remarks

This method is called upon initialization of the Signature property.