Documentation ¶
Index ¶
Constants ¶
View Source
const ( SafeBlockOrder = BlockOrder(-4) FinalizedBlockOrder = BlockOrder(-3) PendingBlockOrder = BlockOrder(-2) LatestBlockOrder = BlockOrder(-1) EarliestBlockOrder = BlockOrder(0) )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type API ¶
type API struct { NameSpace string // namespace under which the rpc methods of Service are exposed Service interface{} // receiver instance which holds the methods Public bool // indication if the methods must be considered safe for public use }
API describes the set of methods offered over the RPC interface
type BlockOrder ¶ added in v1.0.20
type BlockOrder int64
func (BlockOrder) Int64 ¶ added in v1.0.20
func (bo BlockOrder) Int64() int64
func (BlockOrder) MarshalText ¶ added in v1.0.20
func (bo BlockOrder) MarshalText() ([]byte, error)
MarshalText implements encoding.TextMarshaler. It marshals: - "safe", "finalized", "latest", "earliest" or "pending" as strings - other orders as hex
func (*BlockOrder) UnmarshalJSON ¶ added in v1.0.20
func (bo *BlockOrder) UnmarshalJSON(data []byte) error
UnmarshalJSON parses the given JSON fragment into a BlockOrder. It supports: - "safe", "finalized", "latest", "earliest" or "pending" as string arguments - the block order Returned errors: - an invalid block order error when the given argument isn't a known strings - an out of range error when the given block order is either too little or too large
Click to show internal directories.
Click to hide internal directories.