Documentation ¶
Index ¶
- func MakeTransferTransaction(par MakeTransferTransactionParams) ([]byte, error)
- type APIClient
- func (c *APIClient) CheckTransactionIDInLRB(txid ledger.TransactionID) (lrbID ledger.TransactionID, included bool, err error)
- func (c *APIClient) DeleteChainOrigin(par DeleteChainOriginParams) (*transaction.TxContext, error)
- func (c *APIClient) Get(path string) ([]byte, error)
- func (c *APIClient) GetAccountOutputs(account ledger.Accountable, ...) ([]*ledger.OutputWithID, *ledger.TransactionID, error)
- func (c *APIClient) GetAccountOutputsExt(account ledger.Accountable, maxOutputs int, sortOption string, ...) ([]*ledger.OutputWithID, *ledger.TransactionID, error)
- func (c *APIClient) GetChainOutput(chainID ledger.ChainID) (*ledger.OutputWithChainID, byte, error)
- func (c *APIClient) GetChainOutputData(chainID ledger.ChainID) (*ledger.OutputDataWithID, error)
- func (c *APIClient) GetLatestReliableBranch() (*multistate.RootRecord, *ledger.TransactionID, error)
- func (c *APIClient) GetLedgerID() (*ledger.IdentityData, error)
- func (c *APIClient) GetMilestoneData(chainID ledger.ChainID) (*ledger.MilestoneData, error)
- func (c *APIClient) GetNodeInfo() (*global.NodeInfo, error)
- func (c *APIClient) GetOutputData(oid *ledger.OutputID) ([]byte, error)
- func (c *APIClient) GetPeersInfo() (*api.PeersInfo, error)
- func (c *APIClient) GetSyncInfo() (*api.SyncInfo, error)
- func (c *APIClient) GetTransferableOutputs(account ledger.Accountable, maxOutputs ...int) ([]*ledger.OutputWithID, *ledger.TransactionID, uint64, error)
- func (c *APIClient) MakeChainOrigin(par TransferFromED25519WalletParams) (*transaction.TxContext, ledger.ChainID, error)
- func (c *APIClient) MakeCompactTransaction(walletPrivateKey ed25519.PrivateKey, tagAlongSeqID *ledger.ChainID, ...) (*transaction.TxContext, error)
- func (c *APIClient) QueryTxIDStatus(txid ledger.TransactionID, slotSpan int) (*vertex.TxIDStatus, *multistate.TxInclusion, error)
- func (c *APIClient) QueryTxInclusionScore(txid ledger.TransactionID, ...) (*api.TxInclusionScore, error)
- func (c *APIClient) SubmitTransaction(txBytes []byte) error
- func (c *APIClient) TransferFromED25519Wallet(par TransferFromED25519WalletParams) (*transaction.TxContext, error)
- type DeleteChainOriginParams
- type MakeTransferTransactionParams
- type TransferFromED25519WalletParams
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MakeTransferTransaction ¶
func MakeTransferTransaction(par MakeTransferTransactionParams) ([]byte, error)
Types ¶
type APIClient ¶
type APIClient struct {
// contains filtered or unexported fields
}
func NewWithGoogleDNS ¶
NewWithGoogleDNS following ChatGPT suggestion to use GoogleDNS to speed up DNS name resolution Otherwise it takes too long in Proxi
func (*APIClient) CheckTransactionIDInLRB ¶
func (c *APIClient) CheckTransactionIDInLRB(txid ledger.TransactionID) (lrbID ledger.TransactionID, included bool, err error)
func (*APIClient) DeleteChainOrigin ¶
func (c *APIClient) DeleteChainOrigin(par DeleteChainOriginParams) (*transaction.TxContext, error)
func (*APIClient) GetAccountOutputs ¶
func (c *APIClient) GetAccountOutputs(account ledger.Accountable, filter ...func(oid *ledger.OutputID, o *ledger.Output) bool) ([]*ledger.OutputWithID, *ledger.TransactionID, error)
func (*APIClient) GetAccountOutputsExt ¶
func (c *APIClient) GetAccountOutputsExt(account ledger.Accountable, maxOutputs int, sortOption string, filter ...func(oid *ledger.OutputID, o *ledger.Output) bool) ([]*ledger.OutputWithID, *ledger.TransactionID, error)
func (*APIClient) GetChainOutput ¶
GetChainOutput returns parsed output for the chain ID and index of the chain constraint in it
func (*APIClient) GetChainOutputData ¶
func (*APIClient) GetLatestReliableBranch ¶
func (c *APIClient) GetLatestReliableBranch() (*multistate.RootRecord, *ledger.TransactionID, error)
GetLatestReliableBranch retrieves lates reliable branch info from the node
func (*APIClient) GetLedgerID ¶
func (c *APIClient) GetLedgerID() (*ledger.IdentityData, error)
GetLedgerID retrieves ledger ID from server
func (*APIClient) GetMilestoneData ¶
func (*APIClient) GetOutputData ¶
GetOutputData returns output data from the LRB state, if it exists there Returns nil, nil if output does not exist
func (*APIClient) GetTransferableOutputs ¶
func (c *APIClient) GetTransferableOutputs(account ledger.Accountable, maxOutputs ...int) ([]*ledger.OutputWithID, *ledger.TransactionID, uint64, error)
GetTransferableOutputs returns reasonable maximum number of outputs with only 2 constraints and returns total
func (*APIClient) MakeChainOrigin ¶
func (c *APIClient) MakeChainOrigin(par TransferFromED25519WalletParams) (*transaction.TxContext, ledger.ChainID, error)
func (*APIClient) MakeCompactTransaction ¶
func (c *APIClient) MakeCompactTransaction(walletPrivateKey ed25519.PrivateKey, tagAlongSeqID *ledger.ChainID, tagAlongFee uint64, maxInputs ...int) (*transaction.TxContext, error)
MakeCompactTransaction requests server and creates a compact transaction for ED25519 outputs in the form of transaction context. Does not submit it
func (*APIClient) QueryTxIDStatus ¶
func (c *APIClient) QueryTxIDStatus(txid ledger.TransactionID, slotSpan int) (*vertex.TxIDStatus, *multistate.TxInclusion, error)
func (*APIClient) QueryTxInclusionScore ¶
func (c *APIClient) QueryTxInclusionScore(txid ledger.TransactionID, thresholdNumerator, thresholdDenominator, slotSpan int) (*api.TxInclusionScore, error)
func (*APIClient) SubmitTransaction ¶
func (*APIClient) TransferFromED25519Wallet ¶
func (c *APIClient) TransferFromED25519Wallet(par TransferFromED25519WalletParams) (*transaction.TxContext, error)