Documentation ¶
Index ¶
- type AuctionRPCCaller
- func (rpc1 *AuctionRPCCaller) KillServerNoWait() (err error)
- func (rpc1 *AuctionRPCCaller) KillServerWait() (err error)
- func (rpc1 *AuctionRPCCaller) NoiseListen(privkey *koblitz.PrivateKey, host string, port uint16) (err error)
- func (rpc1 *AuctionRPCCaller) NoiseListenAsync(doneChan chan bool, errChan chan error, privkey *koblitz.PrivateKey, ...)
- func (rpc1 *AuctionRPCCaller) RPCListen(host string, port uint16) (err error)
- func (rpc1 *AuctionRPCCaller) RPCListenAsync(doneChan chan bool, errChan chan error, host string, port uint16)
- func (rpc1 *AuctionRPCCaller) Stop() (err error)
- func (rpc1 *AuctionRPCCaller) WaitUntilDead()
- type GetPublicParametersArgs
- type GetPublicParametersReply
- type OpencxAuctionRPC
- type SubmitPuzzledOrderArgs
- type SubmitPuzzledOrderReply
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuctionRPCCaller ¶
type AuctionRPCCaller struct {
// contains filtered or unexported fields
}
AuctionRPCCaller is a listener for RPC commands
func CreateRPCForServer ¶
func CreateRPCForServer(server *cxauctionserver.OpencxAuctionServer) (rpc1 *AuctionRPCCaller, err error)
func (*AuctionRPCCaller) KillServerNoWait ¶
func (rpc1 *AuctionRPCCaller) KillServerNoWait() (err error)
KillServerNoWait kills the server, stops the clock, everything, doesn't
func (*AuctionRPCCaller) KillServerWait ¶
func (rpc1 *AuctionRPCCaller) KillServerWait() (err error)
KillServerWait kills the server, stops the clock, everything, but waits for stuff
func (*AuctionRPCCaller) NoiseListen ¶
func (rpc1 *AuctionRPCCaller) NoiseListen(privkey *koblitz.PrivateKey, host string, port uint16) (err error)
NoiseListen is a synchronous version of RPCListenAsync
func (*AuctionRPCCaller) NoiseListenAsync ¶
func (rpc1 *AuctionRPCCaller) NoiseListenAsync(doneChan chan bool, errChan chan error, privkey *koblitz.PrivateKey, host string, port uint16)
NoiseListenAsync listens on socket host and port
func (*AuctionRPCCaller) RPCListen ¶
func (rpc1 *AuctionRPCCaller) RPCListen(host string, port uint16) (err error)
RPCListen is a synchronous version of RPCListenAsync
func (*AuctionRPCCaller) RPCListenAsync ¶
func (rpc1 *AuctionRPCCaller) RPCListenAsync(doneChan chan bool, errChan chan error, host string, port uint16)
RPCListenAsync listens on socket host and port
func (*AuctionRPCCaller) Stop ¶
func (rpc1 *AuctionRPCCaller) Stop() (err error)
Stop closes the RPC listener and notifies those from WaitUntilDead
func (*AuctionRPCCaller) WaitUntilDead ¶
func (rpc1 *AuctionRPCCaller) WaitUntilDead()
WaitUntilDead waits until the Stop() method is called
type GetPublicParametersArgs ¶
GetPublicParametersArgs holds the args for the getpublicparameters command
type GetPublicParametersReply ¶
type GetPublicParametersReply struct { AuctionID [32]byte // This is the time that it will take the auction to run. We need to make sure it doesn't // take any less than this, and can actually verify that the exchange isn't running it // for extra time. AuctionTime uint64 StartTime time.Time }
GetPublicParametersReply holds the reply for the getpublicparameters command
type OpencxAuctionRPC ¶
type OpencxAuctionRPC struct {
Server *cxauctionserver.OpencxAuctionServer
}
OpencxAuctionRPC is what is registered and called
func (*OpencxAuctionRPC) GetPublicParameters ¶
func (cl *OpencxAuctionRPC) GetPublicParameters(args GetPublicParametersArgs, reply *GetPublicParametersReply) (err error)
GetPublicParameters gets public parameters from the exchange, like time and auctionID
func (*OpencxAuctionRPC) SubmitPuzzledOrder ¶
func (cl *OpencxAuctionRPC) SubmitPuzzledOrder(args SubmitPuzzledOrderArgs, reply *SubmitPuzzledOrderReply) (err error)
SubmitPuzzledOrder submits an order to the order book or throws an error
type SubmitPuzzledOrderArgs ¶
type SubmitPuzzledOrderArgs struct { // Use the serialize method on match.EncryptedAuctionOrder EncryptedOrderBytes []byte }
SubmitPuzzledOrderArgs holds the args for the submitpuzzledorder command
type SubmitPuzzledOrderReply ¶
type SubmitPuzzledOrderReply struct { }
SubmitPuzzledOrderReply holds the reply for the submitpuzzledorder command