Documentation ¶
Index ¶
- type ABClient
- type AlphabillClient
- func (c *AlphabillClient) GetBlock(ctx context.Context, blockNumber uint64) (*block.Block, error)
- func (c *AlphabillClient) GetBlocks(ctx context.Context, blockNumber uint64, blockCount uint64) (res *alphabill.GetBlocksResponse, err error)
- func (c *AlphabillClient) GetMaxBlockNumber(ctx context.Context) (uint64, error)
- func (c *AlphabillClient) IsShutdown() bool
- func (c *AlphabillClient) SendTransaction(ctx context.Context, tx *txsystem.Transaction) (*txsystem.TransactionResponse, error)
- func (c *AlphabillClient) Shutdown() error
- type AlphabillClientConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ABClient ¶
type ABClient interface { SendTransaction(ctx context.Context, tx *txsystem.Transaction) (*txsystem.TransactionResponse, error) GetBlock(ctx context.Context, blockNumber uint64) (*block.Block, error) GetBlocks(ctx context.Context, blockNumber, blockCount uint64) (*alphabill.GetBlocksResponse, error) GetMaxBlockNumber(ctx context.Context) (uint64, error) Shutdown() error IsShutdown() bool }
ABClient manages connection to alphabill node and implements RPC methods
type AlphabillClient ¶
type AlphabillClient struct {
// contains filtered or unexported fields
}
func New ¶
func New(config AlphabillClientConfig) *AlphabillClient
New creates instance of AlphabillClient
func (*AlphabillClient) GetBlocks ¶ added in v0.1.1
func (c *AlphabillClient) GetBlocks(ctx context.Context, blockNumber uint64, blockCount uint64) (res *alphabill.GetBlocksResponse, err error)
func (*AlphabillClient) GetMaxBlockNumber ¶
func (c *AlphabillClient) GetMaxBlockNumber(ctx context.Context) (uint64, error)
func (*AlphabillClient) IsShutdown ¶
func (c *AlphabillClient) IsShutdown() bool
func (*AlphabillClient) SendTransaction ¶
func (c *AlphabillClient) SendTransaction(ctx context.Context, tx *txsystem.Transaction) (*txsystem.TransactionResponse, error)
func (*AlphabillClient) Shutdown ¶
func (c *AlphabillClient) Shutdown() error
type AlphabillClientConfig ¶
Click to show internal directories.
Click to hide internal directories.