Documentation ¶
Index ¶
- Constants
- type Sender
- type SubstrateClient
- func (c *SubstrateClient) Configurate(path string, name string) error
- func (c *SubstrateClient) GetBlockEvents(hash types.Hash, target interface{}) error
- func (c *SubstrateClient) GetBlockHash(blockNumber uint64) (types.Hash, error)
- func (c *SubstrateClient) GetConfig() *config.SubstrateConfig
- func (c *SubstrateClient) GetHeaderLatest() (*types.Header, error)
- func (c *SubstrateClient) GetMetadata() (meta types.Metadata)
- func (c *SubstrateClient) GetProposalStatus(sourceID []byte, proposalBytes []byte) (bool, *substrate.VoteState, error)
- func (c *SubstrateClient) GetVoterAccountID() types.AccountID
- func (c *SubstrateClient) QueryStorage(prefix, method string, arg1, arg2 []byte, result interface{}) (bool, error)
- func (c *SubstrateClient) ResolveResourceId(id [32]byte) (string, error)
- func (c *SubstrateClient) SubmitTx(method string, args ...interface{}) error
- func (c *SubstrateClient) UpdateMetatdata() error
- type VoteState
Constants ¶
View Source
const BridgePalletName = "ChainBridge"
View Source
const BridgeStoragePrefix = "ChainBridge"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Sender ¶
type Sender interface { PrivateKey() *ecdsa.PrivateKey Address() string }
type SubstrateClient ¶
type SubstrateClient struct {
// contains filtered or unexported fields
}
func NewSubstrateClient ¶
func NewSubstrateClient(stop <-chan struct{}) *SubstrateClient
func (*SubstrateClient) Configurate ¶
func (c *SubstrateClient) Configurate(path string, name string) error
func (*SubstrateClient) GetBlockEvents ¶
func (c *SubstrateClient) GetBlockEvents(hash types.Hash, target interface{}) error
func (*SubstrateClient) GetBlockHash ¶
func (c *SubstrateClient) GetBlockHash(blockNumber uint64) (types.Hash, error)
func (*SubstrateClient) GetConfig ¶
func (c *SubstrateClient) GetConfig() *config.SubstrateConfig
func (*SubstrateClient) GetHeaderLatest ¶
func (c *SubstrateClient) GetHeaderLatest() (*types.Header, error)
func (*SubstrateClient) GetMetadata ¶
func (c *SubstrateClient) GetMetadata() (meta types.Metadata)
func (*SubstrateClient) GetProposalStatus ¶
func (*SubstrateClient) GetVoterAccountID ¶
func (c *SubstrateClient) GetVoterAccountID() types.AccountID
func (*SubstrateClient) QueryStorage ¶
func (c *SubstrateClient) QueryStorage(prefix, method string, arg1, arg2 []byte, result interface{}) (bool, error)
queryStorage performs a storage lookup. Arguments may be nil, result must be a pointer.
func (*SubstrateClient) ResolveResourceId ¶
func (c *SubstrateClient) ResolveResourceId(id [32]byte) (string, error)
func (*SubstrateClient) SubmitTx ¶
func (c *SubstrateClient) SubmitTx(method string, args ...interface{}) error
SubmitTx constructs and submits an extrinsic to call the method with the given arguments. All args are passed directly into GSRPC. GSRPC types are recommended to avoid serialization inconsistencies.
func (*SubstrateClient) UpdateMetatdata ¶
func (c *SubstrateClient) UpdateMetatdata() error
Click to show internal directories.
Click to hide internal directories.