pub struct AddEntryCpiBuilder<'a, 'b> { /* private fields */ }Expand description
Instruction builder for AddEntry via CPI.
§Accounts:
[]whitelist_account[signer]whitelist_authority[writable]whitelist_entry_account[writable, signer]payer[]system_program
Implementations§
Source§impl<'a, 'b> AddEntryCpiBuilder<'a, 'b>
impl<'a, 'b> AddEntryCpiBuilder<'a, 'b>
pub fn new(program: &'b AccountInfo<'a>) -> Self
Sourcepub fn whitelist_account(
&mut self,
whitelist_account: &'b AccountInfo<'a>,
) -> &mut Self
pub fn whitelist_account( &mut self, whitelist_account: &'b AccountInfo<'a>, ) -> &mut Self
The whitelist account
The whitelist authority
Sourcepub fn whitelist_entry_account(
&mut self,
whitelist_entry_account: &'b AccountInfo<'a>,
) -> &mut Self
pub fn whitelist_entry_account( &mut self, whitelist_entry_account: &'b AccountInfo<'a>, ) -> &mut Self
The whitelist entry account
Sourcepub fn payer(&mut self, payer: &'b AccountInfo<'a>) -> &mut Self
pub fn payer(&mut self, payer: &'b AccountInfo<'a>) -> &mut Self
Payer account (must be a system account)
Sourcepub fn system_program(
&mut self,
system_program: &'b AccountInfo<'a>,
) -> &mut Self
pub fn system_program( &mut self, system_program: &'b AccountInfo<'a>, ) -> &mut Self
System program
Sourcepub fn add_remaining_account(
&mut self,
account: &'b AccountInfo<'a>,
is_writable: bool,
is_signer: bool,
) -> &mut Self
pub fn add_remaining_account( &mut self, account: &'b AccountInfo<'a>, is_writable: bool, is_signer: bool, ) -> &mut Self
Add an additional account to the instruction.
Sourcepub fn add_remaining_accounts(
&mut self,
accounts: &[(&'b AccountInfo<'a>, bool, bool)],
) -> &mut Self
pub fn add_remaining_accounts( &mut self, accounts: &[(&'b AccountInfo<'a>, bool, bool)], ) -> &mut Self
Add additional accounts to the instruction.
Each account is represented by a tuple of the AccountInfo, a bool indicating whether the account is writable or not,
and a bool indicating whether the account is a signer or not.
pub fn invoke(&self) -> ProgramResult
pub fn invoke_signed(&self, signers_seeds: &[&[&[u8]]]) -> ProgramResult
Trait Implementations§
Source§impl<'a, 'b> Clone for AddEntryCpiBuilder<'a, 'b>
impl<'a, 'b> Clone for AddEntryCpiBuilder<'a, 'b>
Auto Trait Implementations§
impl<'a, 'b> !RefUnwindSafe for AddEntryCpiBuilder<'a, 'b>
impl<'a, 'b> !Send for AddEntryCpiBuilder<'a, 'b>
impl<'a, 'b> !Sync for AddEntryCpiBuilder<'a, 'b>
impl<'a, 'b> !UnwindSafe for AddEntryCpiBuilder<'a, 'b>
impl<'a, 'b> Freeze for AddEntryCpiBuilder<'a, 'b>
impl<'a, 'b> Unpin for AddEntryCpiBuilder<'a, 'b>
impl<'a, 'b> UnsafeUnpin for AddEntryCpiBuilder<'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
Mutably borrows from an owned value. Read more