Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidAddress = errors.New("invalid address")
ErrInvalidAddress signals that the provided address is invalid
View Source
var ErrNilAddress = errors.New("nil address")
ErrNilAddress signals that the provided address is nil
View Source
var ErrNilShardCoordinator = errors.New("nil shard coordinator")
ErrNilShardCoordinator signals that the provided shard coordinator is nil
Functions ¶
func NewAddressGenerator ¶
func NewAddressGenerator(coordinator *shardCoordinator) (*addressGenerator, error)
NewAddressGenerator
func NewElrondProxy ¶
func NewElrondProxy(url string, client HTTPClient) *elrondProxy
NewElrondProxy initializes and returns an ElrondProxy object
func NewShardCoordinator ¶
func NewShardCoordinator(numOfShardsWithoutMeta uint32, currentShard uint32) (*shardCoordinator, error)
NewShardCoordinator returns a shard coordinator instance that is able to execute sharding-related operations
Types ¶
type HTTPClient ¶
HTTPClient is the interface we expect to call in order to do the HTTP requests
type ProxyHandler ¶
type ProxyHandler interface { ExecuteVMQuery(vmRequest *data.VmValueRequest) (*data.VmValuesResponseData, error) GetNetworkConfig() (*data.NetworkConfig, error) GetNetworkEconomics() (*data.NetworkEconomics, error) GetAccount(address addressHandler) (*data.Account, error) SendTransaction(tx *data.Transaction) (string, error) RequestTransactionCost(tx *data.Transaction) (*data.TxCostResponseData, error) GetTransactionStatus(hash string) (string, error) GetTransactionInfo(hash string) (*data.TransactionInfo, error) GetTransactionInfoWithResults(hash string) (*data.TransactionInfo, error) GetLatestHyperblockNonce() (uint64, error) GetHyperblockByNonce(nonce uint64) (*data.Hyperblock, error) GetHyperblockByHash(hash string) (*data.Hyperblock, error) }
ProxyHandler will handle different implementations of proxy client
Click to show internal directories.
Click to hide internal directories.