Class CatalogPlan
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
Catalog
The canonical catalog this plan was compiled from.
public Catalog Catalog { get; }
Property Value
Grids
The grids, by index.
public CatalogGrid[] Grids { get; }
Property Value
ServerMetrics
Server-scope metrics, in index order: the first segment of a STATS block.
public MetricPlan[] ServerMetrics { get; }
Property Value
SessionMetrics
Session-scope metrics, in index order: the second segment of a STATS block.
public MetricPlan[] SessionMetrics { get; }
Property Value
Methods
Archetype(int)
The archetype at a wire index read from a peer.
public ArchetypePlan Archetype(int idx)
Parameters
idxintThe 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
namestringThe 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
idxintThe 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
namestringThe command name.
Returns
- MessagePlan
The plan.
Compile(Catalog)
Compiles a catalog that is already canonical.
public static CatalogPlan Compile(Catalog canonical)
Parameters
canonicalCatalogA 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
idxintThe 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
namestringThe event name.
Returns
- MessagePlan
The plan.