Documentation ¶
Overview ¶
Types for storage client responses.
Index ¶
- func EVMEthAddrFromPreimage(contextIdentifier string, contextVersion int, data []byte) ([]byte, error)
- func EthChecksumAddrFromPreimage(contextIdentifier string, contextVersion int, data []byte) *string
- type Account
- type AccountList
- type AccountStats
- type AddressDerivationContext
- type AddressPreimage
- type Allowance
- type BareTokenHolder
- type BigInt
- type Block
- type BlockList
- type DailyActiveAccountsList
- type DebondingDelegation
- type DebondingDelegationList
- type Delegation
- type DelegationList
- type Entity
- type EntityList
- type Epoch
- type EpochList
- type Event
- type EventList
- type EvmNft
- type EvmNftList
- type EvmToken
- type EvmTokenList
- type Node
- type NodeList
- type Proposal
- type ProposalList
- type ProposalTarget
- type ProposalVote
- type ProposalVotes
- type RoothashMessage
- type RoothashMessageList
- type RuntimeAccount
- type RuntimeBlock
- type RuntimeBlockList
- type RuntimeEvent
- type RuntimeEventList
- type RuntimeEventType
- type RuntimeEvmBalance
- type RuntimeEvmContract
- type RuntimeEvmContractVerification
- type RuntimeSdkBalance
- type RuntimeStatus
- type RuntimeTransaction
- type RuntimeTransactionEncryptionEnvelope
- type RuntimeTransactionList
- type Status
- type StorageClient
- func (c *StorageClient) Account(ctx context.Context, address staking.Address) (*Account, error)
- func (c *StorageClient) Accounts(ctx context.Context, r apiTypes.GetConsensusAccountsParams) (*AccountList, error)
- func (c *StorageClient) Block(ctx context.Context, height int64) (*Block, error)
- func (c *StorageClient) Blocks(ctx context.Context, r apiTypes.GetConsensusBlocksParams) (*BlockList, error)
- func (c *StorageClient) DailyActiveAccounts(ctx context.Context, layer apiTypes.Layer, ...) (*DailyActiveAccountsList, error)
- func (c *StorageClient) DebondingDelegations(ctx context.Context, address staking.Address, ...) (*DebondingDelegationList, error)
- func (c *StorageClient) DebondingDelegationsTo(ctx context.Context, address staking.Address, ...) (*DebondingDelegationList, error)
- func (c *StorageClient) Delegations(ctx context.Context, address staking.Address, ...) (*DelegationList, error)
- func (c *StorageClient) DelegationsTo(ctx context.Context, address staking.Address, ...) (*DelegationList, error)
- func (c *StorageClient) Entities(ctx context.Context, p apiTypes.GetConsensusEntitiesParams) (*EntityList, error)
- func (c *StorageClient) Entity(ctx context.Context, address staking.Address) (*Entity, error)
- func (c *StorageClient) EntityNode(ctx context.Context, entityAddress staking.Address, nodeID signature.PublicKey) (*Node, error)
- func (c *StorageClient) EntityNodes(ctx context.Context, address staking.Address, ...) (*NodeList, error)
- func (c *StorageClient) Epoch(ctx context.Context, epoch int64) (*Epoch, error)
- func (c *StorageClient) Epochs(ctx context.Context, p apiTypes.GetConsensusEpochsParams) (*EpochList, error)
- func (c *StorageClient) Events(ctx context.Context, p apiTypes.GetConsensusEventsParams) (*EventList, error)
- func (c *StorageClient) Proposal(ctx context.Context, proposalID uint64) (*Proposal, error)
- func (c *StorageClient) ProposalVotes(ctx context.Context, proposalID uint64, ...) (*ProposalVotes, error)
- func (c *StorageClient) Proposals(ctx context.Context, p apiTypes.GetConsensusProposalsParams) (*ProposalList, error)
- func (c *StorageClient) RoothashMessages(ctx context.Context, p apiTypes.GetConsensusRoothashMessagesParams) (*apiTypes.RoothashMessageList, error)
- func (c *StorageClient) RuntimeAccount(ctx context.Context, address staking.Address) (*RuntimeAccount, error)
- func (c *StorageClient) RuntimeBlocks(ctx context.Context, p apiTypes.GetRuntimeBlocksParams) (*RuntimeBlockList, error)
- func (c *StorageClient) RuntimeEVMNFTs(ctx context.Context, limit *uint64, offset *uint64, ...) (*EvmNftList, error)
- func (c *StorageClient) RuntimeEvents(ctx context.Context, p apiTypes.GetRuntimeEventsParams) (*RuntimeEventList, error)
- func (c *StorageClient) RuntimeStatus(ctx context.Context) (*RuntimeStatus, error)
- func (c *StorageClient) RuntimeTokenHolders(ctx context.Context, p apiTypes.GetRuntimeEvmTokensAddressHoldersParams, ...) (*TokenHolderList, error)
- func (c *StorageClient) RuntimeTokens(ctx context.Context, p apiTypes.GetRuntimeEvmTokensParams, ...) (*EvmTokenList, error)
- func (c *StorageClient) RuntimeTransactions(ctx context.Context, p apiTypes.GetRuntimeTransactionsParams, txHash *string) (*RuntimeTransactionList, error)
- func (c *StorageClient) Shutdown()
- func (c *StorageClient) Status(ctx context.Context) (*Status, error)
- func (c *StorageClient) Transaction(ctx context.Context, txHash string) (*Transaction, error)
- func (c *StorageClient) Transactions(ctx context.Context, p apiTypes.GetConsensusTransactionsParams) (*TransactionList, error)
- func (c *StorageClient) TxVolumes(ctx context.Context, layer apiTypes.Layer, ...) (*TxVolumeList, error)
- func (c *StorageClient) ValidatorHistory(ctx context.Context, address staking.Address, ...) (*ValidatorHistory, error)
- func (c *StorageClient) Validators(ctx context.Context, p apiTypes.GetConsensusValidatorsParams, ...) (*ValidatorList, error)
- type TokenHolderList
- type Transaction
- type TransactionList
- type TxError
- type TxVolume
- type TxVolumeList
- type Validator
- type ValidatorAggStats
- type ValidatorCommissionBound
- type ValidatorHistory
- type ValidatorHistoryPoint
- type ValidatorList
- type ValidatorMedia
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EVMEthAddrFromPreimage ¶
func EthChecksumAddrFromPreimage ¶
EthChecksumAddrFromPreimage gives the friendly Ethereum-style mixed-case checksum address (see ERC-55) for an address preimage or nil if the preimage context is not AddressV0Secp256k1EthContext.
Types ¶
type AccountList ¶
type AccountList = api.AccountList
AccountList is the storage response for ListAccounts.
type AccountStats ¶
type AccountStats = api.AccountStats
type AddressDerivationContext ¶
type AddressDerivationContext = api.AddressDerivationContext
Types that are a part of the storage response for GetRuntimeAccount.
type AddressPreimage ¶
type AddressPreimage = api.AddressPreimage
Types that are a part of the storage response for GetRuntimeAccount.
type BareTokenHolder ¶
type BareTokenHolder = api.BareTokenHolder
type DailyActiveAccountsList ¶
type DailyActiveAccountsList = api.ActiveAccountsList
DailyActiveAccountsList is the storage response for GetDailyActiveAccounts.
type DebondingDelegation ¶
type DebondingDelegation = api.DebondingDelegation
DebondingDelegation is the storage response for GetDebondingDelegation.
type DebondingDelegationList ¶
type DebondingDelegationList = api.DebondingDelegationList
DebondingDelegationList is the storage response for ListDebondingDelegations.
type Delegation ¶
type Delegation = api.Delegation
Delegation is the storage response for GetDelegation.
type DelegationList ¶
type DelegationList = api.DelegationList
DelegationList is the storage response for ListDelegations.
type EntityList ¶
type EntityList = api.EntityList
EntityList is the storage response for ListEntities.
type EventList ¶
type EventList = api.ConsensusEventList
EventsList is the storage response for ListEvents.
type EvmNftList ¶ added in v0.1.17
type EvmNftList = api.EvmNftList
type EvmTokenList ¶
type EvmTokenList = api.EvmTokenList
type ProposalList ¶
type ProposalList = api.ProposalList
ProposalList is the storage response for ListProposals.
type ProposalTarget ¶
type ProposalTarget = api.ProposalTarget
type ProposalVote ¶
type ProposalVote = api.ProposalVote
type ProposalVotes ¶
type ProposalVotes = api.ProposalVotes
ProposalVotes is the storage response for GetProposalVotes.
type RoothashMessage ¶ added in v0.3.0
type RoothashMessage = api.RoothashMessage
type RoothashMessageList ¶ added in v0.3.0
type RoothashMessageList = api.RoothashMessageList
type RuntimeAccount ¶
type RuntimeAccount = api.RuntimeAccount
type RuntimeBlock ¶
type RuntimeBlock = api.RuntimeBlock
Block is the storage response for RuntimeGetBlock.
type RuntimeBlockList ¶
type RuntimeBlockList = api.RuntimeBlockList
RuntimeBlockList is the storage response for RuntimeListBlocks.
type RuntimeEvent ¶
type RuntimeEvent = api.RuntimeEvent
type RuntimeEventList ¶
type RuntimeEventList = api.RuntimeEventList
RuntimeEventList is the storage response for RuntimeEvents.
type RuntimeEventType ¶
type RuntimeEventType = api.RuntimeEventType
type RuntimeEvmBalance ¶
type RuntimeEvmBalance = api.RuntimeEvmBalance
Types that are a part of the storage response for GetRuntimeAccount.
type RuntimeEvmContract ¶
type RuntimeEvmContract = api.RuntimeEvmContract
Types that are a part of the storage response for GetRuntimeAccount.
type RuntimeEvmContractVerification ¶
type RuntimeEvmContractVerification = api.RuntimeEvmContractVerification
Types that are a part of the storage response for GetRuntimeAccount.
type RuntimeSdkBalance ¶
type RuntimeSdkBalance = api.RuntimeSdkBalance
Types that are a part of the storage response for GetRuntimeAccount.
type RuntimeStatus ¶
type RuntimeStatus = api.RuntimeStatus
RuntimeStatus is the storage response for RuntimeStatus.
type RuntimeTransaction ¶
type RuntimeTransaction = api.RuntimeTransaction
RuntimeTransactionList is the storage response for RuntimeTransactions.
type RuntimeTransactionEncryptionEnvelope ¶
type RuntimeTransactionEncryptionEnvelope = api.RuntimeTransactionEncryptionEnvelope
RuntimeTransactionList is the storage response for RuntimeTransactions.
type RuntimeTransactionList ¶
type RuntimeTransactionList = api.RuntimeTransactionList
RuntimeTransactionList is the storage response for RuntimeTransactions.
type StorageClient ¶
type StorageClient struct {
// contains filtered or unexported fields
}
StorageClient is a wrapper around a storage.TargetStorage with knowledge of network semantics.
func NewStorageClient ¶
func NewStorageClient(chainName common.ChainName, db storage.TargetStorage, runtimeClients map[common.Runtime]nodeapi.RuntimeApiLite, networkConfig *oasisConfig.Network, l *log.Logger) (*StorageClient, error)
NewStorageClient creates a new storage client.
func (*StorageClient) Accounts ¶
func (c *StorageClient) Accounts(ctx context.Context, r apiTypes.GetConsensusAccountsParams) (*AccountList, error)
Accounts returns a list of consensus accounts.
func (*StorageClient) Blocks ¶
func (c *StorageClient) Blocks(ctx context.Context, r apiTypes.GetConsensusBlocksParams) (*BlockList, error)
Blocks returns a list of consensus blocks.
func (*StorageClient) DailyActiveAccounts ¶
func (c *StorageClient) DailyActiveAccounts(ctx context.Context, layer apiTypes.Layer, p apiTypes.GetLayerStatsActiveAccountsParams) (*DailyActiveAccountsList, error)
DailyActiveAccounts returns a list of daily active accounts.
func (*StorageClient) DebondingDelegations ¶
func (c *StorageClient) DebondingDelegations(ctx context.Context, address staking.Address, p apiTypes.GetConsensusAccountsAddressDebondingDelegationsParams) (*DebondingDelegationList, error)
DebondingDelegations returns a list of debonding delegations.
func (*StorageClient) DebondingDelegationsTo ¶
func (c *StorageClient) DebondingDelegationsTo(ctx context.Context, address staking.Address, p apiTypes.GetConsensusAccountsAddressDebondingDelegationsToParams) (*DebondingDelegationList, error)
DebondingDelegationsTo returns a list of debonding delegations to an address.
func (*StorageClient) Delegations ¶
func (c *StorageClient) Delegations(ctx context.Context, address staking.Address, p apiTypes.GetConsensusAccountsAddressDelegationsParams) (*DelegationList, error)
Delegations returns a list of delegations.
func (*StorageClient) DelegationsTo ¶
func (c *StorageClient) DelegationsTo(ctx context.Context, address staking.Address, p apiTypes.GetConsensusAccountsAddressDelegationsToParams) (*DelegationList, error)
DelegationsTo returns a list of delegations to an address.
func (*StorageClient) Entities ¶
func (c *StorageClient) Entities(ctx context.Context, p apiTypes.GetConsensusEntitiesParams) (*EntityList, error)
Entities returns a list of registered entities.
func (*StorageClient) EntityNode ¶
func (c *StorageClient) EntityNode(ctx context.Context, entityAddress staking.Address, nodeID signature.PublicKey) (*Node, error)
EntityNode returns a node controlled by the provided entity.
func (*StorageClient) EntityNodes ¶
func (c *StorageClient) EntityNodes(ctx context.Context, address staking.Address, r apiTypes.GetConsensusEntitiesAddressNodesParams) (*NodeList, error)
EntityNodes returns a list of nodes controlled by the provided entity.
func (*StorageClient) Epochs ¶
func (c *StorageClient) Epochs(ctx context.Context, p apiTypes.GetConsensusEpochsParams) (*EpochList, error)
Epochs returns a list of consensus epochs.
func (*StorageClient) Events ¶
func (c *StorageClient) Events(ctx context.Context, p apiTypes.GetConsensusEventsParams) (*EventList, error)
Events returns a list of events.
func (*StorageClient) ProposalVotes ¶
func (c *StorageClient) ProposalVotes(ctx context.Context, proposalID uint64, p apiTypes.GetConsensusProposalsProposalIdVotesParams) (*ProposalVotes, error)
ProposalVotes returns votes for a governance proposal.
func (*StorageClient) Proposals ¶
func (c *StorageClient) Proposals(ctx context.Context, p apiTypes.GetConsensusProposalsParams) (*ProposalList, error)
Proposals returns a list of governance proposals.
func (*StorageClient) RoothashMessages ¶ added in v0.3.0
func (c *StorageClient) RoothashMessages(ctx context.Context, p apiTypes.GetConsensusRoothashMessagesParams) (*apiTypes.RoothashMessageList, error)
func (*StorageClient) RuntimeAccount ¶
func (c *StorageClient) RuntimeAccount(ctx context.Context, address staking.Address) (*RuntimeAccount, error)
func (*StorageClient) RuntimeBlocks ¶
func (c *StorageClient) RuntimeBlocks(ctx context.Context, p apiTypes.GetRuntimeBlocksParams) (*RuntimeBlockList, error)
RuntimeBlocks returns a list of runtime blocks.
func (*StorageClient) RuntimeEVMNFTs ¶ added in v0.1.17
func (*StorageClient) RuntimeEvents ¶
func (c *StorageClient) RuntimeEvents(ctx context.Context, p apiTypes.GetRuntimeEventsParams) (*RuntimeEventList, error)
RuntimeEvents returns a list of runtime events.
func (*StorageClient) RuntimeStatus ¶
func (c *StorageClient) RuntimeStatus(ctx context.Context) (*RuntimeStatus, error)
RuntimeStatus returns runtime status information.
func (*StorageClient) RuntimeTokenHolders ¶
func (c *StorageClient) RuntimeTokenHolders(ctx context.Context, p apiTypes.GetRuntimeEvmTokensAddressHoldersParams, address staking.Address) (*TokenHolderList, error)
func (*StorageClient) RuntimeTokens ¶
func (c *StorageClient) RuntimeTokens(ctx context.Context, p apiTypes.GetRuntimeEvmTokensParams, address *staking.Address) (*EvmTokenList, error)
If `address` is non-nil, it is used to filter the results to at most 1 token: the one with the correcponding contract address.
func (*StorageClient) RuntimeTransactions ¶
func (c *StorageClient) RuntimeTransactions(ctx context.Context, p apiTypes.GetRuntimeTransactionsParams, txHash *string) (*RuntimeTransactionList, error)
RuntimeTransactions returns a list of runtime transactions.
func (*StorageClient) Shutdown ¶
func (c *StorageClient) Shutdown()
Shutdown closes the backing TargetStorage.
func (*StorageClient) Status ¶
func (c *StorageClient) Status(ctx context.Context) (*Status, error)
Status returns status information for Oasis Nexus.
func (*StorageClient) Transaction ¶
func (c *StorageClient) Transaction(ctx context.Context, txHash string) (*Transaction, error)
Transaction returns a consensus transaction. This endpoint is cached.
func (*StorageClient) Transactions ¶
func (c *StorageClient) Transactions(ctx context.Context, p apiTypes.GetConsensusTransactionsParams) (*TransactionList, error)
Transactions returns a list of consensus transactions.
func (*StorageClient) TxVolumes ¶
func (c *StorageClient) TxVolumes(ctx context.Context, layer apiTypes.Layer, p apiTypes.GetLayerStatsTxVolumeParams) (*TxVolumeList, error)
TxVolumes returns a list of transaction volumes per time window.
func (*StorageClient) ValidatorHistory ¶ added in v0.3.2
func (c *StorageClient) ValidatorHistory(ctx context.Context, address staking.Address, p apiTypes.GetConsensusValidatorsAddressHistoryParams) (*ValidatorHistory, error)
func (*StorageClient) Validators ¶
func (c *StorageClient) Validators(ctx context.Context, p apiTypes.GetConsensusValidatorsParams, address *staking.Address) (*ValidatorList, error)
Validators returns a list of validators, or optionally the single validator matching `address`.
type TokenHolderList ¶
type TokenHolderList = api.TokenHolderList
type Transaction ¶
type Transaction = api.Transaction
Transaction is the storage response for GetTransaction.
type TransactionList ¶
type TransactionList = api.TransactionList
TransactionList is the storage response for ListTransactions.
type TxVolumeList ¶
type TxVolumeList = api.TxVolumeList
TxVolumeList is the storage response for GetVolumes.
type ValidatorAggStats ¶ added in v0.3.3
type ValidatorAggStats = api.ValidatorAggStats
ValidatorAggStats holds summary statistics for network validators.
type ValidatorCommissionBound ¶
type ValidatorCommissionBound = api.ValidatorCommissionBound
ValidatorCommissionBound is the commission bound for a validator.
type ValidatorHistory ¶ added in v0.3.2
type ValidatorHistory = api.ValidatorHistory
ValidatorHistory is the storage response for GetValidatorHistory.
type ValidatorHistoryPoint ¶ added in v0.3.2
type ValidatorHistoryPoint = api.ValidatorHistoryPoint
ValidatorHistoryPoint is the escrow information for a validator at a given epoch.
type ValidatorList ¶
type ValidatorList = api.ValidatorList
ValidatorList is the list of consensus validators.
type ValidatorMedia ¶
type ValidatorMedia = api.ValidatorMedia
ValidatorMedia is the metadata for a validator.