ore_api/state/board.rs
1use steel::*;
2
3use crate::state::board_pda;
4
5use super::OreAccount;
6
7#[repr(C)]
8#[derive(Clone, Copy, Debug, PartialEq, Pod, Zeroable)]
9pub struct Board {
10 /// The current round number.
11 pub round_id: u64,
12
13 /// The slot at which the current round starts mining.
14 pub start_slot: u64,
15
16 /// The slot at which the current round ends mining.
17 pub end_slot: u64,
18}
19
20impl Board {
21 pub fn pda(&self) -> (Pubkey, u8) {
22 board_pda()
23 }
24}
25
26account!(OreAccount, Board);