#[repr(C)]pub struct Miner {
pub discriminator: u64,
pub authority: [u8; 32],
pub session_key: [u8; 32],
pub challenge: [u8; 32],
pub last_round: u64,
pub last_round_weight: u64,
pub last_balance: u64,
pub pending_rewards: u64,
pub total_mined: u64,
pub total_hashes: u64,
pub bump: u64,
}Expand description
Konto minera (PDA “miner” + authority).
Fields§
§discriminator: u64Wallet-właściciel (burner z przeglądarki albo podłączony wallet).
session_key: [u8; 32]Session key uprawniony do submitów (zero = brak).
challenge: [u8; 32]Bieżące challenge PoW.
last_round: u64Indeks rundy ostatniego submitu.
last_round_weight: u64Waga zgłoszona w rundzie last_round (nierozliczona, jeśli > 0).
last_balance: u64Saldo tokenów przy ostatnim submicie (reguła min-salda / anty-cycling).
pending_rewards: u64Naliczone, nieodebrane nagrody (jednostki natywne).
total_mined: u64Statystyki lifetime.
total_hashes: u64§bump: u64Bump PDA.
Implementations§
Trait Implementations§
impl Copy for Miner
impl Pod for Miner
Auto Trait Implementations§
impl Freeze for Miner
impl RefUnwindSafe for Miner
impl Send for Miner
impl Sync for Miner
impl Unpin for Miner
impl UnsafeUnpin for Miner
impl UnwindSafe for Miner
Blanket Implementations§
impl<T> AnyBitPattern for Twhere
T: Pod,
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> CheckedBitPattern for Twhere
T: AnyBitPattern,
impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
Source§type Bits = T
type Bits = T
Self must have the same layout as the specified Bits except for
the possible invalid bit patterns being checked during
is_valid_bit_pattern.Source§fn is_valid_bit_pattern(_bits: &T) -> bool
fn is_valid_bit_pattern(_bits: &T) -> bool
If this function returns true, then it must be valid to reinterpret
bits
as &Self.