Documentation
¶
Overview ¶
Package flow_helpers provides convience functions for Flow blockchain interaction.
Index ¶
- func FormatAddress(address flow.Address) string
- func HexString(str string) string
- func LatestBlockId(ctx context.Context, c *client.Client) (*flow.Identifier, error)
- func SendAndWait(ctx context.Context, c *client.Client, tx flow.Transaction, ...) (*flow.TransactionResult, error)
- func ValidateAddress(address string, chainId flow.ChainID) (string, error)
- func ValidateTransactionId(id string) error
- func WaitForSeal(ctx context.Context, c *client.Client, id flow.Identifier, ...) (*flow.TransactionResult, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FormatAddress ¶
func FormatAddress(address flow.Address) string
func LatestBlockId ¶
LatestBlockId retuns the flow.Identifier for the latest block in the chain.
func SendAndWait ¶ added in v0.6.0
func SendAndWait(ctx context.Context, c *client.Client, tx flow.Transaction, timeout time.Duration) (*flow.TransactionResult, error)
SendAndWait sends the transaction and waits for the transaction to be sealed
func ValidateAddress ¶
func ValidateTransactionId ¶
func WaitForSeal ¶
func WaitForSeal(ctx context.Context, c *client.Client, id flow.Identifier, timeout time.Duration) (*flow.TransactionResult, error)
WaitForSeal blocks until - an error occurs while fetching the transaction result - the transaction gets an error status - the transaction gets a "TransactionStatusSealed" or "TransactionStatusExpired" status - timeout is reached
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.