Skip to content

NativeSymbolInfo

Namespace: Dotsider.Core.Analysis.Models

Assembly: Dotsider.Core.dll

The native symbols recovered from a binary, plus the provenance and status needed to explain the result. Symbols are ordered by VirtualAddress, which NativeSymbol%40) relies on to resolve an address to its containing symbol — the lookup the disassembly and hex views use to name code.

public sealed record NativeSymbolInfo : IEquatable<NativeSymbolInfo>

ObjectNativeSymbolInfo

NativeSymbolInfo(IReadOnlyList<NativeSymbol>, NativeSymbolSource, NativeSymbolStatus, string?, string?, NativeArchitecture, NativeSourceMap?)

Section titled “NativeSymbolInfo(IReadOnlyList<NativeSymbol>, NativeSymbolSource, NativeSymbolStatus, string?, string?, NativeArchitecture, NativeSourceMap?)”

The native symbols recovered from a binary, plus the provenance and status needed to explain the result. Symbols are ordered by VirtualAddress, which NativeSymbol%40) relies on to resolve an address to its containing symbol — the lookup the disassembly and hex views use to name code.

Parameters:

  • Symbols (IReadOnlyList<NativeSymbol>): The recovered symbols, sorted ascending by virtual address.
  • Source (NativeSymbolSource): Which reader produced the symbols.
  • Status (NativeSymbolStatus): The probe outcome; explains an empty result.
  • Path (String): The symbol file that was read (PDB, .dbg, or dSYM inner file), or null for self/fallback sources.
  • Diagnostic (String): A human-readable note on the outcome — the mismatch detail, the fallback reason, or null on a clean load.
  • Architecture (NativeArchitecture): The instruction-set architecture of the code the symbols describe (the real selected slice for a fat Mach-O), or Unknown.
  • SourceMap (NativeSourceMap): The aggregated address→file:line map recovered from the sidecar, or null when the format carries no line data.
public NativeSymbolInfo(IReadOnlyList<NativeSymbol> Symbols, NativeSymbolSource Source, NativeSymbolStatus Status, string? Path, string? Diagnostic, NativeArchitecture Architecture, NativeSourceMap? SourceMap)

NativeSymbolInfo(IReadOnlyList<NativeSymbol>, NativeSymbolSource, NativeSymbolStatus, string?, string?)

Section titled “NativeSymbolInfo(IReadOnlyList<NativeSymbol>, NativeSymbolSource, NativeSymbolStatus, string?, string?)”

The pre-#178 five-argument shape, preserved so existing construction sites keep compiling. The architecture defaults to Unknown and the source map to null.

Parameters:

public NativeSymbolInfo(IReadOnlyList<NativeSymbol> symbols, NativeSymbolSource source, NativeSymbolStatus status, string? path, string? diagnostic)

The instruction-set architecture of the code the symbols describe (the real selected slice for a fat Mach-O), or Unknown.

Returns: NativeArchitecture

public NativeArchitecture Architecture { get; init; }

A human-readable note on the outcome — the mismatch detail, the fallback reason, or null on a clean load.

Returns: String

public string? Diagnostic { get; init; }

The symbol file that was read (PDB, .dbg, or dSYM inner file), or null for self/fallback sources.

Returns: String

public string? Path { get; init; }

Which reader produced the symbols.

Returns: NativeSymbolSource

public NativeSymbolSource Source { get; init; }

The aggregated address→file:line map recovered from the sidecar, or null when the format carries no line data.

Returns: NativeSourceMap

public NativeSourceMap? SourceMap { get; init; }

The probe outcome; explains an empty result.

Returns: NativeSymbolStatus

public NativeSymbolStatus Status { get; init; }

The recovered symbols, sorted ascending by virtual address.

Returns: IReadOnlyList<NativeSymbol>

public IReadOnlyList<NativeSymbol> Symbols { get; init; }

Deconstruct(out IReadOnlyList<NativeSymbol>, out NativeSymbolSource, out NativeSymbolStatus, out string?, out string?)

Section titled “Deconstruct(out IReadOnlyList<NativeSymbol>, out NativeSymbolSource, out NativeSymbolStatus, out string?, out string?)”

The pre-#178 five-output deconstruction, preserved alongside the generated seven-output one.

Parameters:

public void Deconstruct(out IReadOnlyList<NativeSymbol> symbols, out NativeSymbolSource source, out NativeSymbolStatus status, out string? path, out string? diagnostic)

Finds the symbol whose range contains virtualAddress. Binary-searches the address-sorted list for the last symbol starting at or before the address, then confirms the address falls within that symbol’s size.

Parameters:

  • virtualAddress (UInt64): The virtual address to resolve.
  • symbol (NativeSymbol): The containing symbol when found.

Returns: Boolean

True when a symbol contains the address; otherwise false.

public bool TryFindByAddress(ulong virtualAddress, out NativeSymbol symbol)