pub trait Payload {
// Required method
fn encode_call_data_to(
&self,
metadata: &Metadata,
out: &mut Vec<u8>,
) -> Result<(), Error>;
// Provided methods
fn encode_call_data(&self, metadata: &Metadata) -> Result<Vec<u8>, Error> { ... }
fn validation_details(&self) -> Option<ValidationDetails<'_>> { ... }
}Expand description
This represents a transaction payload that can be submitted to a node.
Required Methods§
Provided Methods§
Sourcefn encode_call_data(&self, metadata: &Metadata) -> Result<Vec<u8>, Error>
fn encode_call_data(&self, metadata: &Metadata) -> Result<Vec<u8>, Error>
Encode call data and return the output. This is a convenience
wrapper around Payload::encode_call_data_to.
Sourcefn validation_details(&self) -> Option<ValidationDetails<'_>>
fn validation_details(&self) -> Option<ValidationDetails<'_>>
Returns the details needed to validate the call, which include a statically generated hash, the pallet name, and the call name.