Struct sp_wasm_interface::Signature
source · pub struct Signature {
pub args: Cow<'static, [ValueType]>,
pub return_value: Option<ValueType>,
}
Expand description
The Signature of a function
Fields§
§args: Cow<'static, [ValueType]>
The arguments of a function.
return_value: Option<ValueType>
The optional return value of a function.
Implementations§
source§impl Signature
impl Signature
sourcepub fn new<T: Into<Cow<'static, [ValueType]>>>(
args: T,
return_value: Option<ValueType>
) -> Self
pub fn new<T: Into<Cow<'static, [ValueType]>>>( args: T, return_value: Option<ValueType> ) -> Self
Create a new instance of Signature
.
sourcepub fn new_with_args<T: Into<Cow<'static, [ValueType]>>>(args: T) -> Self
pub fn new_with_args<T: Into<Cow<'static, [ValueType]>>>(args: T) -> Self
Create a new instance of Signature
with the given args
and without any return value.
Trait Implementations§
source§impl PartialEq<Signature> for Signature
impl PartialEq<Signature> for Signature
impl Eq for Signature
impl StructuralEq for Signature
impl StructuralPartialEq for Signature
Auto Trait Implementations§
impl RefUnwindSafe for Signature
impl Send for Signature
impl Sync for Signature
impl Unpin for Signature
impl UnwindSafe for Signature
Blanket Implementations§
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more