Documentation ¶
Index ¶
- func ToTaskFunc(f BasicFunc) serialserver.TaskFunc
- func ToTaskFuncNoReadWrite(f NoReadWriteFunc) serialserver.TaskFunc
- func ToTaskFuncWithClient(f BasicFuncWithClient) serialserver.TaskFunc
- func ToTaskFuncWithClientContext(f BasicFuncWithClientContext) serialserver.TaskFunc
- func ToTaskFuncWithContext(f BasicFuncWithContext) serialserver.TaskFunc
- type BasicFunc
- type BasicFuncWithClient
- type BasicFuncWithClientContext
- type BasicFuncWithContext
- type NoReadWriteFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ToTaskFunc ¶
func ToTaskFunc(f BasicFunc) serialserver.TaskFunc
ToTaskFunc generates a serialserver.TaskFunc from the given function f.
func ToTaskFuncNoReadWrite ¶
func ToTaskFuncNoReadWrite(f NoReadWriteFunc) serialserver.TaskFunc
ToTaskFuncNoReadWrite generates a serialserver.TaskFunc from the given function f.
func ToTaskFuncWithClient ¶
func ToTaskFuncWithClient(f BasicFuncWithClient) serialserver.TaskFunc
ToTaskFuncWithClient generates a serialserver.TaskFunc from the given function f.
func ToTaskFuncWithClientContext ¶
func ToTaskFuncWithClientContext(f BasicFuncWithClientContext) serialserver.TaskFunc
ToTaskFuncWithClientContext generates a serialserver.TaskFunc from the given function f.
func ToTaskFuncWithContext ¶
func ToTaskFuncWithContext(f BasicFuncWithContext) serialserver.TaskFunc
ToTaskFuncWithContext generates a serialserver.TaskFunc from the given function f.
Types ¶
type BasicFunc ¶
type BasicFunc func(r binaryutil.BinaryReader, w binaryutil.BinaryWriter, lg log.Interface) error
BasicFunc is a function that can be transformed into a serialserver.TaskFunc via ToTaskFunc. Message data from the client can be read from r. The function should write response data to w. Data written to w will be buffered, and sent to the client on successful return.
type BasicFuncWithClient ¶
type BasicFuncWithClient func(c *serialserver.Client, r binaryutil.BinaryReader, w binaryutil.BinaryWriter, lg log.Interface) error
BasicFuncWithClient is a function that can be transformed into a serialserver.TaskFunc via ToTaskFuncWithClient. Message data from the client can be read from r. The function should write response data to w. Data written to w will be buffered, and sent to the client on successful return.
type BasicFuncWithClientContext ¶
type BasicFuncWithClientContext func(ctx context.Context, c *serialserver.Client, r binaryutil.BinaryReader, w binaryutil.BinaryWriter, lg log.Interface) error
BasicFuncWithClientContext is a function that can be transformed into a serialserver.TaskFunc via ToTaskFuncWithClientContext. Message data from the client can be read from r. The function should write response data to w. Data written to w will be buffered, and sent to the client on successful return.
type BasicFuncWithContext ¶
type BasicFuncWithContext func(ctx context.Context, r binaryutil.BinaryReader, w binaryutil.BinaryWriter, lg log.Interface) error
BasicFuncWithContext is a function that can be transformed into a serialserver.TaskFunc via ToTaskFuncWithContext. Message data from the client can be read from r. The function should write response data to w. Data written to w will be buffered, and sent to the client on successful return.
type NoReadWriteFunc ¶
NoReadWriteFunc is a function that can be transformed into a serialserver.TaskFunc via ToTaskFuncNoReadWrite.