paths

package
v0.0.0-...-5c63435 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2018 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package paths provides utilities and facilities for payment paths as needed by horizon. Most importantly, it provides the Finder interface, allowing for pluggable path finding back ends.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Finder

type Finder interface {
	Find(Query) ([]Path, error)
}

Finder finds paths.

type Path

type Path struct {
	Path        []xdr.Asset
	Source      xdr.Asset
	Destination xdr.Asset
	// represents the source assets to be used as `sendMax` field for a `PathPaymentOp` struct
	Cost xdr.Int64
}

Path is the result returned by a path finder and is tied to the DestinationAmount used in the input query

type Query

type Query struct {
	DestinationAddress string
	DestinationAsset   xdr.Asset
	DestinationAmount  xdr.Int64
	SourceAssets       []xdr.Asset
}

Query is a query for paths

Jump to

Keyboard shortcuts

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