Struct gauge::Gaugemeister
source · [−]pub struct Gaugemeister {
pub base: Pubkey,
pub bump: u8,
pub rewarder: Pubkey,
pub operator: Pubkey,
pub locker: Pubkey,
pub foreman: Pubkey,
pub epoch_duration_seconds: u32,
pub current_rewards_epoch: u32,
pub next_epoch_starts_at: u64,
pub locker_token_mint: Pubkey,
pub locker_governor: Pubkey,
}
Expand description
Manages the rewards shares of all Gauges of a quarry_mine::rewarder.
Fields
base: Pubkey
Base.
bump: u8
Bump seed.
rewarder: Pubkey
The Rewarder.
operator: Pubkey
The Quarry Operator.
locker: Pubkey
The locked_voter::Locker.
foreman: Pubkey
Account which may enable/disable gauges on the Gaugemeister. May call the following instructions:
- gauge_enable
- gauge_disable
epoch_duration_seconds: u32
Number of seconds per rewards epoch. This may be modified later. The epoch duration is not exact, as epochs must manually be incremented.
current_rewards_epoch: u32
The current rewards epoch.
next_epoch_starts_at: u64
When the next epoch starts.
locker_token_mint: Pubkey
Token mint. Unused but useful for frontends.
locker_governor: Pubkey
Governor associated with the Locker. Unused but useful for frontends.
Implementations
sourceimpl Gaugemeister
impl Gaugemeister
sourcepub fn voting_epoch(&self) -> Result<u32>
pub fn voting_epoch(&self) -> Result<u32>
Fetches the current voting epoch. This is always the epoch after Self::current_rewards_epoch.
Trait Implementations
sourceimpl AccountDeserialize for Gaugemeister
impl AccountDeserialize for Gaugemeister
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 AccountSerialize for Gaugemeister
impl AccountSerialize for Gaugemeister
sourceimpl BorshDeserialize for Gaugemeister where
Pubkey: BorshDeserialize,
u8: BorshDeserialize,
Pubkey: BorshDeserialize,
Pubkey: BorshDeserialize,
Pubkey: BorshDeserialize,
Pubkey: BorshDeserialize,
u32: BorshDeserialize,
u32: BorshDeserialize,
u64: BorshDeserialize,
Pubkey: BorshDeserialize,
Pubkey: BorshDeserialize,
impl BorshDeserialize for Gaugemeister where
Pubkey: BorshDeserialize,
u8: BorshDeserialize,
Pubkey: BorshDeserialize,
Pubkey: BorshDeserialize,
Pubkey: BorshDeserialize,
Pubkey: BorshDeserialize,
u32: BorshDeserialize,
u32: BorshDeserialize,
u64: BorshDeserialize,
Pubkey: BorshDeserialize,
Pubkey: BorshDeserialize,
sourceimpl BorshSerialize for Gaugemeister where
Pubkey: BorshSerialize,
u8: BorshSerialize,
Pubkey: BorshSerialize,
Pubkey: BorshSerialize,
Pubkey: BorshSerialize,
Pubkey: BorshSerialize,
u32: BorshSerialize,
u32: BorshSerialize,
u64: BorshSerialize,
Pubkey: BorshSerialize,
Pubkey: BorshSerialize,
impl BorshSerialize for Gaugemeister where
Pubkey: BorshSerialize,
u8: BorshSerialize,
Pubkey: BorshSerialize,
Pubkey: BorshSerialize,
Pubkey: BorshSerialize,
Pubkey: BorshSerialize,
u32: BorshSerialize,
u32: BorshSerialize,
u64: BorshSerialize,
Pubkey: BorshSerialize,
Pubkey: BorshSerialize,
sourceimpl Clone for Gaugemeister
impl Clone for Gaugemeister
sourcefn clone(&self) -> Gaugemeister
fn clone(&self) -> Gaugemeister
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 Debug for Gaugemeister
impl Debug for Gaugemeister
sourceimpl Default for Gaugemeister
impl Default for Gaugemeister
sourcefn default() -> Gaugemeister
fn default() -> Gaugemeister
Returns the “default value” for a type. Read more
sourceimpl Discriminator for Gaugemeister
impl Discriminator for Gaugemeister
fn discriminator() -> [u8; 8]
sourceimpl Owner for Gaugemeister
impl Owner for Gaugemeister
impl Copy for Gaugemeister
Auto Trait Implementations
impl RefUnwindSafe for Gaugemeister
impl Send for Gaugemeister
impl Sync for Gaugemeister
impl Unpin for Gaugemeister
impl UnwindSafe for Gaugemeister
Blanket Implementations
impl<T> AbiExample for T
impl<T> AbiExample for T
pub default fn example() -> T
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
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.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more