Documentation
¶
Index ¶
- func MuxRPCServerWithReader(rpc *jsonrpc.RPCServer, paramDecoder, resultEncoder http.HandlerFunc) http.HandlerFunc
- func ReaderParamDecoder() (http.HandlerFunc, jsonrpc.ServerOption)
- func ReaderParamEncoder(addr string) jsonrpc.Option
- func ReaderResultDecoder(addr string) jsonrpc.Option
- func ReaderResultEncoder() (http.HandlerFunc, jsonrpc.ServerOption)
- type SetContexter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MuxRPCServerWithReader ¶
func MuxRPCServerWithReader(rpc *jsonrpc.RPCServer, paramDecoder, resultEncoder http.HandlerFunc) http.HandlerFunc
func ReaderParamDecoder ¶
func ReaderParamDecoder() (http.HandlerFunc, jsonrpc.ServerOption)
func ReaderParamEncoder ¶
this use slog.Logger and http.Client from jsonrpc.Config. if you're using jsonrpc.WithLogger or jsonrpc.WithHTTPClient as well, make sure they're before this one. Parameters:
- addr: the full http url that reader server is served on.
- timeout: timeout for the whole http request. 0 for no timeout.
func ReaderResultDecoder ¶
func ReaderResultEncoder ¶
func ReaderResultEncoder() (http.HandlerFunc, jsonrpc.ServerOption)
Types ¶
type SetContexter ¶
Click to show internal directories.
Click to hide internal directories.