Table of Contents

Class RuntimeEvent

Namespace
Maplibre.NativeFfi.Runtime
Assembly
Maplibre.NativeFfi.dll

One copied runtime event from DrainEvents().

public sealed record RuntimeEvent : IEquatable<RuntimeEvent>
Inheritance
RuntimeEvent
Implements
Inherited Members

Constructors

RuntimeEvent(RuntimeEventType, uint, RuntimeEventSourceType, uint, ulong, RuntimeHandle?, MapHandle?, int, uint, RuntimeEventPayload, string)

One copied runtime event from DrainEvents().

public RuntimeEvent(RuntimeEventType Type, uint RawType, RuntimeEventSourceType SourceType, uint RawSourceType, ulong RawSource, RuntimeHandle? RuntimeSource, MapHandle? MapSource, int Code, uint RawPayloadType, RuntimeEventPayload Payload, string Message)

Parameters

Type RuntimeEventType

The event kind, when this binding knows the raw value.

RawType uint

The raw native event kind.

SourceType RuntimeEventSourceType

The source kind, when this binding knows the raw value.

RawSourceType uint

The raw native source kind.

RawSource ulong

The raw native source identity, which names one object for the life of the process. Every event carries it, including a source kind this binding does not name and a map source that resolves to no live MapHandle, so a host still correlates or forwards an event whose source this binding cannot resolve. It is an identity value only: it compares and hashes, and it grants no operations on the object it names.

RuntimeSource RuntimeHandle

The runtime that produced a runtime-sourced event.

MapSource MapHandle

The map that raised this event, resolved from the runtime's weak map registry. Hold a strong reference to the MapHandle for as long as you want to attribute its events: a collected map leaves this null even though SourceType still reports a map source.

Code int

Secondary event detail whose meaning Type selects:

RawPayloadType uint

The raw native payload kind.

Payload RuntimeEventPayload

The copied typed payload selected by the payload kind.

Message string

The copied event message, empty when the event carries none. It carries the image ID for MapStyleImageMissing, the source ID for MapTileAction, and native failure text for the loading and render error kinds.

Properties

Code

Secondary event detail whose meaning Type selects:

public int Code { get; init; }

Property Value

int

MapSource

The map that raised this event, resolved from the runtime's weak map registry. Hold a strong reference to the MapHandle for as long as you want to attribute its events: a collected map leaves this null even though SourceType still reports a map source.

public MapHandle? MapSource { get; init; }

Property Value

MapHandle

Message

The copied event message, empty when the event carries none. It carries the image ID for MapStyleImageMissing, the source ID for MapTileAction, and native failure text for the loading and render error kinds.

public string Message { get; init; }

Property Value

string

Payload

The copied typed payload selected by the payload kind.

public RuntimeEventPayload Payload { get; init; }

Property Value

RuntimeEventPayload

RawPayloadType

The raw native payload kind.

public uint RawPayloadType { get; init; }

Property Value

uint

RawSource

The raw native source identity, which names one object for the life of the process. Every event carries it, including a source kind this binding does not name and a map source that resolves to no live MapHandle, so a host still correlates or forwards an event whose source this binding cannot resolve. It is an identity value only: it compares and hashes, and it grants no operations on the object it names.

public ulong RawSource { get; init; }

Property Value

ulong

RawSourceType

The raw native source kind.

public uint RawSourceType { get; init; }

Property Value

uint

RawType

The raw native event kind.

public uint RawType { get; init; }

Property Value

uint

RuntimeSource

The runtime that produced a runtime-sourced event.

public RuntimeHandle? RuntimeSource { get; init; }

Property Value

RuntimeHandle

SourceType

The source kind, when this binding knows the raw value.

public RuntimeEventSourceType SourceType { get; init; }

Property Value

RuntimeEventSourceType

Type

The event kind, when this binding knows the raw value.

public RuntimeEventType Type { get; init; }

Property Value

RuntimeEventType