Show / Hide Table of Contents

Class PathfindingSource

The ledger a path search reads: accounts, their trust lines in the order the ledger keeps them, the MPTs they issue and hold, the index of order books, and the state the payment engine needs to rank the paths it finds. Built from a DexSnapshot or read from a node at one ledger.

Inheritance
object
PathfindingSource
Namespace: Xrpl.Amounts
Assembly: Xrpl.dll
Syntax
public abstract class PathfindingSource

Properties

| Edit this page View Source

Books

The order books the search can use.

Declaration
public IBookIndex Books { get; }
Property Value
Type Description
IBookIndex
| Edit this page View Source

LedgerSequence

The ledger's sequence, which breaks ties between equally good accounts as the node does.

Declaration
public uint LedgerSequence { get; }
Property Value
Type Description
uint
| Edit this page View Source

ReserveBase

The account reserve, in drops: an XRP payment must fund a new account with at least this.

Declaration
public ulong ReserveBase { get; }
Property Value
Type Description
ulong

Methods

| Edit this page View Source

FromNodeAsync(IXrplClient, IBookIndex, LedgerIndex, CancellationToken)

A search against a node, at one ledger: accounts and trust lines read as the search reaches them, and the state for ranking read along the paths it finds.

Declaration
public static Task<PathfindingSource> FromNodeAsync(IXrplClient client, IBookIndex books, LedgerIndex ledger = null, CancellationToken cancellationToken = default)
Parameters
Type Name Description
IXrplClient client

The node to read from.

IBookIndex books

The order books; see BookIndex.

LedgerIndex ledger

The ledger to read; the last validated one when null.

CancellationToken cancellationToken

Cancels the reads.

Returns
Type Description
Task<PathfindingSource>
| Edit this page View Source

FromSnapshot(DexSnapshot, IBookIndex, uint)

A search over a snapshot: its accounts and trust lines, and its books unless others are given.

Declaration
public static PathfindingSource FromSnapshot(DexSnapshot snapshot, IBookIndex books = null, uint ledgerSequence = 0)
Parameters
Type Name Description
DexSnapshot snapshot

The ledger state; its trust lines listed in the order they were created.

IBookIndex books

The order books; those of the snapshot's offers and pools when null.

uint ledgerSequence

The ledger's sequence, for the node's tie-break between accounts.

Returns
Type Description
PathfindingSource
  • Edit this page
  • View Source
In this article
Back to top Generated by DocFX