pub trait StackEvaluate<N: Network>: Clone {
    // Required methods
    fn evaluate_closure<A: Aleo<Network = N>>(
        &self,
        closure: &Closure<N>,
        inputs: &[Value<N>],
        call_stack: CallStack<N>,
        signer: Address<N>,
        caller: Address<N>,
        tvk: Field<N>
    ) -> Result<Vec<Value<N>>>;
    fn evaluate_function<A: Aleo<Network = N>>(
        &self,
        call_stack: CallStack<N>,
        caller: Option<ProgramID<N>>
    ) -> Result<Response<N>>;
}

Required Methods§

source

fn evaluate_closure<A: Aleo<Network = N>>( &self, closure: &Closure<N>, inputs: &[Value<N>], call_stack: CallStack<N>, signer: Address<N>, caller: Address<N>, tvk: Field<N> ) -> Result<Vec<Value<N>>>

Evaluates 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.

source

fn evaluate_function<A: Aleo<Network = N>>( &self, call_stack: CallStack<N>, caller: Option<ProgramID<N>> ) -> Result<Response<N>>

Evaluates a program function on the given inputs.

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.

Implementors§

source§

impl<N: Network> StackEvaluate<N> for Stack<N>