Skip to main content

ore_stake_api/state/
treasury.rs

1use serde::{Deserialize, Serialize};
2use steel::*;
3
4use super::OreAccount;
5
6/// Treasury is a singleton account which tracks top level protocol balances and holds onto staking yield.
7#[repr(C)]
8#[derive(Clone, Copy, Debug, PartialEq, Pod, Zeroable, Serialize, Deserialize)]
9pub struct Treasury {
10    /// The cumulative ORE distributed to stakers, divided by the total stake at the time of distribution.
11    pub rewards_factor: Numeric,
12
13    /// The current total amount of ORE staking deposits.
14    pub total_staked: u64,
15}
16
17account!(OreAccount, Treasury);