pub struct Ledger<'a> {
pub common_fields: CommonFields<'a>,
pub accounts: Option<bool>,
pub binary: Option<bool>,
pub expand: Option<bool>,
pub full: Option<bool>,
pub ledger_hash: Option<Cow<'a, str>>,
pub ledger_index: Option<Cow<'a, str>>,
pub owner_funds: Option<bool>,
pub queue: Option<bool>,
pub transactions: Option<bool>,
}
Expand description
Retrieve information about the public ledger.
See Ledger Data:
<https://xrpl.org/ledger.html>
Fields§
§common_fields: CommonFields<'a>
The common fields shared by all requests.
accounts: Option<bool>
Admin required. If true, return information on accounts in the ledger. Ignored if you did not specify a ledger version. Defaults to false. Caution: This returns a very large amount of data!
binary: Option<bool>
If true, and transactions and expand are both also true, return transaction information in binary format (hexadecimal string) instead of JSON format.
expand: Option<bool>
Provide full JSON-formatted information for transaction/account information instead of only hashes. Defaults to false. Ignored unless you request transactions, accounts, or both.
full: Option<bool>
Admin required. If true, return full information on the entire ledger. Ignored if you did not specify a ledger version. Defaults to false. (Equivalent to enabling transactions, accounts, and expand.) Caution: This is a very large amount of data – on the order of several hundred megabytes!
ledger_hash: Option<Cow<'a, str>>
A 20-byte hex string for the ledger version to use.
ledger_index: Option<Cow<'a, str>>
The ledger index of the ledger to use, or a shortcut string to choose a ledger automatically.
owner_funds: Option<bool>
If true, include owner_funds field in the metadata of OfferCreate transactions in the response. Defaults to false. Ignored unless transactions are included and expand is true.
queue: Option<bool>
If true, and the command is requesting the current ledger, includes an array of queued transactions in the results.
transactions: Option<bool>
If true, return information on transactions in the specified ledger version. Defaults to false. Ignored if you did not specify a ledger version.
Implementations§
Trait Implementations§
Source§impl<'de, 'a> Deserialize<'de> for Ledger<'a>
impl<'de, 'a> Deserialize<'de> for Ledger<'a>
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl<'a> From<Ledger<'a>> for XRPLRequest<'a>
impl<'a> From<Ledger<'a>> for XRPLRequest<'a>
Source§impl<'a> Model for Ledger<'a>
impl<'a> Model for Ledger<'a>
Source§fn get_errors(&self) -> XRPLModelResult<()>
fn get_errors(&self) -> XRPLModelResult<()>
Source§fn validate(&self) -> XRPLModelResult<()>
fn validate(&self) -> XRPLModelResult<()>
get_errors
if there was one.Source§impl<'a> Request<'a> for Ledger<'a>
impl<'a> Request<'a> for Ledger<'a>
fn get_common_fields(&self) -> &CommonFields<'a>
fn get_common_fields_mut(&mut self) -> &mut CommonFields<'a>
impl<'a> Eq for Ledger<'a>
impl<'a> StructuralPartialEq for Ledger<'a>
Auto Trait Implementations§
impl<'a> Freeze for Ledger<'a>
impl<'a> RefUnwindSafe for Ledger<'a>
impl<'a> Send for Ledger<'a>
impl<'a> Sync for Ledger<'a>
impl<'a> Unpin for Ledger<'a>
impl<'a> UnwindSafe for Ledger<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.