cli

package
v0.0.0-...-664a6bc Latest Latest
Warning

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

Go to latest
Published: Jul 27, 2020 License: GPL-3.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func TestCLIVersion

func TestCLIVersion(t *testing.T)

TestCLIVersion test cli version

Types

type Blocks

type Blocks struct {
	Number           string    `db:"block_number"`
	Hash             string    `db:"block_hash"`
	ParentHash       string    `db:"block_parent_hash"`
	Nonce            uint64    `db:"block_nonce"`
	Sha3Uncles       string    `db:"block_sha3_uncles"`
	TransactionsRoot string    `db:"block_transactions_root"`
	StateRoot        string    `db:"block_state_root"`
	ReceiptsRoot     string    `db:"block_receipts_root"`
	Miner            string    `db:"block_miner"`
	Difficulty       string    `db:"block_difficulty"`
	TotalDifficulty  string    `db:"block_total_difficulty"`
	Size             string    `db:"block_size"`
	GasLimit         uint64    `db:"block_gas_limit"`
	GasUsed          uint64    `db:"block_gas_used"`
	Timestamp        time.Time `db:"block_timestamp"`
	TransactionCount int       `db:"block_transaction_count"`
	Signer           string    `db:"block_signer"`
}

Blocks NewChain Blocks

type CLI

type CLI struct {
	Name string
	// contains filtered or unexported fields
}

CLI represents a command-line interface. This class is not threadsafe.

func NewCLI

func NewCLI() *CLI

NewCLI returns an initialized CLI

func (*CLI) Embeddable

func (cli *CLI) Embeddable() *CLI

Embeddable returns a CLI that you can embed into your own Go programs. This is not thread-safe.

func (*CLI) Execute

func (cli *CLI) Execute()

Execute parses the command line and processes it.

func (*CLI) Run

func (cli *CLI) Run(args ...string) string

Run executes CLI with the given arguments. Used for testing. Not thread safe.

func (*CLI) TestCommand

func (cli *CLI) TestCommand(command string) string

TestCommand test command

type Transactions

type Transactions struct {
	Hash        string `db:"tx_hash"`
	BlockNumber string `db:"tx_block_number"`
	Nonce       uint64 `db:"tx_nonce"`
	From        string `db:"tx_from"`
	To          string `db:"tx_to"`
	Value       string `db:"tx_value"`
	Gas         uint64 `db:"tx_gas"`
	GasPrice    string `db:"tx_gas_price"`
}

Transactions NewChain Transactions

Jump to

Keyboard shortcuts

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