pub struct GlvPricing {
pub glv_token: Pubkey,
pub market_token: Pubkey,
pub supply: u64,
pub value_maximized: bool,
pub value: u128,
pub input_amount: u64,
pub input_value: u128,
pub output_amount: u64,
pub kind: GlvPricingKind,
}
Expand description
GLV pricing event.
Fields§
§glv_token: Pubkey
GLV token.
market_token: Pubkey
Market token.
supply: u64
The supply of the GLV tokens.
value_maximized: bool
Whether the value
is maximized.
value: u128
Total value of the GLV.
input_amount: u64
Input amount.
- For GLV deposit, this is the total amount of market tokens received.
- For GLV withdrawal, this is the amount of GLV tokens received.
input_value: u128
The value of the input amount.
output_amount: u64
Output amount.
- For GLV deposit, this will be the amount of GLV tokens to be minted.
- For GLV withdrawal, this will be the amount of market tokens to be burned.
kind: GlvPricingKind
The type of GLV pricing.
Trait Implementations§
Source§impl BorshDeserialize for GlvPricingwhere
Pubkey: BorshDeserialize,
u64: BorshDeserialize,
bool: BorshDeserialize,
u128: BorshDeserialize,
GlvPricingKind: BorshDeserialize,
impl BorshDeserialize for GlvPricingwhere
Pubkey: BorshDeserialize,
u64: BorshDeserialize,
bool: BorshDeserialize,
u128: BorshDeserialize,
GlvPricingKind: 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 GlvPricingwhere
Pubkey: BorshSerialize,
u64: BorshSerialize,
bool: BorshSerialize,
u128: BorshSerialize,
GlvPricingKind: BorshSerialize,
impl BorshSerialize for GlvPricingwhere
Pubkey: BorshSerialize,
u64: BorshSerialize,
bool: BorshSerialize,
u128: BorshSerialize,
GlvPricingKind: BorshSerialize,
Source§impl Clone for GlvPricing
impl Clone for GlvPricing
Source§fn clone(&self) -> GlvPricing
fn clone(&self) -> GlvPricing
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 GlvPricing
impl Debug for GlvPricing
Source§impl Discriminator for GlvPricing
impl Discriminator for GlvPricing
const DISCRIMINATOR: [u8; 8]
fn discriminator() -> [u8; 8]
Source§impl Event for GlvPricing
impl Event for GlvPricing
Source§impl InitSpace for GlvPricing
impl InitSpace for GlvPricing
Source§const INIT_SPACE: usize = 122usize
const INIT_SPACE: usize = 122usize
Init Space.
Source§impl Space for GlvPricing
impl Space for GlvPricing
const INIT_SPACE: usize = 122usize
Auto Trait Implementations§
impl Freeze for GlvPricing
impl RefUnwindSafe for GlvPricing
impl Send for GlvPricing
impl Sync for GlvPricing
impl Unpin for GlvPricing
impl UnwindSafe for GlvPricing
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§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