Documentation ¶
Index ¶
- func Init(name string, s rpctypes.RPCServer)
- type BlackwhiteCreateTx
- type BlackwhiteCreateTxRPC
- type BlackwhitePlayTx
- type BlackwhitePlayTxRPC
- type BlackwhiteShowTx
- type BlackwhiteShowTxRPC
- type BlackwhiteTimeoutDoneTx
- type BlackwhiteTimeoutDoneTxRPC
- type Grpc
- func (c Grpc) Create(ctx context.Context, head *bw.BlackwhiteCreate) (*types.UnsignTx, error)
- func (c Grpc) Play(ctx context.Context, head *bw.BlackwhitePlay) (*types.UnsignTx, error)
- func (c Grpc) Show(ctx context.Context, head *bw.BlackwhiteShow) (*types.UnsignTx, error)
- func (c Grpc) TimeoutDone(ctx context.Context, head *bw.BlackwhiteTimeoutDone) (*types.UnsignTx, error)
- type Jrpc
- func (c *Jrpc) BlackwhiteCreateTx(parm *bw.BlackwhiteCreateTxReq, result *interface{}) error
- func (c *Jrpc) BlackwhitePlayTx(parm *BlackwhitePlayTx, result *interface{}) error
- func (c *Jrpc) BlackwhiteShowTx(parm *BlackwhiteShowTx, result *interface{}) error
- func (c *Jrpc) BlackwhiteTimeoutDoneTx(parm *BlackwhiteTimeoutDoneTx, result *interface{}) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BlackwhiteCreateTx ¶
type BlackwhiteCreateTx struct { PlayAmount int64 `json:"amount"` PlayerCount int32 `json:"playerCount"` Timeout int64 `json:"timeout"` GameName string `json:"gameName"` Fee int64 `json:"fee"` }
BlackwhiteCreateTx 创建游戏结构体
type BlackwhiteCreateTxRPC ¶
type BlackwhiteCreateTxRPC struct{}
BlackwhiteCreateTxRPC ...
func (*BlackwhiteCreateTxRPC) Input ¶
func (t *BlackwhiteCreateTxRPC) Input(message json.RawMessage) ([]byte, error)
Input for convert struct
func (*BlackwhiteCreateTxRPC) Output ¶
func (t *BlackwhiteCreateTxRPC) Output(reply interface{}) (interface{}, error)
Output for convert struct
type BlackwhitePlayTx ¶
type BlackwhitePlayTx struct { GameID string `json:"gameID"` Amount int64 `json:"amount"` HashValues [][]byte `json:"hashValues"` Fee int64 `json:"fee"` }
BlackwhitePlayTx 参与游戏结构体
type BlackwhitePlayTxRPC ¶
type BlackwhitePlayTxRPC struct { }
BlackwhitePlayTxRPC ...
func (*BlackwhitePlayTxRPC) Input ¶
func (t *BlackwhitePlayTxRPC) Input(message json.RawMessage) ([]byte, error)
Input for convert struct
func (*BlackwhitePlayTxRPC) Output ¶
func (t *BlackwhitePlayTxRPC) Output(reply interface{}) (interface{}, error)
Output for convert struct
type BlackwhiteShowTx ¶
type BlackwhiteShowTx struct { GameID string `json:"gameID"` Secret string `json:"secret"` Fee int64 `json:"fee"` }
BlackwhiteShowTx 出示密钥结构体
type BlackwhiteShowTxRPC ¶
type BlackwhiteShowTxRPC struct { }
BlackwhiteShowTxRPC ...
func (*BlackwhiteShowTxRPC) Input ¶
func (t *BlackwhiteShowTxRPC) Input(message json.RawMessage) ([]byte, error)
Input for convert struct
func (*BlackwhiteShowTxRPC) Output ¶
func (t *BlackwhiteShowTxRPC) Output(reply interface{}) (interface{}, error)
Output for convert struct
type BlackwhiteTimeoutDoneTx ¶
BlackwhiteTimeoutDoneTx 游戏超时结构体
type BlackwhiteTimeoutDoneTxRPC ¶
type BlackwhiteTimeoutDoneTxRPC struct { }
BlackwhiteTimeoutDoneTxRPC ...
func (*BlackwhiteTimeoutDoneTxRPC) Input ¶
func (t *BlackwhiteTimeoutDoneTxRPC) Input(message json.RawMessage) ([]byte, error)
Input for convert struct
func (*BlackwhiteTimeoutDoneTxRPC) Output ¶
func (t *BlackwhiteTimeoutDoneTxRPC) Output(reply interface{}) (interface{}, error)
Output for convert struct
type Grpc ¶
type Grpc struct {
// contains filtered or unexported fields
}
Grpc grpc struct
func (Grpc) TimeoutDone ¶
type Jrpc ¶
type Jrpc struct {
// contains filtered or unexported fields
}
Jrpc json rpc struct
func (*Jrpc) BlackwhiteCreateTx ¶
func (c *Jrpc) BlackwhiteCreateTx(parm *bw.BlackwhiteCreateTxReq, result *interface{}) error
BlackwhiteCreateTx 创建游戏RPC接口
func (*Jrpc) BlackwhitePlayTx ¶
func (c *Jrpc) BlackwhitePlayTx(parm *BlackwhitePlayTx, result *interface{}) error
BlackwhitePlayTx 参与游戏的RPC接口
func (*Jrpc) BlackwhiteShowTx ¶
func (c *Jrpc) BlackwhiteShowTx(parm *BlackwhiteShowTx, result *interface{}) error
BlackwhiteShowTx 出示游戏密钥的RPC接口
func (*Jrpc) BlackwhiteTimeoutDoneTx ¶
func (c *Jrpc) BlackwhiteTimeoutDoneTx(parm *BlackwhiteTimeoutDoneTx, result *interface{}) error
BlackwhiteTimeoutDoneTx 游戏超时RPC接口
Click to show internal directories.
Click to hide internal directories.