Enum spl_token_2022::extension::AccountType
source · #[repr(u8)]pub enum AccountType {
Uninitialized = 0,
Mint = 1,
Account = 2,
}Expand description
Different kinds of accounts. Note that Mint, Account, and Multisig
types are determined exclusively by the size of the account, and are not
included in the account data. AccountType is only included if extensions
have been initialized.
Variants§
Uninitialized = 0
Marker for 0 data
Mint = 1
Mint account with additional extensions
Account = 2
Token holding account with additional extensions
Trait Implementations§
source§impl Clone for AccountType
impl Clone for AccountType
source§fn clone(&self) -> AccountType
fn clone(&self) -> AccountType
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for AccountType
impl Debug for AccountType
source§impl Default for AccountType
impl Default for AccountType
source§impl From<AccountType> for u8
impl From<AccountType> for u8
source§fn from(enum_value: AccountType) -> Self
fn from(enum_value: AccountType) -> Self
Converts to this type from the input type.
source§impl PartialEq for AccountType
impl PartialEq for AccountType
source§fn eq(&self, other: &AccountType) -> bool
fn eq(&self, other: &AccountType) -> bool
This method tests for
self and other values to be equal, and is used
by ==.source§impl TryFrom<u8> for AccountType
impl TryFrom<u8> for AccountType
§type Error = TryFromPrimitiveError<AccountType>
type Error = TryFromPrimitiveError<AccountType>
The type returned in the event of a conversion error.
source§impl TryFromPrimitive for AccountType
impl TryFromPrimitive for AccountType
type Primitive = u8
type Error = TryFromPrimitiveError<AccountType>
const NAME: &'static str = "AccountType"
fn try_from_primitive( number: Self::Primitive, ) -> Result<Self, TryFromPrimitiveError<Self>>
impl Copy for AccountType
impl StructuralPartialEq for AccountType
Auto Trait Implementations§
impl Freeze for AccountType
impl RefUnwindSafe for AccountType
impl Send for AccountType
impl Sync for AccountType
impl Unpin for AccountType
impl UnwindSafe for AccountType
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)source§impl<T> CloneToUninit for Twhere
T: Copy,
impl<T> CloneToUninit for Twhere
T: Copy,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)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