Documentation ¶
Index ¶
- func NewKeyPair(private string) (ed25519.PrivateKey, ed25519.PublicKey, error)
- type InvokeResponse
- type Key
- type Option
- type User
- func (u *User) AddUser() error
- func (u *User) Addr() string
- func (u *User) AddrFromKey(key ed25519.PublicKey) string
- func (u *User) BalanceShouldBe(expected uint64) error
- func (u *User) Base58Pk() string
- func (u *User) ChangeKeys(secretKey ed25519.PrivateKey, publicKey ed25519.PublicKey)
- func (u *User) Invoke(ch, cc, fn string, args ...string) (*InvokeResponse, error)
- func (u *User) InvokeWithListener(ch, cc, fn string, args ...string) (*InvokeResponse, error)
- func (u *User) Query(ch, cc, fn string, args ...string) ([]byte, error)
- func (u *User) QueryWithRetryIfEndorsementMismatch(ch, cc, fn string, args ...string) ([]byte, error)
- func (u *User) SendBatch(ch, cc string, batch *proto.Batch) (*fab.TxStatusEvent, *proto.BatchResponse, error)
- func (u *User) Sign(msg []byte) []byte
- func (u *User) SignedInvoke(nonce *int64, ch, cc, fn string, args ...string) (*InvokeResponse, error)
- func (u *User) SignedInvokeAsync(ch, cc, fn string, args ...string) (*InvokeResponse, error)
- func (u *User) SwapAnswerAndDone(ch, cc, swapID string, swapKey string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewKeyPair ¶
Types ¶
type InvokeResponse ¶
type InvokeResponse struct { Event *fab.TxStatusEvent Response []byte }
type Key ¶
type Key struct { PrivKey ed25519.PrivateKey PubKey ed25519.PublicKey }
Key is a core.Key wrapper for *ecdsa.PublicKey
func (*Key) PublicKey ¶
PublicKey returns the corresponding public key part of an asymmetric public/private key pair.
type User ¶
type User struct { ID string PublicKey ed25519.PublicKey SecretKey ed25519.PrivateKey // contains filtered or unexported fields }
func (*User) BalanceShouldBe ¶
func (*User) ChangeKeys ¶
func (u *User) ChangeKeys(secretKey ed25519.PrivateKey, publicKey ed25519.PublicKey)
func (*User) Invoke ¶
func (u *User) Invoke(ch, cc, fn string, args ...string) (*InvokeResponse, error)
func (*User) InvokeWithListener ¶
func (u *User) InvokeWithListener(ch, cc, fn string, args ...string) (*InvokeResponse, error)
func (*User) QueryWithRetryIfEndorsementMismatch ¶
func (*User) SendBatch ¶
func (u *User) SendBatch(ch, cc string, batch *proto.Batch) (*fab.TxStatusEvent, *proto.BatchResponse, error)
func (*User) SignedInvoke ¶
func (*User) SignedInvokeAsync ¶
func (u *User) SignedInvokeAsync(ch, cc, fn string, args ...string) (*InvokeResponse, error)
Click to show internal directories.
Click to hide internal directories.