Documentation ¶
Index ¶
- Constants
- func Answer(stub *cachestub.BatchCacheStub, swap *proto.MultiSwap, robotSideTimeout int64) (r *proto.SwapResponse)
- func Delete(stub shim.ChaincodeStubInterface, swapID string) error
- func Load(stub shim.ChaincodeStubInterface, swapID string) (*proto.MultiSwap, error)
- func RobotDone(stub *cachestub.BatchCacheStub, swapID []byte, key string) (r *proto.SwapResponse)
- func Save(stub shim.ChaincodeStubInterface, swapID string, swap *proto.MultiSwap) error
- func UserDone(bc BaseContractInterface, swapID string, key string) peer.Response
- type BaseContractInterface
Constants ¶
View Source
const ( // MultiSwapCompositeType is a composite key for multiswap MultiSwapCompositeType = "multi_swap" // MultiSwapKeyEvent is a reason for multiswap MultiSwapKeyEvent = "multi_swap_key" // ErrIncorrectMultiSwap is a reason for multiswap ErrIncorrectMultiSwap = "incorrect swap" // ErrIncorrectMultiSwapKey is a reason for multiswap ErrIncorrectMultiSwapKey = "incorrect key" )
Variables ¶
This section is empty.
Functions ¶
func Answer ¶
func Answer(stub *cachestub.BatchCacheStub, swap *proto.MultiSwap, robotSideTimeout int64) (r *proto.SwapResponse)
func Delete ¶
func Delete(stub shim.ChaincodeStubInterface, swapID string) error
Delete deletes multiswap from the ledger
func RobotDone ¶
func RobotDone(stub *cachestub.BatchCacheStub, swapID []byte, key string) (r *proto.SwapResponse)
Types ¶
type BaseContractInterface ¶
type BaseContractInterface interface { GetStub() shim.ChaincodeStubInterface TokenBalanceAddWithTicker(address *types.Address, amount *big.Int, ticker string, reason string) error AllowedIndustrialBalanceAdd(address *types.Address, industrialAssets []*proto.Asset, reason string) error }
BaseContractInterface represents BaseContract interface
Click to show internal directories.
Click to hide internal directories.