Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type HttpService ¶
type HttpService struct {
Ctx *context.Context
Cfg *configs.MainConfiguration
// contains filtered or unexported fields
}
func NewHttpService ¶
func NewHttpService(mainCtx *context.Context) *HttpService
func (*HttpService) Start ¶
func (p *HttpService) Start(rpcPort string) error
type JsonRpc ¶
type JsonRpc struct {
JsonRpcVersion string `json:"jsonrpc"`
Id int `json:"id"`
Method string `json:"method"`
Params []json.RawMessage `json:"params"`
}
type RpcResponse ¶
type RpcResponse struct {
Status string `json:"status"`
Data interface{} `json:"data"`
}
type RpcService ¶
type RpcService struct {
Ctx *context.Context
Cfg *configs.MainConfiguration
}
func NewRpcService ¶
func NewRpcService(mainCtx *context.Context) *RpcService
func (*RpcService) SendMessage ¶
func (p *RpcService) SendMessage(param []byte, reply *RpcResponse) error
func (*RpcService) Subscription ¶
func (p *RpcService) Subscription(params []byte, reply *RpcResponse) error
Click to show internal directories.
Click to hide internal directories.