pub trait DiamondLoupe: ContractEnv {
    type facetsOutput: ImpliesReturn<Vec<FacetCut>>;
    type facetFunctionSelectorsOutput: ImpliesReturn<Vec<Selector>>;
    type facetCodeHashesOutput: ImpliesReturn<Vec<Hash>>;
    type facetCodeHashOutput: ImpliesReturn<Option<Hash>>;

    // Required methods
    fn facets(&self) -> Self::facetsOutput;
    fn facet_function_selectors(
        &self,
        facet: Hash
    ) -> Self::facetFunctionSelectorsOutput;
    fn facet_code_hashes(&self) -> Self::facetCodeHashesOutput;
    fn facet_code_hash(&self, selector: Selector) -> Self::facetCodeHashOutput;
}
Expand description

Trait which implements functions of Diamond Loupe to lookup the functionality of the diamond contract

Required Associated Types§

source

type facetsOutput: ImpliesReturn<Vec<FacetCut>>

Output type of the respective trait message.

source

type facetFunctionSelectorsOutput: ImpliesReturn<Vec<Selector>>

Output type of the respective trait message.

source

type facetCodeHashesOutput: ImpliesReturn<Vec<Hash>>

Output type of the respective trait message.

source

type facetCodeHashOutput: ImpliesReturn<Option<Hash>>

Output type of the respective trait message.

Required Methods§

Implementations on Foreign Types§

source§

impl<E> DiamondLoupe for TraitDefinitionRegistry<E>where E: Environment,

§

type facetsOutput = Vec<FacetCut, Global>

source§

fn facets(&self) -> Self::facetsOutput

§

type facetFunctionSelectorsOutput = Vec<[u8; 4], Global>

source§

fn facet_function_selectors( &self, __ink_binding_0: Hash ) -> Self::facetFunctionSelectorsOutput

§

type facetCodeHashesOutput = Vec<<DefaultEnvironment as Environment>::Hash, Global>

source§

fn facet_code_hashes(&self) -> Self::facetCodeHashesOutput

§

type facetCodeHashOutput = Option<<DefaultEnvironment as Environment>::Hash>

source§

fn facet_code_hash( &self, __ink_binding_0: Selector ) -> Self::facetCodeHashOutput

Implementors§