Struct mango_v4_client::swap::sanctum_state::StakePool
source · #[repr(C)]pub struct StakePool {Show 30 fields
pub account_type: AccountType,
pub manager: Pubkey,
pub staker: Pubkey,
pub stake_deposit_authority: Pubkey,
pub stake_withdraw_bump_seed: u8,
pub validator_list: Pubkey,
pub reserve_stake: Pubkey,
pub pool_mint: Pubkey,
pub manager_fee_account: Pubkey,
pub token_program_id: Pubkey,
pub total_lamports: u64,
pub pool_token_supply: u64,
pub last_update_epoch: u64,
pub lockup: Lockup,
pub epoch_fee: Fee,
pub next_epoch_fee: FutureEpoch<Fee>,
pub preferred_deposit_validator_vote_address: Option<Pubkey>,
pub preferred_withdraw_validator_vote_address: Option<Pubkey>,
pub stake_deposit_fee: Fee,
pub stake_withdrawal_fee: Fee,
pub next_stake_withdrawal_fee: FutureEpoch<Fee>,
pub stake_referral_fee: u8,
pub sol_deposit_authority: Option<Pubkey>,
pub sol_deposit_fee: Fee,
pub sol_referral_fee: u8,
pub sol_withdraw_authority: Option<Pubkey>,
pub sol_withdrawal_fee: Fee,
pub next_sol_withdrawal_fee: FutureEpoch<Fee>,
pub last_epoch_pool_token_supply: u64,
pub last_epoch_total_lamports: u64,
}
Fields§
§account_type: AccountType
Account type, must be StakePool currently
manager: Pubkey
Manager authority, allows for updating the staker, manager, and fee account
staker: Pubkey
Staker authority, allows for adding and removing validators, and managing stake distribution
Stake deposit authority
If a depositor pubkey is specified on initialization, then deposits must
be signed by this authority. If no deposit authority is specified,
then the stake pool will default to the result of:
Pubkey::find_program_address( &[&stake_pool_address.as_ref(), b"deposit"], program_id, )
stake_withdraw_bump_seed: u8
Stake withdrawal authority bump seed
for create_program_address(&[state::StakePool account, "withdrawal"])
validator_list: Pubkey
Validator stake list storage account
reserve_stake: Pubkey
Reserve stake account, holds deactivated stake
pool_mint: Pubkey
Pool Mint
manager_fee_account: Pubkey
Manager fee account
token_program_id: Pubkey
Pool token program id
total_lamports: u64
Total stake under management.
Note that if last_update_epoch
does not match the current epoch then
this field may not be accurate
pool_token_supply: u64
Total supply of pool tokens (should always match the supply in the Pool Mint)
last_update_epoch: u64
Last epoch the total_lamports
field was updated
lockup: Lockup
Lockup that all stakes in the pool must have
epoch_fee: Fee
Fee taken as a proportion of rewards each epoch
next_epoch_fee: FutureEpoch<Fee>
Fee for next epoch
preferred_deposit_validator_vote_address: Option<Pubkey>
Preferred deposit validator vote account pubkey
preferred_withdraw_validator_vote_address: Option<Pubkey>
Preferred withdraw validator vote account pubkey
stake_deposit_fee: Fee
Fee assessed on stake deposits
stake_withdrawal_fee: Fee
Fee assessed on withdrawals
next_stake_withdrawal_fee: FutureEpoch<Fee>
Future stake withdrawal fee, to be set for the following epoch
stake_referral_fee: u8
Fees paid out to referrers on referred stake deposits.
Expressed as a percentage (0 - 100) of deposit fees.
i.e. stake_deposit_fee
% of stake deposited is collected as deposit
fees for every deposit and stake_referral_fee
% of the collected
stake deposit fees is paid out to the referrer
Toggles whether the DepositSol
instruction requires a signature from
this sol_deposit_authority
sol_deposit_fee: Fee
Fee assessed on SOL deposits
sol_referral_fee: u8
Fees paid out to referrers on referred SOL deposits.
Expressed as a percentage (0 - 100) of SOL deposit fees.
i.e. sol_deposit_fee
% of SOL deposited is collected as deposit fees
for every deposit and sol_referral_fee
% of the collected SOL
deposit fees is paid out to the referrer
Toggles whether the WithdrawSol
instruction requires a signature from
the deposit_authority
sol_withdrawal_fee: Fee
Fee assessed on SOL withdrawals
next_sol_withdrawal_fee: FutureEpoch<Fee>
Future SOL withdrawal fee, to be set for the following epoch
last_epoch_pool_token_supply: u64
Last epoch’s total pool tokens, used only for APR estimation
last_epoch_total_lamports: u64
Last epoch’s total lamports, used only for APR estimation
Trait Implementations§
source§impl BorshDeserialize for StakePoolwhere
AccountType: BorshDeserialize,
Pubkey: BorshDeserialize,
u8: BorshDeserialize,
u64: BorshDeserialize,
Lockup: BorshDeserialize,
Fee: BorshDeserialize,
FutureEpoch<Fee>: BorshDeserialize,
Option<Pubkey>: BorshDeserialize,
impl BorshDeserialize for StakePoolwhere AccountType: BorshDeserialize, Pubkey: BorshDeserialize, u8: BorshDeserialize, u64: BorshDeserialize, Lockup: BorshDeserialize, Fee: BorshDeserialize, FutureEpoch<Fee>: BorshDeserialize, Option<Pubkey>: BorshDeserialize,
fn deserialize_reader<R: Read>(reader: &mut R) -> Result<Self, Error>
§fn deserialize(buf: &mut &[u8]) -> Result<Self, Error>
fn deserialize(buf: &mut &[u8]) -> Result<Self, Error>
§fn try_from_slice(v: &[u8]) -> Result<Self, Error>
fn try_from_slice(v: &[u8]) -> Result<Self, Error>
fn try_from_reader<R>(reader: &mut R) -> Result<Self, Error>where R: Read,
source§impl PartialEq<StakePool> for StakePool
impl PartialEq<StakePool> for StakePool
impl StructuralPartialEq for StakePool
Auto Trait Implementations§
impl RefUnwindSafe for StakePool
impl Send for StakePool
impl Sync for StakePool
impl Unpin for StakePool
impl UnwindSafe for StakePool
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere T: 'a,
§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> CheckedAs for T
impl<T> CheckedAs for T
source§fn checked_as<Dst>(self) -> Option<Dst>where
T: CheckedCast<Dst>,
fn checked_as<Dst>(self) -> Option<Dst>where T: CheckedCast<Dst>,
source§impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere
Src: CheckedCast<Dst>,
impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere Src: CheckedCast<Dst>,
source§fn checked_cast_from(src: Src) -> Option<Dst>
fn checked_cast_from(src: Src) -> Option<Dst>
source§impl<T> DerefOrBorrow<T> for Twhere
T: ?Sized,
impl<T> DerefOrBorrow<T> for Twhere T: ?Sized,
fn deref_or_borrow(&self) -> &T
source§impl<T> DerefOrBorrowMut<T> for Twhere
T: ?Sized,
impl<T> DerefOrBorrowMut<T> for Twhere T: ?Sized,
fn deref_or_borrow_mut(&mut self) -> &mut T
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request