Table of Contents

Class TablesStreamBuffer

Namespace
AsmResolver.DotNet.Builder.Metadata
Assembly
AsmResolver.DotNet.dll

Provides a mutable buffer for building up a tables stream in a .NET portable executable.

public class TablesStreamBuffer : IMetadataStreamBuffer
Inheritance
TablesStreamBuffer
Implements
Inherited Members

Constructors

TablesStreamBuffer()

Creates a new mutable tables stream buffer.

public TablesStreamBuffer()

Properties

ForceEncMetadata

Gets a value indicating whether the buffer should always use edit-and-continue metadata.

public bool ForceEncMetadata { get; set; }

Property Value

bool

IsEmpty

Gets a value indicating whether the metadata stream buffer does not contain any data.

public bool IsEmpty { get; }

Property Value

bool

IsEncMetadata

Gets a value indicating whether the buffer contains edit-and-continue metadata tables.

public bool IsEncMetadata { get; }

Property Value

bool

Name

Gets the name of the stream.

public string Name { get; }

Property Value

string

Methods

CreateStream()

Serializes the tables stream buffer to a metadata stream.

public TablesStream CreateStream()

Returns

TablesStream

The stream.

GetDistinctTable<TRow>(TableIndex)

Gets a table buffer by its table index.

public DistinctMetadataTableBuffer<TRow> GetDistinctTable<TRow>(TableIndex table) where TRow : struct, IMetadataRow

Parameters

table TableIndex

The index of the table to get.

Returns

DistinctMetadataTableBuffer<TRow>

The metadata table.

Type Parameters

TRow

The type of rows the table stores.

GetIndexEncoder(CodedIndex)

Gets an encoder/decoder for a particular coded index.

public IndexEncoder GetIndexEncoder(CodedIndex codedIndex)

Parameters

codedIndex CodedIndex

The coded index.

Returns

IndexEncoder

The encoder/decoder object.

GetSortedTable<TKey, TRow>(TableIndex)

Gets a table buffer by its table index.

public ISortedMetadataTableBuffer<TKey, TRow> GetSortedTable<TKey, TRow>(TableIndex table) where TRow : struct, IMetadataRow

Parameters

table TableIndex

The index of the table to get.

Returns

ISortedMetadataTableBuffer<TKey, TRow>

The metadata table.

Type Parameters

TKey

The type of members that are assigned new metadata rows.

TRow

The type of rows the table stores.

GetTable<TRow>(TableIndex)

Gets a table buffer by its table index.

public IMetadataTableBuffer<TRow> GetTable<TRow>(TableIndex table) where TRow : struct, IMetadataRow

Parameters

table TableIndex

The index of the table to get.

Returns

IMetadataTableBuffer<TRow>

The metadata table.

Type Parameters

TRow

The type of rows the table stores.