Documentation ¶
Index ¶
- func AddUserByUserId(aclAPI *acl.API, userID string) (*base_token.KeyPair, error)
- func AddUserByUserIdAndPublicKey(aclAPI *acl.API, userID string, publicKey ed25519.PublicKey) error
- func GetAllowedBalance(externalChannel basetoken.BaseTokenInterface, address string, token string) (uint64, error)
- func GetBalance(tokenChannel basetoken.BaseTokenInterface, address string) (uint64, error)
- func Retry(ctx context.Context, what func() error, d time.Duration) error
- func Swap(fromChaincodeAPI base_token.BaseTokenInterface, ...) error
- func UserAllowedBalanceShouldBe(keyPair *basetoken.KeyPair, externalChannel basetoken.BaseTokenInterface, ...) error
- func UserBalanceShouldBe(keyPair *basetoken.KeyPair, tokenOwnChannel basetoken.BaseTokenInterface, ...) error
- func WaitSwapInOtherChannel(chaincodeAPI base_token.BaseTokenInterface, swapTransactionId string) (*channel.Response, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddUserByUserId ¶
func GetAllowedBalance ¶
func GetBalance ¶
func GetBalance(tokenChannel basetoken.BaseTokenInterface, address string) (uint64, error)
func Swap ¶
func Swap(fromChaincodeAPI base_token.BaseTokenInterface, toChaincodeAPI base_token.BaseTokenInterface, keyPair *base_token.KeyPair, token string, swapAmount uint64) error
Swap user token from one cc to another cc fromChaincodeAPI - source chaincode api toChaincodeAPI - target chaincode api user - who will swap token - token owner token - title token swapAmount - amount of token
func UserBalanceShouldBe ¶
func WaitSwapInOtherChannel ¶
func WaitSwapInOtherChannel(chaincodeAPI base_token.BaseTokenInterface, swapTransactionId string) (*channel.Response, error)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.