xlm

package
v0.0.0-...-15c384e Latest Latest
Warning

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

Go to latest
Published: Feb 11, 2025 License: Apache-2.0, MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckError

func CheckError(err error) errors.Status

Types

type Preconditions

type Preconditions struct {
	// Transaction is only valid during a certain time range (units are seconds).
	TimeBounds TimeBounds
	// Transaction is valid for ledger numbers n such that minLedger <= n
	MinLedgerSequence int64
}

Preconditions is a container for all transaction preconditions.

func (Preconditions) BuildXDR

func (prec Preconditions) BuildXDR() xdr.Preconditions

type TimeBounds

type TimeBounds struct {
	MinTime int64
	MaxTime int64
	// contains filtered or unexported fields
}

TimeBounds represents the time window during which a Stellar transaction is considered valid.

MinTime and MaxTime represent Stellar timebounds - a window of time over which the Transaction will be considered valid. In general, almost all Transactions benefit from setting an upper timebound, because once submitted, the status of a pending Transaction may remain unresolved for a long time if the network is congested. With an upper timebound, the submitter has a guaranteed time at which the Transaction is known to have either succeeded or failed, and can then take appropriate action (e.g. resubmit or mark as resolved).

Create a TimeBounds struct using NewTimeout()

func NewInfiniteTimeout

func NewInfiniteTimeout() TimeBounds

func NewTimeout

func NewTimeout(timeout time.Duration) TimeBounds

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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