pub struct CheckCash<'a> {
pub common_fields: CommonFields<'a, NoFlags>,
pub check_id: Cow<'a, str>,
pub amount: Option<Amount<'a>>,
pub deliver_min: Option<Amount<'a>>,
}
Expand description
Attempt to redeem a Check object in the ledger to receive up to the amount authorized by a corresponding CheckCreate transaction.
See CheckCash:
<https://xrpl.org/docs/references/protocol/transactions/types/checkcash>
Fields§
§common_fields: CommonFields<'a, NoFlags>
The base fields for all transaction models.
See Transaction Common Fields:
<https://xrpl.org/transaction-common-fields.html>
check_id: Cow<'a, str>
The ID of the Check ledger object to cash, as a 64-character hexadecimal string.
amount: Option<Amount<'a>>
Redeem the Check for exactly this amount, if possible. The currency must match that of the SendMax of the corresponding CheckCreate transaction. You must provide either this field or DeliverMin.
deliver_min: Option<Amount<'a>>
Redeem the Check for at least this amount and for as much as possible. The currency must match that of the SendMax of the corresponding CheckCreate transaction. You must provide either this field or Amount.
Implementations§
Source§impl<'a> CheckCash<'a>
impl<'a> CheckCash<'a>
pub fn new( account: Cow<'a, str>, account_txn_id: Option<Cow<'a, str>>, fee: Option<XRPAmount<'a>>, last_ledger_sequence: Option<u32>, memos: Option<Vec<Memo>>, sequence: Option<u32>, signers: Option<Vec<Signer>>, source_tag: Option<u32>, ticket_sequence: Option<u32>, check_id: Cow<'a, str>, amount: Option<Amount<'a>>, deliver_min: Option<Amount<'a>>, ) -> Self
pub fn with_amount(self, amount: Amount<'a>) -> Self
pub fn with_deliver_min(self, deliver_min: Amount<'a>) -> Self
Trait Implementations§
Source§impl<'a> CheckCashError for CheckCash<'a>
impl<'a> CheckCashError for CheckCash<'a>
fn _get_amount_and_deliver_min_error(&self) -> XRPLModelResult<()>
Source§impl<'a> CommonTransactionBuilder<'a, NoFlags> for CheckCash<'a>
impl<'a> CommonTransactionBuilder<'a, NoFlags> for CheckCash<'a>
Source§fn get_mut_common_fields(&mut self) -> &mut CommonFields<'a, NoFlags>
fn get_mut_common_fields(&mut self) -> &mut CommonFields<'a, NoFlags>
Source§fn with_sequence(self, sequence: u32) -> Selfwhere
Self: Sized,
fn with_sequence(self, sequence: u32) -> Selfwhere
Self: Sized,
Source§fn with_last_ledger_sequence(self, last_ledger_sequence: u32) -> Selfwhere
Self: Sized,
fn with_last_ledger_sequence(self, last_ledger_sequence: u32) -> Selfwhere
Self: Sized,
Source§fn with_source_tag(self, source_tag: u32) -> Selfwhere
Self: Sized,
fn with_source_tag(self, source_tag: u32) -> Selfwhere
Self: Sized,
Source§fn with_ticket_sequence(self, ticket_sequence: u32) -> Selfwhere
Self: Sized,
fn with_ticket_sequence(self, ticket_sequence: u32) -> Selfwhere
Self: Sized,
Source§impl<'de, 'a> Deserialize<'de> for CheckCash<'a>
impl<'de, 'a> Deserialize<'de> for CheckCash<'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> Model for CheckCash<'a>
impl<'a> Model for CheckCash<'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> Transaction<'a, NoFlags> for CheckCash<'a>
impl<'a> Transaction<'a, NoFlags> for CheckCash<'a>
fn get_transaction_type(&self) -> &TransactionType
fn get_common_fields(&self) -> &CommonFields<'_, NoFlags>
fn get_mut_common_fields(&mut self) -> &mut CommonFields<'a, NoFlags>
fn has_flag(&self, flag: &T) -> bool
fn get_field_value(&self, field: &str) -> XRPLModelResult<Option<String>>
fn is_signed(&self) -> bool
Source§impl<'a> ValidateCurrencies for CheckCash<'a>
impl<'a> ValidateCurrencies for CheckCash<'a>
fn validate_currencies(&self) -> XRPLModelResult<()>
impl<'a> Eq for CheckCash<'a>
impl<'a> StructuralPartialEq for CheckCash<'a>
Auto Trait Implementations§
impl<'a> Freeze for CheckCash<'a>
impl<'a> RefUnwindSafe for CheckCash<'a>
impl<'a> Send for CheckCash<'a>
impl<'a> Sync for CheckCash<'a>
impl<'a> Unpin for CheckCash<'a>
impl<'a> UnwindSafe for CheckCash<'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.