core_types

package
v0.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 13, 2020 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterAmino

func RegisterAmino(cdc *amino.Codec)

Types

type Peer

type Peer struct {
	p2p.NodeInfo     `json:"node_info"`
	IsOutbound       bool                 `json:"is_outbound"`
	ConnectionStatus p2p.ConnectionStatus `json:"connection_status"`
}

A peer

type PeerRoundState

type PeerRoundState struct {
	NodeAddress    string          `json:"node_address"`
	PeerRoundState json.RawMessage `json:"peer_round_state"`
}

Raw JSON for the PeerRoundState Unstable

type ResultABCIInfo

type ResultABCIInfo struct {
	Response abci.ResponseInfo `json:"response"`
}

Info abci msg

type ResultABCIQuery

type ResultABCIQuery struct {
	Response abci.ResponseQuery `json:"response"`
}

Query abci msg

type ResultABCIQueryEx

type ResultABCIQueryEx struct {
	Response abci.ResponseQueryEx `json:"response"`
}

QueryEx abci msg

type ResultBlock

type ResultBlock struct {
	BlockMeta *types.BlockMeta `json:"block_meta"`
	Block     *types.Block     `json:"block"`
	BlockSize int              `json:"block_size"`
}

Single block (with meta)

type ResultBlockResults

type ResultBlockResults struct {
	Height  int64                `json:"height"`
	Results *state.ABCIResponses `json:"results"`
}

ABCI results from a block

type ResultBlockchainInfo

type ResultBlockchainInfo struct {
	LastHeight int64              `json:"last_height"`
	BlockMetas []*types.BlockMeta `json:"block_metas"`
}

List of blocks

type ResultBroadcastTx

type ResultBroadcastTx struct {
	Code uint32       `json:"code"`
	Data cmn.HexBytes `json:"data"`
	Log  string       `json:"log"`

	Hash cmn.HexBytes `json:"hash"`
}

CheckTx result

type ResultBroadcastTxCommit

type ResultBroadcastTxCommit struct {
	CheckTx   abci.ResponseCheckTx   `json:"check_tx,omitempt"`
	DeliverTx abci.ResponseDeliverTx `json:"deliver_tx,omitempt"`
	Hash      cmn.HexBytes           `json:"hash,omitempt"`
	Height    int64                  `json:"height,omitempt"`
}

CheckTx and DeliverTx results

type ResultCommit

type ResultCommit struct {
	// SignedHeader is header and commit, embedded so we only have
	// one level in the json output
	types.SignedHeader
	CanonicalCommit bool `json:"canonical"`
}

Commit and Header

func NewResultCommit

func NewResultCommit(header *types.Header, commit *types.Commit,
	canonical bool) *ResultCommit

NewResultCommit is a helper to initialize the ResultCommit with the embedded struct

type ResultConfFile

type ResultConfFile struct {
	F json.RawMessage `json:"f"`
}

type ResultDialPeers

type ResultDialPeers struct {
	Log string `json:"log"`
}

Log from dialing peers

type ResultDialSeeds

type ResultDialSeeds struct {
	Log string `json:"log"`
}

Log from dialing seeds

type ResultDumpConsensusState

type ResultDumpConsensusState struct {
	RoundState      json.RawMessage  `json:"round_state"`
	PeerRoundStates []PeerRoundState `json:"peer_round_states"`
}

Info about the consensus state. Unstable

type ResultEvent

type ResultEvent struct {
	Query string            `json:"query"`
	Data  types.TMEventData `json:"data"`
}

Event data from a subscription

type ResultGenesis

type ResultGenesis struct {
	Genesis *types.GenesisDoc `json:"genesis"`
}

Genesis file

type ResultHealth

type ResultHealth struct {
	ChainID         string `json:"chain_id"`
	Version         string `json:"version"`
	ChainVersion    int64  `json:"chain_version"`
	LastBlockHeight int64  `json:"last_block_height"`
	ValidatorCount  int64  `json:"validator_count"`
}

Result of health data

type ResultNetInfo

type ResultNetInfo struct {
	Listening bool     `json:"listening"`
	Listeners []string `json:"listeners"`
	Peers     []Peer   `json:"peers"`
}

Info about peer connections

type ResultStatus

type ResultStatus struct {
	NodeInfo      p2p.NodeInfo  `json:"node_info"`
	SyncInfo      SyncInfo      `json:"sync_info"`
	ValidatorInfo ValidatorInfo `json:"validator_info"`
}

Node Status

func (*ResultStatus) TxIndexEnabled

func (s *ResultStatus) TxIndexEnabled() bool

Is TxIndexing enabled

type ResultSubscribe

type ResultSubscribe struct{}

empty results

type ResultTx

type ResultTx struct {
	Hash          string                 `json:"hash"`
	Height        int64                  `json:"height"`
	Index         uint32                 `json:"index"`
	DeliverResult abci.ResponseDeliverTx `json:"deliver_tx,omitempt"`
	CheckResult   abci.ResponseCheckTx   `json:"check_tx,omitempt"`
	Tx            types.Tx               `json:"tx"`
	Proof         types.TxProof          `json:"proof,omitempty"`
	StateCode     uint32                 `json:"state_code"`
}

Result of querying for a tx

type ResultUnconfirmedTxs

type ResultUnconfirmedTxs struct {
	N   int        `json:"n_txs"`
	Txs []types.Tx `json:"txs"`
}

List of mempool txs

type ResultUnsafeFlushMempool

type ResultUnsafeFlushMempool struct{}

empty results

type ResultUnsafeProfile

type ResultUnsafeProfile struct{}

empty results

type ResultUnsubscribe

type ResultUnsubscribe struct{}

empty results

type ResultValidators

type ResultValidators struct {
	BlockHeight int64              `json:"block_height"`
	Validators  []*types.Validator `json:"validators"`
}

Validators for a height

type SyncInfo

type SyncInfo struct {
	LatestBlockHash   cmn.HexBytes `json:"latest_block_hash"`
	LatestAppHash     cmn.HexBytes `json:"latest_app_hash"`
	LatestBlockHeight int64        `json:"latest_block_height"`
	LatestBlockTime   time.Time    `json:"latest_block_time"`
	Syncing           bool         `json:"syncing"`
}

Info about the node's syncing state

type ValidatorInfo

type ValidatorInfo struct {
	Address     string        `json:"address"`
	PubKey      crypto.PubKey `json:"pub_key"`
	VotingPower uint64        `json:"voting_power"`
	RewardAddr  string        `json:"reward_addr"`
	Name        string        `json:"name"`
}

Info about the node's validator

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL