Trait snarkvm_synthesizer::prelude::StackExecute
source · pub trait StackExecute<N>where
N: Network,{
// Required methods
fn execute_closure<A>(
&self,
closure: &ClosureCore<N, Instruction<N>>,
inputs: &[Value<A>],
call_stack: CallStack<N>,
signer: Address<A>,
caller: Address<A>,
tvk: Field<A>
) -> Result<Vec<Value<A>>, Error>
where A: Aleo<Network = N>;
fn execute_function<A, R>(
&self,
call_stack: CallStack<N>,
console_caller: Option<ProgramID<N>>,
rng: &mut R
) -> Result<Response<N>, Error>
where A: Aleo<Network = N>,
R: CryptoRng + Rng;
}
Required Methods§
sourcefn execute_closure<A>(
&self,
closure: &ClosureCore<N, Instruction<N>>,
inputs: &[Value<A>],
call_stack: CallStack<N>,
signer: Address<A>,
caller: Address<A>,
tvk: Field<A>
) -> Result<Vec<Value<A>>, Error>where
A: Aleo<Network = N>,
fn execute_closure<A>( &self, closure: &ClosureCore<N, Instruction<N>>, inputs: &[Value<A>], call_stack: CallStack<N>, signer: Address<A>, caller: Address<A>, tvk: Field<A> ) -> Result<Vec<Value<A>>, Error>where A: Aleo<Network = N>,
Executes a program closure on the given inputs.
Errors
This method will halt if the given inputs are not the same length as the input statements.
sourcefn execute_function<A, R>(
&self,
call_stack: CallStack<N>,
console_caller: Option<ProgramID<N>>,
rng: &mut R
) -> Result<Response<N>, Error>where
A: Aleo<Network = N>,
R: CryptoRng + Rng,
fn execute_function<A, R>( &self, call_stack: CallStack<N>, console_caller: Option<ProgramID<N>>, rng: &mut R ) -> Result<Response<N>, Error>where A: Aleo<Network = N>, R: CryptoRng + Rng,
Executes a program function on the given inputs.
Note: To execute a transition, do not call this method. Instead, call Process::execute
.
Errors
This method will halt if the given inputs are not the same length as the input statements.
Object Safety§
This trait is not object safe.