#[repr(packed)]pub struct TokenizedPositionState {
pub bump: u8,
pub mint: Pubkey,
pub pool_id: Pubkey,
pub tick_lower: i32,
pub tick_upper: i32,
pub liquidity: u64,
pub fee_growth_inside_0_last_x32: u64,
pub fee_growth_inside_1_last_x32: u64,
pub tokens_owed_0: u64,
pub tokens_owed_1: u64,
}Expand description
Position wrapped as an SPL non-fungible token
PDA of [POSITION_SEED, mint_address]
Fields
bump: u8Bump to identify PDA
mint: PubkeyMint address of the tokenized position
pool_id: PubkeyThe ID of the pool with which this token is connected
tick_lower: i32The lower bound tick of the position
tick_upper: i32The upper bound tick of the position
liquidity: u64The amount of liquidity owned by this position
fee_growth_inside_0_last_x32: u64The token_0 fee growth of the aggregate position as of the last action on the individual position
fee_growth_inside_1_last_x32: u64The token_0 fee growth of the aggregate position as of the last action on the individual position
tokens_owed_0: u64How many uncollected token_0 are owed to the position, as of the last computation
tokens_owed_1: u64How many uncollected token_0 are owed to the position, as of the last computation
Trait Implementations
sourceimpl AccountDeserialize for TokenizedPositionState
impl AccountDeserialize for TokenizedPositionState
sourcefn try_deserialize(buf: &mut &[u8]) -> Result<Self>
fn try_deserialize(buf: &mut &[u8]) -> Result<Self>
Deserializes previously initialized account data. Should fail for all
uninitialized accounts, where the bytes are zeroed. Implementations
should be unique to a particular account type so that one can never
successfully deserialize the data of one account type into another.
For example, if the SPL token program were to implement this trait,
it should be impossible to deserialize a Mint account into a token
Account. Read more
sourceimpl Clone for TokenizedPositionState
impl Clone for TokenizedPositionState
sourcefn clone(&self) -> TokenizedPositionState
fn clone(&self) -> TokenizedPositionState
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Default for TokenizedPositionState
impl Default for TokenizedPositionState
sourcefn default() -> TokenizedPositionState
fn default() -> TokenizedPositionState
Returns the “default value” for a type. Read more
sourceimpl Discriminator for TokenizedPositionState
impl Discriminator for TokenizedPositionState
fn discriminator() -> [u8; 8]
sourceimpl Owner for TokenizedPositionState
impl Owner for TokenizedPositionState
sourceimpl Zeroable for TokenizedPositionState
impl Zeroable for TokenizedPositionState
impl Copy for TokenizedPositionState
impl Pod for TokenizedPositionState
impl ZeroCopy for TokenizedPositionState
Auto Trait Implementations
impl RefUnwindSafe for TokenizedPositionState
impl Send for TokenizedPositionState
impl Sync for TokenizedPositionState
impl Unpin for TokenizedPositionState
impl UnwindSafe for TokenizedPositionState
Blanket Implementations
impl<T> AbiExample for T
impl<T> AbiExample for T
default fn example() -> T
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> CheckedBitPattern for T where
T: AnyBitPattern,
impl<T> CheckedBitPattern for T where
T: AnyBitPattern,
type Bits = T
type Bits = T
Self must have the same layout as the specified Bits except for
the possible invalid bit patterns being checked during is_valid_bit_pattern. Read more
fn is_valid_bit_pattern(_bits: &T) -> bool
fn is_valid_bit_pattern(_bits: &T) -> bool
If this function returns true, then it must be valid to reinterpret bits as &Self.
impl<T> Pointable for T
impl<T> Pointable for T
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more