pub struct TransferChecked<'a> {
pub from: &'a AccountView,
pub mint: &'a AccountView,
pub to: &'a AccountView,
pub authority: &'a AccountView,
pub amount: u64,
pub decimals: u8,
}Expand description
Transfer Tokens from one Token Account to another.
§Accounts:
[WRITE]The source account.[]The token mint.[WRITE]The destination account.[SIGNER]The source account’s owner/delegate.
Fields§
§from: &'a AccountViewSender account.
mint: &'a AccountViewMint Account
to: &'a AccountViewRecipient account.
Authority account.
amount: u64Amount of micro-tokens to transfer.
decimals: u8Decimal for the Token
Implementations§
Source§impl TransferChecked<'_>
impl TransferChecked<'_>
pub fn invoke(&self) -> Result<(), ProgramError>
pub fn invoke_signed( &self, signers: &[Signer<'_, '_>], ) -> Result<(), ProgramError>
Auto Trait Implementations§
impl<'a> Freeze for TransferChecked<'a>
impl<'a> RefUnwindSafe for TransferChecked<'a>
impl<'a> !Send for TransferChecked<'a>
impl<'a> !Sync for TransferChecked<'a>
impl<'a> Unpin for TransferChecked<'a>
impl<'a> UnsafeUnpin for TransferChecked<'a>
impl<'a> UnwindSafe for TransferChecked<'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
Mutably borrows from an owned value. Read more