core_types

package
v0.7.3 Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2016 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// 0x0 bytes are for the blockchain
	ResultTypeGenesis        = byte(0x01)
	ResultTypeBlockchainInfo = byte(0x02)
	ResultTypeBlock          = byte(0x03)

	// 0x2 bytes are for the network
	ResultTypeStatus    = byte(0x20)
	ResultTypeNetInfo   = byte(0x21)
	ResultTypeDialSeeds = byte(0x22)

	// 0x4 bytes are for the consensus
	ResultTypeValidators         = byte(0x40)
	ResultTypeDumpConsensusState = byte(0x41)

	// 0x6 bytes are for txs / the application
	ResultTypeBroadcastTx    = byte(0x60)
	ResultTypeUnconfirmedTxs = byte(0x61)

	// 0x7 bytes are for querying the application
	ResultTypeTMSPQuery = byte(0x70)
	ResultTypeTMSPInfo  = byte(0x71)

	// 0x8 bytes are for events
	ResultTypeSubscribe   = byte(0x80)
	ResultTypeUnsubscribe = byte(0x81)
	ResultTypeEvent       = byte(0x82)

	// 0xa bytes for testing
	ResultTypeUnsafeSetConfig        = byte(0xa0)
	ResultTypeUnsafeStartCPUProfiler = byte(0xa1)
	ResultTypeUnsafeStopCPUProfiler  = byte(0xa2)
	ResultTypeUnsafeWriteHeapProfile = byte(0xa3)
	ResultTypeUnsafeFlushMempool     = byte(0xa4)
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Peer

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

type ResultBlock

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

type ResultBlockchainInfo

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

type ResultBroadcastTx

type ResultBroadcastTx struct {
	Code tmsp.CodeType `json:"code"`
	Data []byte        `json:"data"`
	Log  string        `json:"log"`
}

type ResultDialSeeds

type ResultDialSeeds struct {
}

type ResultDumpConsensusState

type ResultDumpConsensusState struct {
	RoundState      string   `json:"round_state"`
	PeerRoundStates []string `json:"peer_round_states"`
}

type ResultEvent

type ResultEvent struct {
	Name string            `json:"name"`
	Data types.TMEventData `json:"data"`
}

type ResultGenesis

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

type ResultNetInfo

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

type ResultStatus

type ResultStatus struct {
	NodeInfo          *p2p.NodeInfo `json:"node_info"`
	PubKey            crypto.PubKey `json:"pub_key"`
	LatestBlockHash   []byte        `json:"latest_block_hash"`
	LatestAppHash     []byte        `json:"latest_app_hash"`
	LatestBlockHeight int           `json:"latest_block_height"`
	LatestBlockTime   int64         `json:"latest_block_time"` // nano
}

type ResultSubscribe

type ResultSubscribe struct {
}

type ResultTMSPInfo added in v0.7.1

type ResultTMSPInfo struct {
	Result tmsp.Result `json:"result"`
}

type ResultTMSPQuery added in v0.7.1

type ResultTMSPQuery struct {
	Result tmsp.Result `json:"result"`
}

type ResultUnconfirmedTxs

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

type ResultUnsafeFlushMempool

type ResultUnsafeFlushMempool struct{}

type ResultUnsafeProfile

type ResultUnsafeProfile struct{}

type ResultUnsafeSetConfig

type ResultUnsafeSetConfig struct{}

type ResultUnsubscribe

type ResultUnsubscribe struct {
}

type ResultValidators

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

type TMResult

type TMResult interface {
	rpctypes.Result
}

Jump to

Keyboard shortcuts

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