source

package
v0.0.9 Latest Latest
Warning

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

Go to latest
Published: Apr 6, 2019 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrInvalidAddr = errors.New("invalid address")
View Source
var ErrSourceConn = errors.New("connection to servers failed")

Functions

This section is empty.

Types

type Client

type Client struct {
	RpcClient jsonrpc.RPCClient
	RpcUrl    string
}

func NewClient

func NewClient(rpcUrl string) *Client

func (*Client) GetTxsOfAddress

func (c *Client) GetTxsOfAddress(address string) (txs []Tx, err error)

type Tx

type Tx struct {
	Hash          string        `json:"hash"`
	BlockHash     string        `json:"blockHash"`
	BlockNumber   uint64        `json:"blockNumber"`
	Timestamp     int64         `json:"timestamp"`
	Confirmations int           `json:"confirmations"`
	TxIndex       int           `json:"transactionIndex"`
	FromAddress   string        `json:"fromAddress"`
	ToAddress     string        `json:"toAddress"`
	Value         models.Amount `json:"value"`
	Fee           models.Amount `json:"fee"`
}

Jump to

Keyboard shortcuts

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