pub trait EntrypointArgument: Sized {
// Required methods
fn is_required() -> bool;
fn cl_type() -> CLType;
fn insert_runtime_arg(self, name: &str, args: &mut RuntimeArgs);
fn unwrap(value: Option<Self>, env: &ContractEnv) -> Self;
}Expand description
A trait for types that can be used as entrypoint arguments.
Required Methods§
Sourcefn is_required() -> bool
fn is_required() -> bool
Returns true if the argument is required.
Sourcefn insert_runtime_arg(self, name: &str, args: &mut RuntimeArgs)
fn insert_runtime_arg(self, name: &str, args: &mut RuntimeArgs)
Inserts the argument into the runtime args.
Sourcefn unwrap(value: Option<Self>, env: &ContractEnv) -> Self
fn unwrap(value: Option<Self>, env: &ContractEnv) -> Self
Unwraps the argument from an Option.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".