Table of Contents

Class MethodEntryPointsSection

Namespace
AsmResolver.PE.DotNet.ReadyToRun
Assembly
AsmResolver.PE.dll

Represents a section in a ReadyToRun directory of a .NET module containing the native entry points and fixups of all the ahead-of-time compiled managed methods.

public class MethodEntryPointsSection : SegmentBase, IReadyToRunSection, ISegment, IOffsetProvider, IWritable
Inheritance
MethodEntryPointsSection
Implements
Derived
Inherited Members

Properties

CanRead

Indicates whether the raw contents of the section can be read using a BinaryStreamReader.

public virtual bool CanRead { get; }

Property Value

bool

EntryPoints

Gets a collection of entry points stored in the section. The index of the element corresponds to the method as specified in the method definition table in the tables stream of the .NET module.

public NativeArray<MethodEntryPoint> EntryPoints { get; }

Property Value

NativeArray<MethodEntryPoint>

Type

Gets the type of the ReadyToRun section.

public ReadyToRunSectionType Type { get; }

Property Value

ReadyToRunSectionType

Methods

CreateReader()

Creates a binary reader that reads the raw contents of the ReadyToRun section.

public virtual BinaryStreamReader CreateReader()

Returns

BinaryStreamReader

The reader.

Exceptions

InvalidOperationException

Occurs when CanRead is false.

GetEntryPoints()

Obtains the entry points stored in the section.

protected virtual NativeArray<MethodEntryPoint> GetEntryPoints()

Returns

NativeArray<MethodEntryPoint>

The entry points.

Remarks

This method is called upon initialization of the EntryPoints property.

GetPhysicalSize()

Computes the number of bytes that the structure contains.

public override uint GetPhysicalSize()

Returns

uint

The number of bytes.

UpdateOffsets(in RelocationParameters)

Assigns a new file and virtual offset to the segment and all its sub-components.

public override void UpdateOffsets(in RelocationParameters parameters)

Parameters

parameters RelocationParameters

The parameters containing the new offset information for the segment.

Write(BinaryStreamWriter)

Serializes the structure to an output stream.

public override void Write(BinaryStreamWriter writer)

Parameters

writer BinaryStreamWriter

The output stream to write the data to.