Delegate CommandOffTick<T>
Handles a command on the transport thread that received it, instead of delivering it to a tick: the control plane of an application — the "resume" a client sends to a paused engine, which no tick would ever drain.
public delegate void CommandOffTick<T>(SessionId session, in T command) where T : unmanaged
Parameters
sessionSessionIdThe session that sent it, already checked against the declaration's roles, rate and pre-check.
commandTThe decoded command.
Type Parameters
TThe command type.
Remarks
It runs on a receive thread, outside any tick, while the engine may be held. It may call TyphonRuntime.RequestPause, Resume,
Step (without awaiting it) and set TimeScale — the calls that never block. It must not block, must not touch session state, and must not
read or write the database (EW-02): anything that needs the world is a tick's job, queued with WriteInTick or sent as an ordinary command.
Its sequence number settles lastSeq with the next frame. A handler that throws is answered with a REJECTED ACK and counted; the
connection stays open.
Constructors
CommandOffTick(object, nint)
public CommandOffTick(object @object, nint method)
Parameters
Methods
BeginInvoke(SessionId, in T, AsyncCallback, object)
public virtual IAsyncResult BeginInvoke(SessionId session, in T command, AsyncCallback callback, object @object)
Parameters
sessionSessionIdcommandTcallbackAsyncCallbackobjectobject
Returns
EndInvoke(in T, IAsyncResult)
public virtual void EndInvoke(in T command, IAsyncResult result)
Parameters
commandTresultIAsyncResult
Invoke(SessionId, in T)
public virtual void Invoke(SessionId session, in T command)
Parameters
sessionSessionIdcommandT