pub struct TransactionScriptsSyscallsGenerator<DL>{ /* private fields */ }
Expand description
Syscalls can be generated individually by TransactionScriptsSyscallsGenerator.
TransactionScriptsSyscallsGenerator can be cloned.
Implementations§
Source§impl<DL> TransactionScriptsSyscallsGenerator<DL>
impl<DL> TransactionScriptsSyscallsGenerator<DL>
Sourcepub fn build_current_cycles(&self) -> CurrentCycles
pub fn build_current_cycles(&self) -> CurrentCycles
Build syscall: current_cycles
Sourcepub fn build_vm_version(&self) -> VMVersion
pub fn build_vm_version(&self) -> VMVersion
Build syscall: vm_version
Sourcepub fn build_exec(
&self,
group_inputs: Arc<Vec<usize>>,
group_outputs: Arc<Vec<usize>>,
load_elf_base_fee: u64,
) -> Exec<DL>
pub fn build_exec( &self, group_inputs: Arc<Vec<usize>>, group_outputs: Arc<Vec<usize>>, load_elf_base_fee: u64, ) -> Exec<DL>
Build syscall: exec
Sourcepub fn build_load_tx(&self) -> LoadTx
pub fn build_load_tx(&self) -> LoadTx
Build syscall: load_tx
Sourcepub fn build_load_cell(
&self,
group_inputs: Arc<Vec<usize>>,
group_outputs: Arc<Vec<usize>>,
) -> LoadCell<DL>
pub fn build_load_cell( &self, group_inputs: Arc<Vec<usize>>, group_outputs: Arc<Vec<usize>>, ) -> LoadCell<DL>
Build syscall: load_cell
Sourcepub fn build_load_cell_data(
&self,
snapshot2_context: Arc<Mutex<Snapshot2Context<DataPieceId, TxData<DL>>>>,
) -> LoadCellData<DL>
pub fn build_load_cell_data( &self, snapshot2_context: Arc<Mutex<Snapshot2Context<DataPieceId, TxData<DL>>>>, ) -> LoadCellData<DL>
Build syscall: load_cell_data
Sourcepub fn build_load_input(&self, group_inputs: Arc<Vec<usize>>) -> LoadInput
pub fn build_load_input(&self, group_inputs: Arc<Vec<usize>>) -> LoadInput
Build syscall: load_input
Sourcepub fn build_load_script_hash(&self, hash: Byte32) -> LoadScriptHash
pub fn build_load_script_hash(&self, hash: Byte32) -> LoadScriptHash
Build syscall: load_script_hash
Sourcepub fn build_load_header(&self, group_inputs: Arc<Vec<usize>>) -> LoadHeader<DL>
pub fn build_load_header(&self, group_inputs: Arc<Vec<usize>>) -> LoadHeader<DL>
Build syscall: load_header
Sourcepub fn build_load_block_extension(
&self,
group_inputs: Arc<Vec<usize>>,
) -> LoadBlockExtension<DL>
pub fn build_load_block_extension( &self, group_inputs: Arc<Vec<usize>>, ) -> LoadBlockExtension<DL>
Build syscall: load_block_extension
Sourcepub fn build_load_witness(
&self,
group_inputs: Arc<Vec<usize>>,
group_outputs: Arc<Vec<usize>>,
) -> LoadWitness
pub fn build_load_witness( &self, group_inputs: Arc<Vec<usize>>, group_outputs: Arc<Vec<usize>>, ) -> LoadWitness
Build syscall: load_witness
Sourcepub fn build_load_script(&self, script: Script) -> LoadScript
pub fn build_load_script(&self, script: Script) -> LoadScript
Build syscall: load_script
Sourcepub fn build_spawn(
&self,
snapshot2_context: Arc<Mutex<Snapshot2Context<DataPieceId, TxData<DL>>>>,
) -> Spawn<DL>
pub fn build_spawn( &self, snapshot2_context: Arc<Mutex<Snapshot2Context<DataPieceId, TxData<DL>>>>, ) -> Spawn<DL>
Build syscall: spawn
Sourcepub fn build_wait(&self) -> Wait
pub fn build_wait(&self) -> Wait
Build syscall: wait
Sourcepub fn build_process_id(&self) -> ProcessID
pub fn build_process_id(&self) -> ProcessID
Build syscall: process_id
Sourcepub fn build_pipe(&self) -> Pipe
pub fn build_pipe(&self) -> Pipe
Build syscall: pipe
Sourcepub fn build_write(&self) -> Write
pub fn build_write(&self) -> Write
Build syscall: write
Sourcepub fn build_read(&self) -> Read
pub fn build_read(&self) -> Read
Build syscall: read
Sourcepub fn inherited_fd(&self) -> InheritedFd
pub fn inherited_fd(&self) -> InheritedFd
Build syscall: inherited_fd
Sourcepub fn generate_syscalls(
&self,
script_version: ScriptVersion,
script_group: &ScriptGroup,
snapshot2_context: Arc<Mutex<Snapshot2Context<DataPieceId, TxData<DL>>>>,
) -> Vec<Box<dyn Syscalls<CoreMachine>>>
pub fn generate_syscalls( &self, script_version: ScriptVersion, script_group: &ScriptGroup, snapshot2_context: Arc<Mutex<Snapshot2Context<DataPieceId, TxData<DL>>>>, ) -> Vec<Box<dyn Syscalls<CoreMachine>>>
Generate syscalls.
Trait Implementations§
Source§impl<DL> Clone for TransactionScriptsSyscallsGenerator<DL>where
DL: CellDataProvider + HeaderProvider + ExtensionProvider + Send + Sync + Clone + 'static + Clone,
impl<DL> Clone for TransactionScriptsSyscallsGenerator<DL>where
DL: CellDataProvider + HeaderProvider + ExtensionProvider + Send + Sync + Clone + 'static + Clone,
Source§fn clone(&self) -> TransactionScriptsSyscallsGenerator<DL>
fn clone(&self) -> TransactionScriptsSyscallsGenerator<DL>
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl<DL> Freeze for TransactionScriptsSyscallsGenerator<DL>where
DL: Freeze,
impl<DL> !RefUnwindSafe for TransactionScriptsSyscallsGenerator<DL>
impl<DL> Send for TransactionScriptsSyscallsGenerator<DL>
impl<DL> Sync for TransactionScriptsSyscallsGenerator<DL>
impl<DL> Unpin for TransactionScriptsSyscallsGenerator<DL>where
DL: Unpin,
impl<DL> !UnwindSafe for TransactionScriptsSyscallsGenerator<DL>
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)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