pub struct DeployPublicCpi<'a, 'b> {Show 19 fields
pub __program: &'b AccountInfo<'a>,
pub authority: &'b AccountInfo<'a>,
pub satrush_config: &'b AccountInfo<'a>,
pub board: &'b AccountInfo<'a>,
pub round: &'b AccountInfo<'a>,
pub usd_mint: &'b AccountInfo<'a>,
pub authority_usd_ata: &'b AccountInfo<'a>,
pub board_usd_ata: &'b AccountInfo<'a>,
pub public_deployment: &'b AccountInfo<'a>,
pub miner: &'b AccountInfo<'a>,
pub epoch_vault: &'b AccountInfo<'a>,
pub epoch_vault_usd_ata: &'b AccountInfo<'a>,
pub one_btc_vault: &'b AccountInfo<'a>,
pub one_btc_vault_usd_ata: &'b AccountInfo<'a>,
pub treasury: &'b AccountInfo<'a>,
pub treasury_usd_ata: &'b AccountInfo<'a>,
pub token_program: &'b AccountInfo<'a>,
pub system_program: &'b AccountInfo<'a>,
pub __args: DeployPublicInstructionArgs,
}Expand description
deploy_public CPI instruction.
Fields§
§__program: &'b AccountInfo<'a>The program to invoke.
satrush_config: &'b AccountInfo<'a>§board: &'b AccountInfo<'a>§round: &'b AccountInfo<'a>Round the miner is deploying into. Must be the board’s current round.
Stays a regular Account: its id feeds PDA seeds here and below, and
the IDL seed parser can only encode plain field paths like round.id.
usd_mint: &'b AccountInfo<'a>Miner’s USD token account funds are pulled from.
board_usd_ata: &'b AccountInfo<'a>Board’s USD deposit pool that funds are deposited into.
public_deployment: &'b AccountInfo<'a>Per-(round, miner) deployment record. Init fails if the miner already deployed into this round.
miner: &'b AccountInfo<'a>Miner profile for authority. Created lazily on the first deploy and
loaded on subsequent ones; its streak advances on every play.
epoch_vault: &'b AccountInfo<'a>Epoch Vault singleton — receives the epoch fee leg.
epoch_vault_usd_ata: &'b AccountInfo<'a>Epoch Vault’s USD pool the epoch fee is transferred into.
one_btc_vault: &'b AccountInfo<'a>1 BTC Vault singleton — receives the 1 BTC fee leg.
one_btc_vault_usd_ata: &'b AccountInfo<'a>1 BTC Vault’s USD pool the 1 BTC fee is transferred into.
treasury: &'b AccountInfo<'a>Treasury singleton — receives the protocol fee leg. No seeds constraint:
the PDA derivation is redundant — the discriminator + owner checks already
pin the one Treasury instance that can ever exist (init on fixed seeds).
treasury_usd_ata: &'b AccountInfo<'a>Treasury’s USD fee pool the protocol fee is transferred into. Validated by
field equality (token::) rather than ATA derivation (associated_token::):
this instruction sits at the 4 KB BPF stack ceiling and cannot afford the
derivation. Any treasury-owned USD account passes, but misdirecting the fee
into a non-canonical one only strands the payer’s own fee.
token_program: &'b AccountInfo<'a>§system_program: &'b AccountInfo<'a>§__args: DeployPublicInstructionArgsThe arguments for the instruction.
Implementations§
Source§impl<'a, 'b> DeployPublicCpi<'a, 'b>
impl<'a, 'b> DeployPublicCpi<'a, 'b>
pub fn new( program: &'b AccountInfo<'a>, accounts: DeployPublicCpiAccounts<'a, 'b>, args: DeployPublicInstructionArgs, ) -> Self
pub fn invoke(&self) -> ProgramResult
pub fn invoke_with_remaining_accounts( &self, remaining_accounts: &[(&'b AccountInfo<'a>, bool, bool)], ) -> ProgramResult
pub fn invoke_signed(&self, signers_seeds: &[&[&[u8]]]) -> ProgramResult
pub fn invoke_signed_with_remaining_accounts( &self, signers_seeds: &[&[&[u8]]], remaining_accounts: &[(&'b AccountInfo<'a>, bool, bool)], ) -> ProgramResult
Auto Trait Implementations§
impl<'a, 'b> !RefUnwindSafe for DeployPublicCpi<'a, 'b>
impl<'a, 'b> !Send for DeployPublicCpi<'a, 'b>
impl<'a, 'b> !Sync for DeployPublicCpi<'a, 'b>
impl<'a, 'b> !UnwindSafe for DeployPublicCpi<'a, 'b>
impl<'a, 'b> Freeze for DeployPublicCpi<'a, 'b>
impl<'a, 'b> Unpin for DeployPublicCpi<'a, 'b>
impl<'a, 'b> UnsafeUnpin for DeployPublicCpi<'a, 'b>
Blanket Implementations§
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more