pub struct ZTokenDataMut<'a> {
pub delegate: <Option<Pubkey> as ZeroCopyAtMut<'a>>::ZeroCopyAtMut,
pub state: <u8 as ZeroCopyAtMut<'a>>::ZeroCopyAtMut,
pub tlv: <Option<Vec<ExtensionStruct>> as ZeroCopyAtMut<'a>>::ZeroCopyAtMut,
/* private fields */
}Fields§
§delegate: <Option<Pubkey> as ZeroCopyAtMut<'a>>::ZeroCopyAtMut§state: <u8 as ZeroCopyAtMut<'a>>::ZeroCopyAtMut§tlv: <Option<Vec<ExtensionStruct>> as ZeroCopyAtMut<'a>>::ZeroCopyAtMutImplementations§
Source§impl<'a> ZTokenDataMut<'a>
impl<'a> ZTokenDataMut<'a>
Sourcepub fn set(
&mut self,
mint: Pubkey,
owner: Pubkey,
amount: impl ZeroCopyNumTrait,
delegate: Option<Pubkey>,
state: CompressedTokenAccountState,
tlv_data: Option<&[ZExtensionInstructionData<'_>]>,
) -> Result<(), TokenError>
pub fn set( &mut self, mint: Pubkey, owner: Pubkey, amount: impl ZeroCopyNumTrait, delegate: Option<Pubkey>, state: CompressedTokenAccountState, tlv_data: Option<&[ZExtensionInstructionData<'_>]>, ) -> Result<(), TokenError>
Set all fields of the TokenData struct at once. All data must be allocated before calling this function.
Trait Implementations§
Source§impl<'a> Debug for ZTokenDataMut<'a>
impl<'a> Debug for ZTokenDataMut<'a>
Source§impl<'a> Deref for ZTokenDataMut<'a>
impl<'a> Deref for ZTokenDataMut<'a>
Auto Trait Implementations§
impl<'a> Freeze for ZTokenDataMut<'a>
impl<'a> RefUnwindSafe for ZTokenDataMut<'a>
impl<'a> Send for ZTokenDataMut<'a>
impl<'a> Sync for ZTokenDataMut<'a>
impl<'a> Unpin for ZTokenDataMut<'a>
impl<'a> !UnwindSafe for ZTokenDataMut<'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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more