Struct mango_v4::instruction::TokenRegister
source · pub struct TokenRegister {Show 31 fields
pub token_index: TokenIndex,
pub name: String,
pub oracle_config: OracleConfigParams,
pub interest_rate_params: InterestRateParams,
pub loan_fee_rate: f32,
pub loan_origination_fee_rate: f32,
pub maint_asset_weight: f32,
pub init_asset_weight: f32,
pub maint_liab_weight: f32,
pub init_liab_weight: f32,
pub liquidation_fee: f32,
pub stable_price_delay_interval_seconds: u32,
pub stable_price_delay_growth_limit: f32,
pub stable_price_growth_limit: f32,
pub min_vault_to_deposits_ratio: f64,
pub net_borrow_limit_window_size_ts: u64,
pub net_borrow_limit_per_window_quote: i64,
pub borrow_weight_scale_start_quote: f64,
pub deposit_weight_scale_start_quote: f64,
pub reduce_only: u8,
pub token_conditional_swap_taker_fee_rate: f32,
pub token_conditional_swap_maker_fee_rate: f32,
pub flash_loan_swap_fee_rate: f32,
pub interest_curve_scaling: f32,
pub interest_target_utilization: f32,
pub group_insurance_fund: bool,
pub deposit_limit: u64,
pub zero_util_rate: f32,
pub platform_liquidation_fee: f32,
pub disable_asset_liquidation: bool,
pub collateral_fee_per_day: f32,
}
Expand description
Instruction.
Fields§
§token_index: TokenIndex
§name: String
§oracle_config: OracleConfigParams
§interest_rate_params: InterestRateParams
§loan_fee_rate: f32
§loan_origination_fee_rate: f32
§maint_asset_weight: f32
§init_asset_weight: f32
§maint_liab_weight: f32
§init_liab_weight: f32
§liquidation_fee: f32
§stable_price_delay_interval_seconds: u32
§stable_price_delay_growth_limit: f32
§stable_price_growth_limit: f32
§min_vault_to_deposits_ratio: f64
§net_borrow_limit_window_size_ts: u64
§net_borrow_limit_per_window_quote: i64
§borrow_weight_scale_start_quote: f64
§deposit_weight_scale_start_quote: f64
§reduce_only: u8
§token_conditional_swap_taker_fee_rate: f32
§token_conditional_swap_maker_fee_rate: f32
§flash_loan_swap_fee_rate: f32
§interest_curve_scaling: f32
§interest_target_utilization: f32
§group_insurance_fund: bool
§deposit_limit: u64
§zero_util_rate: f32
§platform_liquidation_fee: f32
§disable_asset_liquidation: bool
§collateral_fee_per_day: f32
Trait Implementations§
source§impl BorshDeserialize for TokenRegisterwhere
TokenIndex: BorshDeserialize,
String: BorshDeserialize,
OracleConfigParams: BorshDeserialize,
InterestRateParams: BorshDeserialize,
f32: BorshDeserialize,
u32: BorshDeserialize,
f64: BorshDeserialize,
u64: BorshDeserialize,
i64: BorshDeserialize,
u8: BorshDeserialize,
bool: BorshDeserialize,
impl BorshDeserialize for TokenRegisterwhere TokenIndex: BorshDeserialize, String: BorshDeserialize, OracleConfigParams: BorshDeserialize, InterestRateParams: BorshDeserialize, f32: BorshDeserialize, u32: BorshDeserialize, f64: BorshDeserialize, u64: BorshDeserialize, i64: BorshDeserialize, u8: BorshDeserialize, bool: 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>
Deserializes this instance from a given slice of bytes.
Updates the buffer to point at the remaining bytes.
§fn try_from_slice(v: &[u8]) -> Result<Self, Error>
fn try_from_slice(v: &[u8]) -> Result<Self, Error>
Deserialize this instance from a slice of bytes.
fn try_from_reader<R>(reader: &mut R) -> Result<Self, Error>where R: Read,
source§impl BorshSerialize for TokenRegisterwhere
TokenIndex: BorshSerialize,
String: BorshSerialize,
OracleConfigParams: BorshSerialize,
InterestRateParams: BorshSerialize,
f32: BorshSerialize,
u32: BorshSerialize,
f64: BorshSerialize,
u64: BorshSerialize,
i64: BorshSerialize,
u8: BorshSerialize,
bool: BorshSerialize,
impl BorshSerialize for TokenRegisterwhere TokenIndex: BorshSerialize, String: BorshSerialize, OracleConfigParams: BorshSerialize, InterestRateParams: BorshSerialize, f32: BorshSerialize, u32: BorshSerialize, f64: BorshSerialize, u64: BorshSerialize, i64: BorshSerialize, u8: BorshSerialize, bool: BorshSerialize,
source§impl Discriminator for TokenRegister
impl Discriminator for TokenRegister
const DISCRIMINATOR: [u8; 8] = _
fn discriminator() -> [u8; 8]
Auto Trait Implementations§
impl RefUnwindSafe for TokenRegister
impl Send for TokenRegister
impl Sync for TokenRegister
impl Unpin for TokenRegister
impl UnwindSafe for TokenRegister
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>,
Casts the value.
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>
Casts the value.
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<Src, Dst> LosslessTryInto<Dst> for Srcwhere
Dst: LosslessTryFrom<Src>,
impl<Src, Dst> LosslessTryInto<Dst> for Srcwhere Dst: LosslessTryFrom<Src>,
source§fn lossless_try_into(self) -> Option<Dst>
fn lossless_try_into(self) -> Option<Dst>
Performs the conversion.
source§impl<Src, Dst> LossyInto<Dst> for Srcwhere
Dst: LossyFrom<Src>,
impl<Src, Dst> LossyInto<Dst> for Srcwhere Dst: LossyFrom<Src>,
source§fn lossy_into(self) -> Dst
fn lossy_into(self) -> Dst
Performs the conversion.
source§impl<T> OverflowingAs for T
impl<T> OverflowingAs for T
source§fn overflowing_as<Dst>(self) -> (Dst, bool)where
T: OverflowingCast<Dst>,
fn overflowing_as<Dst>(self) -> (Dst, bool)where T: OverflowingCast<Dst>,
Casts the value.
source§impl<Src, Dst> OverflowingCastFrom<Src> for Dstwhere
Src: OverflowingCast<Dst>,
impl<Src, Dst> OverflowingCastFrom<Src> for Dstwhere Src: OverflowingCast<Dst>,
source§fn overflowing_cast_from(src: Src) -> (Dst, bool)
fn overflowing_cast_from(src: Src) -> (Dst, bool)
Casts the value.
§impl<T> Pointable for T
impl<T> Pointable for T
source§impl<T> SaturatingAs for T
impl<T> SaturatingAs for T
source§fn saturating_as<Dst>(self) -> Dstwhere
T: SaturatingCast<Dst>,
fn saturating_as<Dst>(self) -> Dstwhere T: SaturatingCast<Dst>,
Casts the value.
source§impl<Src, Dst> SaturatingCastFrom<Src> for Dstwhere
Src: SaturatingCast<Dst>,
impl<Src, Dst> SaturatingCastFrom<Src> for Dstwhere Src: SaturatingCast<Dst>,
source§fn saturating_cast_from(src: Src) -> Dst
fn saturating_cast_from(src: Src) -> Dst
Casts the value.
source§impl<T> UnwrappedAs for T
impl<T> UnwrappedAs for T
source§fn unwrapped_as<Dst>(self) -> Dstwhere
T: UnwrappedCast<Dst>,
fn unwrapped_as<Dst>(self) -> Dstwhere T: UnwrappedCast<Dst>,
Casts the value.
source§impl<Src, Dst> UnwrappedCastFrom<Src> for Dstwhere
Src: UnwrappedCast<Dst>,
impl<Src, Dst> UnwrappedCastFrom<Src> for Dstwhere Src: UnwrappedCast<Dst>,
source§fn unwrapped_cast_from(src: Src) -> Dst
fn unwrapped_cast_from(src: Src) -> Dst
Casts the value.
source§impl<T> WithSubscriber for T
impl<T> WithSubscriber for T
source§fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>where S: Into<Dispatch>,
source§fn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
source§impl<T> WrappingAs for T
impl<T> WrappingAs for T
source§fn wrapping_as<Dst>(self) -> Dstwhere
T: WrappingCast<Dst>,
fn wrapping_as<Dst>(self) -> Dstwhere T: WrappingCast<Dst>,
Casts the value.
source§impl<Src, Dst> WrappingCastFrom<Src> for Dstwhere
Src: WrappingCast<Dst>,
impl<Src, Dst> WrappingCastFrom<Src> for Dstwhere Src: WrappingCast<Dst>,
source§fn wrapping_cast_from(src: Src) -> Dst
fn wrapping_cast_from(src: Src) -> Dst
Casts the value.