Table of Contents

Class CatalogPlan

Namespace
Typhon.Protocol
Assembly
Typhon.Protocol.dll

A canonical catalog compiled into the plans both directions work from: the server's encoder, a client's decoder and the golden-vector generator.

public sealed class CatalogPlan
Inheritance
CatalogPlan
Inherited Members

Remarks

Compiled once per catalog — at Start on a server, at WELCOME on a client — so no record decode ever looks a codec parameter up by name.

Properties

Archetypes

The archetypes, by index.

public ArchetypePlan[] Archetypes { get; }

Property Value

ArchetypePlan[]

Catalog

The canonical catalog this plan was compiled from.

public Catalog Catalog { get; }

Property Value

Catalog

Grids

The grids, by index.

public CatalogGrid[] Grids { get; }

Property Value

CatalogGrid[]

ServerMetrics

Server-scope metrics, in index order: the first segment of a STATS block.

public MetricPlan[] ServerMetrics { get; }

Property Value

MetricPlan[]

SessionMetrics

Session-scope metrics, in index order: the second segment of a STATS block.

public MetricPlan[] SessionMetrics { get; }

Property Value

MetricPlan[]

Methods

Archetype(int)

The archetype at a wire index read from a peer.

public ArchetypePlan Archetype(int idx)

Parameters

idx int

The index.

Returns

ArchetypePlan

The plan.

Exceptions

WireFormatException

No such archetype.

ArchetypeByName(string)

The archetype with a given name, or null.

public ArchetypePlan ArchetypeByName(string name)

Parameters

name string

The archetype name.

Returns

ArchetypePlan

The plan.

Command(int)

The command type at a wire index read from a peer.

public MessagePlan Command(int idx)

Parameters

idx int

The index.

Returns

MessagePlan

The plan.

Exceptions

WireFormatException

No such command.

CommandByName(string)

The command type with a given name, or null.

public MessagePlan CommandByName(string name)

Parameters

name string

The command name.

Returns

MessagePlan

The plan.

Compile(Catalog)

Compiles a catalog that is already canonical.

public static CatalogPlan Compile(Catalog canonical)

Parameters

canonical Catalog

A validated, canonical catalog.

Returns

CatalogPlan

The plan.

Event(int)

The event type at a wire index read from a peer.

public MessagePlan Event(int idx)

Parameters

idx int

The index.

Returns

MessagePlan

The plan.

Exceptions

WireFormatException

No such event.

EventByName(string)

The event type with a given name, or null.

public MessagePlan EventByName(string name)

Parameters

name string

The event name.

Returns

MessagePlan

The plan.