Documentation
¶
Index ¶
- func AddLPOperations(txMeta []xdr.OperationMeta, AssetA, AssetB xdr.Asset) []xdr.OperationMeta
- func ConvertStroopValueToReal(input xdr.Int64) float64
- func CreateSampleResultMeta(successful bool, subOperationCount int) xdr.TransactionResultMeta
- func CreateSampleTx(sequence int64, operationCount int) xdr.TransactionEnvelope
- func CreateSampleTxMeta(subOperationCount int, AssetA, AssetB xdr.Asset) *xdr.TransactionMetaV1
- func ExtractEntryFromChange(change ingest.Change) (xdr.LedgerEntry, xdr.LedgerEntryChangeType, bool, error)
- func ExtractLedgerCloseTime(ledger xdr.LedgerHeaderHistoryEntry) (time.Time, error)
- func FarmHashAsset(assetCode, assetIssuer, assetType string) int64
- func GetAccountAddressFromMuxedAccount(account xdr.MuxedAccount) (string, error)
- func GetCloseTime(lcm xdr.LedgerCloseMeta) (time.Time, error)
- func GetLedgerSequence(lcm xdr.LedgerCloseMeta) uint32
- func HashToHexString(inputHash xdr.Hash) string
- func LedgerEntrySponsorToNullString(entry xdr.LedgerEntry) null.String
- func LedgerEntryToLedgerKeyHash(ledgerEntry xdr.LedgerEntry) string
- func LedgerKeyToLedgerKeyHash(ledgerKey xdr.LedgerKey) string
- func PanicOnError(err error)
- func TimePointToUTCTimeStamp(providedTime xdr.TimePoint) (time.Time, error)
- type Claimant
- type HistoryArchiveLedgerAndLCM
- type Path
- type Price
- type SponsorshipOutput
- type TestTransaction
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddLPOperations ¶
func AddLPOperations(txMeta []xdr.OperationMeta, AssetA, AssetB xdr.Asset) []xdr.OperationMeta
func ConvertStroopValueToReal ¶
ConvertStroopValueToReal converts a value in stroops, the smallest amount unit, into real units
func CreateSampleResultMeta ¶
func CreateSampleResultMeta(successful bool, subOperationCount int) xdr.TransactionResultMeta
CreateSampleResultMeta creates Transaction results with the desired success flag and number of sub operation results
func CreateSampleTx ¶
func CreateSampleTx(sequence int64, operationCount int) xdr.TransactionEnvelope
func CreateSampleTxMeta ¶
func CreateSampleTxMeta(subOperationCount int, AssetA, AssetB xdr.Asset) *xdr.TransactionMetaV1
func ExtractEntryFromChange ¶
func ExtractEntryFromChange(change ingest.Change) (xdr.LedgerEntry, xdr.LedgerEntryChangeType, bool, error)
ExtractEntryFromChange gets the most recent state of an entry from an ingestion change, as well as if the entry was deleted
func ExtractLedgerCloseTime ¶
func ExtractLedgerCloseTime(ledger xdr.LedgerHeaderHistoryEntry) (time.Time, error)
ExtractLedgerCloseTime gets the close time of the provided ledger
func FarmHashAsset ¶
func GetAccountAddressFromMuxedAccount ¶
func GetAccountAddressFromMuxedAccount(account xdr.MuxedAccount) (string, error)
GetAccountAddressFromMuxedAccount takes in a muxed account and returns the address of the account
func GetCloseTime ¶
func GetCloseTime(lcm xdr.LedgerCloseMeta) (time.Time, error)
func GetLedgerSequence ¶
func GetLedgerSequence(lcm xdr.LedgerCloseMeta) uint32
func HashToHexString ¶
HashToHexString is utility function that converts and xdr.Hash type to a hex string
func LedgerEntrySponsorToNullString ¶
func LedgerEntrySponsorToNullString(entry xdr.LedgerEntry) null.String
func LedgerEntryToLedgerKeyHash ¶
func LedgerEntryToLedgerKeyHash(ledgerEntry xdr.LedgerEntry) string
func PanicOnError ¶
func PanicOnError(err error)
PanicOnError is a function that panics if the provided error is not nil
Types ¶
type Claimant ¶
type Claimant struct { Destination string `json:"destination"` Predicate xdr.ClaimPredicate `json:"predicate"` }
Claimants
type HistoryArchiveLedgerAndLCM ¶
type HistoryArchiveLedgerAndLCM struct { Ledger historyarchive.Ledger LCM xdr.LedgerCloseMeta }
type Path ¶
type Path struct { AssetCode string `json:"asset_code"` AssetIssuer string `json:"asset_issuer"` AssetType string `json:"asset_type"` }
Path is a representation of an asset without an ID that forms part of a path in a path payment