btsjson

package
v0.0.0-...-4f625b6 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2021 License: ISC Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ToBytes

func ToBytes(in interface{}) []byte

Types

type AccountHistoryOperationDetail

type AccountHistoryOperationDetail struct {
	TotalCount  int                `json:"total_count"`
	ResultCount int                `json:"result_count"`
	Details     []*OperationDetail `json:"details"`
}

type AssetAmount

type AssetAmount struct {
	Asset  string `json:"asset_id"`
	Amount int64  `json:"amount"`
}

type GetAccountHistoryByOperationsCmd

type GetAccountHistoryByOperationsCmd struct {
	Account    string
	Operations []int
	Start      int
	Limit      int
}

Returns the relative operations on the named account from start number.

func NewGetAccountHistoryByOperationsCmd

func NewGetAccountHistoryByOperationsCmd(account string, operations []int, start int, limit int) *GetAccountHistoryByOperationsCmd

NewGetAccountHistoryByOperationsCmd returns a new instance which can be used to issue a get_account_history_by_operations JSON-RPC command.

type GetBtsAccountCmd

type GetBtsAccountCmd struct {
	Account string
}

GetBtcAccountCmd defines the getaccount JSON-RPC command.

func NewGetBtsAccountCmd

func NewGetBtsAccountCmd(account string) *GetBtsAccountCmd

NewGetAccountCmd returns a new instance which can be used to issue a getaccount JSON-RPC command.

type GetRelativeAccountHistoryCmd

type GetRelativeAccountHistoryCmd struct {
	Account string
	Start   int
	Limit   int
	End     int
}

Returns the relative operations on the named account from start number.

func NewGetRelativeAccountHistoryCmd

func NewGetRelativeAccountHistoryCmd(account string, start int, limit int, end int) *GetRelativeAccountHistoryCmd

NewGetRelativeAccountHistoryCmd returns a new instance which can be used to issue a get_relative_account_history JSON-RPC command.

type ListAccountBalancesCmd

type ListAccountBalancesCmd struct {
	Account string
}

ListAccountBalancesCmd defines the unlock JSON-RPC command.

func NewListAccountBalancesCmd

func NewListAccountBalancesCmd(account string) *ListAccountBalancesCmd

NewListAccountBalancesCmd returns a new instance which can be used to issue a unlock JSON-RPC command.

type OperationArray

type OperationArray struct {
	Id string
	Op OperationContents
}

type OperationContent

type OperationContent interface{}

type OperationContents

type OperationContents []OperationContent

func (*OperationContents) UnmarshalJSON

func (content *OperationContents) UnmarshalJSON(data []byte) error

type OperationDetail

type OperationDetail struct {
	Memo        string
	Description string
	Op          OperationArray
}

type OperationEnvelope

type OperationEnvelope struct {
	Type      int
	Operation interface{}
}

func (*OperationEnvelope) UnmarshalJSON

func (p *OperationEnvelope) UnmarshalJSON(data []byte) error

type Transfer2Cmd

type Transfer2Cmd struct {
	From   string
	To     string
	Amount string
	Symbol string
	Memo   string
}

Transfer2Cmd defines the transfer2 JSON-RPC command.

func NewTransfer2Cmd

func NewTransfer2Cmd(from string, to string, amount string, symbol string, memo string) *Transfer2Cmd

NewTransfer2Cmd returns a new instance which can be used to issue a transfer2 JSON-RPC command.

type Transfer2Content

type Transfer2Content struct {
	RefBlockNum    int64               `json:"ref_block_num"`
	RefBlockPrefix int64               `json:"ref_block_prefix"`
	Expiration     string              `json:"expiration"`
	Operations     []OperationContents `json:"operations"`
}

type Transfer2Result

type Transfer2Result struct {
	TxHash string
	//Operation interface{}
	Operation Transfer2Content
}

func (*Transfer2Result) UnmarshalJSON

func (p *Transfer2Result) UnmarshalJSON(data []byte) error

type TransferOperation

type TransferOperation struct {
	From   string      `json:"from"`
	To     string      `json:"to"`
	Amount AssetAmount `json:"amount"`
	Fee    AssetAmount `json:"fee"`
}

type UnWalletLockCmd

type UnWalletLockCmd struct {
	Password string
}

UnWalletLockCmd defines the unlock JSON-RPC command.

func NewWalletUnLockCmd

func NewWalletUnLockCmd(password string) *UnWalletLockCmd

NewWalletUnLockCmd returns a new instance which can be used to issue a unlock JSON-RPC command.

type WalletLockCmd

type WalletLockCmd struct{}

WalletLockCmd defines the lock JSON-RPC command.

func NewWalletLockCmd

func NewWalletLockCmd() *WalletLockCmd

NewWalletLockCmd returns a new instance which can be used to issue a lock JSON-RPC command.

Jump to

Keyboard shortcuts

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