oil_api/state/
auction_pool.rs1use serde::{Deserialize, Serialize};
2use steel::*;
3
4use crate::state::auction_pool_pda;
5
6use super::OilAccount;
7
8#[repr(C)]
12#[derive(Clone, Copy, Debug, PartialEq, Pod, Zeroable, Serialize, Deserialize)]
13pub struct AuctionPool {
14 pub well_id: u64,
16
17 pub epoch_id: u64,
19
20 pub pool_total: u64,
22
23 pub status: u64,
26
27 pub buffer_a: u64,
29 pub buffer_b: u64,
30 pub buffer_c: u64,
31 pub buffer_d: u64,
32}
33
34impl AuctionPool {
35 pub fn pda(well_id: u64, epoch_id: u64) -> (Pubkey, u8) {
36 auction_pool_pda(well_id, epoch_id)
37 }
38}
39
40account!(OilAccount, AuctionPool);
41