Table of Contents

Class StringTable

Namespace
AsmResolver.PE.Win32Resources.Version
Assembly
AsmResolver.PE.Win32Resources.dll

Represents the organization of data in a file-version resource. It contains language and code page formatting information for the strings specified by the Children member. A code page is an ordered character set.

public class StringTable : VersionTableEntry, ISegment, IOffsetProvider, IWritable, IDictionary<string, string>, ICollection<KeyValuePair<string, string>>, IEnumerable<KeyValuePair<string, string>>, IEnumerable
Inheritance
StringTable
Implements
Inherited Members

Constructors

StringTable(ushort, ushort)

Creates a new string table.

public StringTable(ushort languageIdentifier, ushort codePage)

Parameters

languageIdentifier ushort

The language identifier.

codePage ushort

The code page.

Fields

CommentsKey

The name of the string describing the comments assigned to the executable file.

public const string CommentsKey = "Comments"

Field Value

string

CompanyNameKey

The name of the string describing the name of the company that developed the executable file.

public const string CompanyNameKey = "CompanyName"

Field Value

string

FileDescriptionKey

The name of the string describing the executable in such a way that it can be presented to users.

public const string FileDescriptionKey = "FileDescription"

Field Value

string

FileVersionKey

The name of the string describing the version of the file.

public const string FileVersionKey = "FileVersion"

Field Value

string

InternalNameKey

The name of the string describing the internal name of the file.

public const string InternalNameKey = "InternalName"

Field Value

string

LegalCopyrightKey

The name of the string describing the copyright notices that apply to the file.

public const string LegalCopyrightKey = "LegalCopyright"

Field Value

string

LegalTrademarksKey

The name of the string describing the trademark notices that apply to the file.

public const string LegalTrademarksKey = "LegalTrademarks"

Field Value

string

OriginalFilenameKey

The name of the string providing the original file name.

public const string OriginalFilenameKey = "OriginalFilename"

Field Value

string

PrivateBuildKey

The name of the string describing by whom, where, and why this private version of the file was built.

public const string PrivateBuildKey = "PrivateBuild"

Field Value

string

ProductNameKey

The name of the string describing the name of the product with which this file is distributed.

public const string ProductNameKey = "ProductName"

Field Value

string

ProductVersionKey

The name of the string describing the version of the product with which this file is distributed.

public const string ProductVersionKey = "ProductVersion"

Field Value

string

SpecialBuildKey

The name of the string describing how this version of the file differs from the normal version

public const string SpecialBuildKey = "SpecialBuild"

Field Value

string

Properties

CodePage

Gets or sets the code page of this string table.

public ushort CodePage { get; set; }

Property Value

ushort

Count

public int Count { get; }

Property Value

int

this[string]

public string this[string key] { get; set; }

Parameters

key string

Property Value

string

Key

Gets the name of the table.

public override string Key { get; }

Property Value

string

Keys

public ICollection<string> Keys { get; }

Property Value

ICollection<string>

LanguageIdentifier

Gets or sets the language identifier of this string table.

public ushort LanguageIdentifier { get; set; }

Property Value

ushort

ValueType

Gets the value type of the table.

protected override VersionTableValueType ValueType { get; }

Property Value

VersionTableValueType

Values

public ICollection<string> Values { get; }

Property Value

ICollection<string>

Methods

Add(KeyValuePair<string, string>)

public void Add(KeyValuePair<string, string> item)

Parameters

item KeyValuePair<string, string>

Add(string, string)

public void Add(string key, string value)

Parameters

key string
value string

Clear()

public void Clear()

Contains(KeyValuePair<string, string>)

public bool Contains(KeyValuePair<string, string> item)

Parameters

item KeyValuePair<string, string>

Returns

bool

ContainsKey(string)

public bool ContainsKey(string key)

Parameters

key string

Returns

bool

CopyTo(KeyValuePair<string, string>[], int)

public void CopyTo(KeyValuePair<string, string>[] array, int arrayIndex)

Parameters

array KeyValuePair<string, string>[]
arrayIndex int

FromReader(ref BinaryStreamReader)

Reads a single StringTable structure from the provided input stream.

public static StringTable FromReader(ref BinaryStreamReader reader)

Parameters

reader BinaryStreamReader

The input stream.

Returns

StringTable

The read structure.

GetEnumerator()

public IEnumerator<KeyValuePair<string, string>> GetEnumerator()

Returns

IEnumerator<KeyValuePair<string, string>>

GetPhysicalSize()

Computes the number of bytes that the structure contains.

public override uint GetPhysicalSize()

Returns

uint

The number of bytes.

GetValueLength()

Gets the length of the raw value.

protected override uint GetValueLength()

Returns

uint

The raw value.

Remove(KeyValuePair<string, string>)

public bool Remove(KeyValuePair<string, string> item)

Parameters

item KeyValuePair<string, string>

Returns

bool

Remove(string)

public bool Remove(string key)

Parameters

key string

Returns

bool

TryGetValue(string, out string?)

public bool TryGetValue(string key, out string? value)

Parameters

key string
value string

Returns

bool

WriteValue(BinaryStreamWriter)

Writes the value field of the version structure.

protected override void WriteValue(BinaryStreamWriter writer)

Parameters

writer BinaryStreamWriter

The output stream.