pub struct DynamicBondingCurvePoolData {Show 32 fields
pub config: Pubkey,
pub creator: Pubkey,
pub base_mint: Pubkey,
pub base_vault: Pubkey,
pub quote_vault: Pubkey,
pub base_reserve: u64,
pub quote_reserve: u64,
pub protocol_base_fee: u64,
pub protocol_quote_fee: u64,
pub partner_base_fee: u64,
pub partner_quote_fee: u64,
pub creator_base_fee: u64,
pub creator_quote_fee: u64,
pub sqrt_price: u128,
pub activation_point: u64,
pub finish_curve_timestamp: u64,
pub pool_type: u8,
pub is_migrated: bool,
pub is_partner_withdraw_surplus: bool,
pub is_protocol_withdraw_surplus: bool,
pub migration_progress: u8,
pub is_withdraw_leftover: bool,
pub is_creator_withdraw_surplus: bool,
pub migration_fee_withdraw_status: u8,
pub total_protocol_base_fee: u64,
pub total_protocol_quote_fee: u64,
pub total_trading_base_fee: u64,
pub total_trading_quote_fee: u64,
pub creation_fee_bits: u8,
pub has_creation_fee: bool,
pub creation_fee_claimed: bool,
pub volatility_tracker: VolatilityTrackerData,
}Fields§
§config: Pubkey§creator: Pubkey§base_mint: Pubkey§base_vault: Pubkey§quote_vault: Pubkey§base_reserve: u64§quote_reserve: u64§protocol_base_fee: u64§protocol_quote_fee: u64§partner_base_fee: u64§partner_quote_fee: u64§creator_base_fee: u64§creator_quote_fee: u64§sqrt_price: u128§activation_point: u64§finish_curve_timestamp: u64§pool_type: u8§is_migrated: bool§is_partner_withdraw_surplus: bool§is_protocol_withdraw_surplus: bool§migration_progress: u8§is_withdraw_leftover: bool§is_creator_withdraw_surplus: bool§migration_fee_withdraw_status: u8§total_protocol_base_fee: u64§total_protocol_quote_fee: u64§total_trading_base_fee: u64§total_trading_quote_fee: u64§creation_fee_bits: u8§has_creation_fee: bool§creation_fee_claimed: bool§volatility_tracker: VolatilityTrackerDataImplementations§
Source§impl DynamicBondingCurvePoolData
impl DynamicBondingCurvePoolData
Sourcepub fn get_pool_type_str(&self) -> &'static str
pub fn get_pool_type_str(&self) -> &'static str
Get pool type as string
Sourcepub fn get_migration_progress_str(&self) -> &'static str
pub fn get_migration_progress_str(&self) -> &'static str
Get migration progress as string
Sourcepub fn has_creation_fee(&self) -> bool
pub fn has_creation_fee(&self) -> bool
Get creation fee status
Sourcepub fn creation_fee_claimed(&self) -> bool
pub fn creation_fee_claimed(&self) -> bool
Get creation fee claimed status
Sourcepub fn eligible_to_withdraw_migration_fee(&self, mask: u8) -> bool
pub fn eligible_to_withdraw_migration_fee(&self, mask: u8) -> bool
Get migration fee withdraw eligibility
Sourcepub fn is_curve_complete(&self, migration_threshold: u64) -> bool
pub fn is_curve_complete(&self, migration_threshold: u64) -> bool
Check if curve is complete
Sourcepub fn get_protocol_and_trading_base_fee(&self) -> u64
pub fn get_protocol_and_trading_base_fee(&self) -> u64
Get protocol and trading base fee total
Sourcepub fn get_total_surplus(&self, migration_threshold: u64) -> Option<u64>
pub fn get_total_surplus(&self, migration_threshold: u64) -> Option<u64>
Get total surplus
Sourcepub fn get_volatility_accumulator_percentage(&self) -> f64
pub fn get_volatility_accumulator_percentage(&self) -> f64
Get volatility accumulator as percentage
Sourcepub fn get_protocol_fees(&self) -> (u64, u64)
pub fn get_protocol_fees(&self) -> (u64, u64)
Get protocol fees
Sourcepub fn get_partner_fees(&self) -> (u64, u64)
pub fn get_partner_fees(&self) -> (u64, u64)
Get partner fees
Sourcepub fn get_creator_fees(&self) -> (u64, u64)
pub fn get_creator_fees(&self) -> (u64, u64)
Get creator fees
Sourcepub fn get_reserves(&self) -> (u64, u64)
pub fn get_reserves(&self) -> (u64, u64)
Get all reserves
Sourcepub fn is_migrated(&self) -> bool
pub fn is_migrated(&self) -> bool
Check if pool is migrated
Sourcepub fn can_partner_withdraw_surplus(&self) -> bool
pub fn can_partner_withdraw_surplus(&self) -> bool
Check if partner can withdraw surplus
Sourcepub fn can_protocol_withdraw_surplus(&self) -> bool
pub fn can_protocol_withdraw_surplus(&self) -> bool
Check if protocol can withdraw surplus
Sourcepub fn can_creator_withdraw_surplus(&self) -> bool
pub fn can_creator_withdraw_surplus(&self) -> bool
Check if creator can withdraw surplus
Sourcepub fn can_withdraw_leftover(&self) -> bool
pub fn can_withdraw_leftover(&self) -> bool
Check if leftover can be withdrawn
Sourcepub fn get_metrics(&self) -> PoolMetricsData
pub fn get_metrics(&self) -> PoolMetricsData
Get pool metrics
Trait Implementations§
Source§impl Clone for DynamicBondingCurvePoolData
impl Clone for DynamicBondingCurvePoolData
Source§fn clone(&self) -> DynamicBondingCurvePoolData
fn clone(&self) -> DynamicBondingCurvePoolData
Returns a duplicate 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 moreAuto Trait Implementations§
impl Freeze for DynamicBondingCurvePoolData
impl RefUnwindSafe for DynamicBondingCurvePoolData
impl Send for DynamicBondingCurvePoolData
impl Sync for DynamicBondingCurvePoolData
impl Unpin for DynamicBondingCurvePoolData
impl UnwindSafe for DynamicBondingCurvePoolData
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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