Documentation
¶
Index ¶
- type CallOption
- type CallRequest
- type CallResponse
- type CallStreamOption
- type Caller
- type HandleFunc
- type HandleOption
- type HandleRequest
- type HandleResponse
- type HandleStreamFunc
- type HandleStreamOption
- type Handler
- type Message
- type MessageMarshaler
- type MessageParser
- type NewCallerOption
- type NewHandlerOption
- type NewServerOption
- type Server
- type Stream
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CallOption ¶
type CallOption = option.ApplyOption
type CallRequest ¶
type CallRequest = any
type CallResponse ¶
type CallResponse = any
type CallStreamOption ¶
type CallStreamOption = option.ApplyOption
type Caller ¶
type Caller interface { Call(ctx context.Context, method string, req CallRequest, res CallResponse, opts ...CallOption) error CallStream(ctx context.Context, method string, opts ...CallStreamOption) (Stream, error) }
type HandleFunc ¶
type HandleFunc = func(context.Context, HandleRequest) (HandleResponse, error)
type HandleOption ¶
type HandleOption = option.ApplyOption
type HandleRequest ¶
type HandleRequest = []byte
type HandleResponse ¶
type HandleResponse = []byte
type HandleStreamOption ¶
type HandleStreamOption = option.ApplyOption
type Handler ¶
type Handler interface { Handle(method string, fn HandleFunc, opts ...HandleOption) HandleStream(method string, fn HandleStreamFunc, opts ...HandleStreamOption) Do(ctx context.Context, method string, req HandleRequest) (HandleResponse, error) DoStream(ctx context.Context, method string, stm Stream) error }
type MessageMarshaler ¶
type MessageParser ¶
type NewCallerOption ¶
type NewCallerOption = option.ApplyOption
type NewHandlerOption ¶
type NewHandlerOption = option.ApplyOption
type NewServerOption ¶
type NewServerOption = option.ApplyOption
Click to show internal directories.
Click to hide internal directories.