Struct stellar_client::endpoint::ledger::Transactions[][src]

pub struct Transactions { /* fields omitted */ }

Represents the transactions for ledger endpoint on the stellar horizon server. The endpoint will return all the transactions for a single ledger in the chain.

https://www.stellar.org/developers/horizon/reference/endpoints/transactions-for-ledger.html

Example

use stellar_client::sync::Client;
use stellar_client::endpoint::{ledger, transaction, Limit};

let client   = Client::horizon_test().unwrap();

// Grab transactions and associated ledger to ensure a ledger sequence with transactions
let txns = client.request(transaction::All::default().with_limit(1)).unwrap();
let txn = &txns.records()[0];
let sequence = txn.ledger();

// Now we issue a request for that ledgers transactions
let endpoint = ledger::Transactions::new(sequence);
let ledger_txns = client.request(endpoint).unwrap();

assert!(ledger_txns.records().len() > 0);

Methods

impl Transactions
[src]

Creates a new ledger::Transactions endpoint struct.

use stellar_client::endpoint::ledger;

let txns = ledger::Transactions::new(123);

Trait Implementations

impl Debug for Transactions
[src]

Formats the value using the given formatter. Read more

impl Clone for Transactions
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Cursor for Transactions
[src]

Sets a cursor on the struct and returns an owned version.

Returns the cursor that has been set, if it has been set.

impl Limit for Transactions
[src]

Sets a limit on the struct and returns an owned version.

Returns the limit or None.

impl Order for Transactions
[src]

Sets the order on the struct and returns an owned version.

Returns the order that has been set, if it has been set.

impl IntoRequest for Transactions
[src]

The deserializable type that is expected to come back from the stellar server.

The request body to be sent to stellar. Generally this is just a () unit. Converts the implementing struct into an http request. Read more

Auto Trait Implementations