pub struct TridentSVM { /* private fields */ }Implementations§
Source§impl TridentSVM
impl TridentSVM
pub fn get_account(&self, pubkey: &Pubkey) -> Option<AccountSharedData>
pub fn set_account( &mut self, pubkey: &Pubkey, account: &AccountSharedData, permanent: bool, )
pub fn get_sysvar<T>(&self) -> T
pub fn set_sysvar<T>(&mut self, sysvar: &T)
pub fn get_payer(&self) -> Keypair
Source§impl TridentSVM
impl TridentSVM
pub fn deploy_binary_program(&mut self, program: &TridentProgram)
Source§impl TridentSVM
impl TridentSVM
pub fn process_transaction( &mut self, transaction: Transaction, ) -> TridentTransactionProcessingResult
pub fn process_transaction_with_settle( &mut self, transaction: Transaction, ) -> TridentTransactionProcessingResult
Source§impl TridentSVM
impl TridentSVM
pub fn builder() -> TridentSVMBuilder
pub fn clear_accounts(&mut self)
Trait Implementations§
Source§impl Default for TridentSVM
impl Default for TridentSVM
Source§fn default() -> TridentSVM
fn default() -> TridentSVM
Returns the “default value” for a type. Read more
Source§impl InvokeContextCallback for TridentSVM
impl InvokeContextCallback for TridentSVM
Source§fn get_epoch_stake(&self) -> u64
fn get_epoch_stake(&self) -> u64
Returns the total current epoch stake for the network.
Source§fn get_epoch_stake_for_vote_account(&self, _vote_address: &Pubkey) -> u64
fn get_epoch_stake_for_vote_account(&self, _vote_address: &Pubkey) -> u64
Returns the current epoch stake for the given vote account.
Source§fn is_precompile(&self, _program_id: &Pubkey) -> bool
fn is_precompile(&self, _program_id: &Pubkey) -> bool
Returns true if the program_id corresponds to a precompiled program
Source§fn process_precompile(
&self,
_program_id: &Pubkey,
_data: &[u8],
_instruction_datas: Vec<&[u8]>,
) -> Result<(), PrecompileError>
fn process_precompile( &self, _program_id: &Pubkey, _data: &[u8], _instruction_datas: Vec<&[u8]>, ) -> Result<(), PrecompileError>
Calls the precompiled program corresponding to the given program ID.
Source§impl TransactionProcessingCallback for TridentSVM
impl TransactionProcessingCallback for TridentSVM
fn account_matches_owners( &self, account: &Pubkey, owners: &[Pubkey], ) -> Option<usize>
fn add_builtin_account(&self, _name: &str, _program_id: &Pubkey)
fn inspect_account( &self, _address: &Pubkey, _account_state: AccountState<'_>, _is_writable: bool, )
Source§fn get_current_epoch_vote_account_stake(&self, vote_address: &Pubkey) -> u64
fn get_current_epoch_vote_account_stake(&self, vote_address: &Pubkey) -> u64
👎Deprecated since 2.3.0: Use
get_epoch_stake_for_vote_account on the InvokeContextCallback trait insteadAuto Trait Implementations§
impl !Freeze for TridentSVM
impl RefUnwindSafe for TridentSVM
impl Send for TridentSVM
impl Sync for TridentSVM
impl Unpin for TridentSVM
impl UnwindSafe for TridentSVM
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
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>
Converts
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>
Converts
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