pub trait FraudProofHostFunctions: Send + Sync {
// Required methods
fn derive_bundle_digest(
&self,
domain_runtime_code: Vec<u8>,
bundle_body: Vec<OpaqueExtrinsic>,
) -> Option<H256>;
fn execution_proof_check(
&self,
domain_block_id: (BlockNumber, H256),
pre_state_root: H256,
encoded_proof: Vec<u8>,
execution_method: &str,
call_data: &[u8],
domain_runtime_code: Vec<u8>,
) -> Option<Vec<u8>>;
fn check_extrinsics_in_single_context(
&self,
domain_runtime_code: Vec<u8>,
domain_block_id: (BlockNumber, H256),
domain_block_state_root: H256,
bundle_extrinsics: Vec<OpaqueExtrinsic>,
encoded_proof: Vec<u8>,
) -> Option<Option<u32>>;
fn construct_domain_inherent_extrinsic(
&self,
domain_runtime_code: Vec<u8>,
domain_inherent_extrinsic_data: DomainInherentExtrinsicData,
) -> Option<DomainInherentExtrinsic>;
fn domain_storage_key(
&self,
domain_runtime_code: Vec<u8>,
req: DomainStorageKeyRequest,
) -> Option<Vec<u8>>;
fn domain_runtime_call(
&self,
domain_runtime_code: Vec<u8>,
call: StatelessDomainRuntimeCall,
) -> Option<bool>;
fn bundle_weight(
&self,
domain_runtime_code: Vec<u8>,
bundle_body: Vec<OpaqueExtrinsic>,
) -> Option<Weight>;
fn extract_xdm_mmr_proof(
&self,
domain_runtime_code: Vec<u8>,
opaque_extrinsic: Vec<u8>,
) -> Option<Option<Vec<u8>>>;
}Expand description
Trait to query and verify Domains Fraud proof.
Required Methods§
Sourcefn derive_bundle_digest(
&self,
domain_runtime_code: Vec<u8>,
bundle_body: Vec<OpaqueExtrinsic>,
) -> Option<H256>
fn derive_bundle_digest( &self, domain_runtime_code: Vec<u8>, bundle_body: Vec<OpaqueExtrinsic>, ) -> Option<H256>
Derive the bundle digest for the given bundle body.
Sourcefn execution_proof_check(
&self,
domain_block_id: (BlockNumber, H256),
pre_state_root: H256,
encoded_proof: Vec<u8>,
execution_method: &str,
call_data: &[u8],
domain_runtime_code: Vec<u8>,
) -> Option<Vec<u8>>
fn execution_proof_check( &self, domain_block_id: (BlockNumber, H256), pre_state_root: H256, encoded_proof: Vec<u8>, execution_method: &str, call_data: &[u8], domain_runtime_code: Vec<u8>, ) -> Option<Vec<u8>>
Check the execution proof
fn check_extrinsics_in_single_context( &self, domain_runtime_code: Vec<u8>, domain_block_id: (BlockNumber, H256), domain_block_state_root: H256, bundle_extrinsics: Vec<OpaqueExtrinsic>, encoded_proof: Vec<u8>, ) -> Option<Option<u32>>
fn construct_domain_inherent_extrinsic( &self, domain_runtime_code: Vec<u8>, domain_inherent_extrinsic_data: DomainInherentExtrinsicData, ) -> Option<DomainInherentExtrinsic>
fn domain_storage_key( &self, domain_runtime_code: Vec<u8>, req: DomainStorageKeyRequest, ) -> Option<Vec<u8>>
fn domain_runtime_call( &self, domain_runtime_code: Vec<u8>, call: StatelessDomainRuntimeCall, ) -> Option<bool>
fn bundle_weight( &self, domain_runtime_code: Vec<u8>, bundle_body: Vec<OpaqueExtrinsic>, ) -> Option<Weight>
fn extract_xdm_mmr_proof( &self, domain_runtime_code: Vec<u8>, opaque_extrinsic: Vec<u8>, ) -> Option<Option<Vec<u8>>>
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".