Documentation ¶
Index ¶
- func Synchronize(ctx context.Context, c *conn.Conn, mode string, manualNodeIndex ...int) (rerr *rpc.Error, err error)
- type AddedTransaction
- type Balance
- type BigInt
- type BinaryWalletTransaction
- type Block
- type BlockchainInfo
- type BlockchainNode
- type BlockchainState
- type ByteArray
- type TextualWalletTransaction
- type WalletState
- type WalletsDump
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AddedTransaction ¶
type AddedTransaction struct { VotingNow bool `json:"voting_now"` TransactionPool struct { PendingCapacity int `json:"pending_capacity"` VotingCapacity int `json:"voting_capacity"` } `json:"txpool"` }
AddedTransaction model
func AddTransaction ¶
func AddTransaction(ctx context.Context, c *conn.Conn, tc transaction.Code, data []byte) (res AddedTransaction, rerr *rpc.Error, err error)
AddTransaction method
type BinaryWalletTransaction ¶
type BinaryWalletTransaction struct { Data ByteArray `json:"data"` Code transaction.Code `json:"code"` Block *BigInt `json:"block"` }
BinaryWalletTransaction model
type Block ¶
type Block []byte
Block model
func GetBlockByDigest ¶
func GetBlockByDigest(ctx context.Context, c *conn.Conn, digest mint.Digest) (res Block, rerr *rpc.Error, err error)
GetBlockByDigest method
type BlockchainInfo ¶
type BlockchainInfo struct { BlockchainVersion uint16 `json:"blockchain_version"` ClientAPIVersion uint16 `json:"client_api_version"` SupportedTransactions []string `json:"supported_transactions"` SupportedAssets []string `json:"supported_assets"` SupportedWalletTags []string `json:"supported_wallet_tags"` }
BlockchainInfo model
func GetBlockchainInfo ¶
func GetBlockchainInfo(ctx context.Context, c *conn.Conn) (res BlockchainInfo, rerr *rpc.Error, err error)
GetBlockchainInfo method
type BlockchainNode ¶
type BlockchainNode struct { Index uint32 `json:"index"` PublicKey mint.PublicKey `json:"public_key"` IP string `json:"ip"` }
BlockchainNode model
func GetBlockchainNodes ¶
func GetBlockchainNodes(ctx context.Context, c *conn.Conn) (res []BlockchainNode, rerr *rpc.Error, err error)
GetBlockchainNodes method
type BlockchainState ¶
type BlockchainState struct { LastBlockDigest mint.Digest `json:"last_block_digest"` LastBlockMerkleRoot mint.Digest `json:"last_block_merkle_root"` BlockCount *BigInt `json:"block_count"` TransactionCount *BigInt `json:"transaction_count"` WalletCount *BigInt `json:"wallet_count"` NodeCount int `json:"node_count"` Balance Balance `json:"balance"` Node struct { BlockchainState string `json:"blockchain_state"` LastError string `json:"last_error"` SyncState string `json:"sync_state"` ConsensusRound int `json:"consensus_round"` VotingNodes string `json:"voting_nodes"` TransactionPool struct { PendingCount int `json:"pending_count"` PendingCapacity int `json:"pending_capacity"` VotingCount int `json:"voting_count"` VotingCapacity int `json:"voting_capacity"` } `json:"transaction_pool"` } `json:"node"` }
BlockchainState model
func GetBlockchainState ¶
func GetBlockchainState(ctx context.Context, c *conn.Conn) (res BlockchainState, rerr *rpc.Error, err error)
GetBlockchainState method
type ByteArray ¶
type ByteArray []byte
ByteArray is byte array wrapper
func (*ByteArray) UnmarshalJSON ¶
UnmarshalJSON impl.
type TextualWalletTransaction ¶
type TextualWalletTransaction struct { Desc string `json:"desc"` Digest mint.Digest `json:"digest"` Block *BigInt `json:"block"` }
TextualWalletTransaction model
type WalletState ¶
type WalletState struct { Exist bool `json:"exist"` Balance Balance `json:"balance"` Tags []string `json:"tags"` LastTransactionID uint64 `json:"last_transaction_id"` LastPoolTransactionID uint64 `json:"last_pool_transaction_id"` }
WalletState model
type WalletsDump ¶
type WalletsDump struct { Count uint64 `json:"count"` Uncompressed uint64 `json:"uncompressed"` Dump ByteArray `json:"dump"` }
WalletsDump model
func DumpWallets ¶
func DumpWallets(ctx context.Context, c *conn.Conn, withMNT, withGOLD bool) (res WalletsDump, rerr *rpc.Error, err error)
DumpWallets method
func (WalletsDump) Wallets ¶
func (wd WalletsDump) Wallets() (map[mint.PublicKey]WalletState, error)
Wallets parses dump
Click to show internal directories.
Click to hide internal directories.