Type Alias pallet_did_lookup::pallet::Module
source · pub type Module<T> = Pallet<T>;
Pallet
insteadExpand description
Type alias to Pallet
, to be used by construct_runtime
.
Generated by pallet
attribute macro.
Aliased Type§
struct Module<T>(/* private fields */);
Implementations§
source§impl<T: Config> Pallet<T>where
T::AccountId: Into<LinkableAccountId> + From<AccountId32> + Into<AccountId32>,
impl<T: Config> Pallet<T>where T::AccountId: Into<LinkableAccountId> + From<AccountId32> + Into<AccountId32>,
sourcepub fn associate_account(
origin: OriginFor<T>,
req: AssociateAccountRequest,
expiration: BlockNumberFor<T>
) -> DispatchResult
pub fn associate_account( origin: OriginFor<T>, req: AssociateAccountRequest, expiration: BlockNumberFor<T> ) -> DispatchResult
Associate the given account to the DID that authorized this call.
The account has to sign the DID and a blocknumber after which the signature expires in order to authorize the association.
The signature will be checked against the scale encoded tuple of the method specific id of the did identifier and the block number after which the signature should be regarded invalid.
Emits AssociationEstablished
and, optionally, AssociationRemoved
if there was a previous association for the account.
Weight: O(1)
- Reads: ConnectedDids + ConnectedAccounts + DID Origin Check
- Writes: ConnectedDids + ConnectedAccounts
sourcepub fn associate_sender(origin: OriginFor<T>) -> DispatchResult
pub fn associate_sender(origin: OriginFor<T>) -> DispatchResult
Associate the sender of the call to the DID that authorized this call.
Emits AssociationEstablished
and, optionally, AssociationRemoved
if there was a previous association for the account.
Weight: O(1)
- Reads: ConnectedDids + ConnectedAccounts + DID Origin Check
- Writes: ConnectedDids + ConnectedAccounts
sourcepub fn remove_sender_association(origin: OriginFor<T>) -> DispatchResult
pub fn remove_sender_association(origin: OriginFor<T>) -> DispatchResult
sourcepub fn remove_account_association(
origin: OriginFor<T>,
account: LinkableAccountId
) -> DispatchResult
pub fn remove_account_association( origin: OriginFor<T>, account: LinkableAccountId ) -> DispatchResult
Remove the association of the provided account ID. This call doesn’t require the authorization of the account ID, but the associated DID needs to match the DID that authorized this call.
Emits AssociationRemoved
.
Weight: O(1)
- Reads: ConnectedDids + ConnectedAccounts + DID Origin Check
- Writes: ConnectedDids + ConnectedAccounts
sourcepub fn reclaim_deposit(
origin: OriginFor<T>,
account: LinkableAccountId
) -> DispatchResult
pub fn reclaim_deposit( origin: OriginFor<T>, account: LinkableAccountId ) -> DispatchResult
sourcepub fn change_deposit_owner(
origin: OriginFor<T>,
account: LinkableAccountId
) -> DispatchResult
pub fn change_deposit_owner( origin: OriginFor<T>, account: LinkableAccountId ) -> DispatchResult
Changes the deposit owner.
The balance that is reserved by the current deposit owner will be freed and balance of the new deposit owner will get reserved.
The subject of the call must be linked to the account. The sender of the call will be the new deposit owner.
sourcepub fn update_deposit(
origin: OriginFor<T>,
account: LinkableAccountId
) -> DispatchResult
pub fn update_deposit( origin: OriginFor<T>, account: LinkableAccountId ) -> DispatchResult
Updates the deposit amount to the current deposit rate.
The sender must be the deposit owner.
source§impl<T: Config> Pallet<T>
impl<T: Config> Pallet<T>
pub fn add_association( sender: <T as Config>::AccountId, did_identifier: <T as Config>::DidIdentifier, account: LinkableAccountId ) -> DispatchResult
source§impl<T: Config> Pallet<T>
impl<T: Config> Pallet<T>
sourcepub fn connected_dids<KArg>(
k: KArg
) -> Option<ConnectionRecord<<T as Config>::DidIdentifier, <T as Config>::AccountId, BalanceOf<T>>>where
KArg: EncodeLike<LinkableAccountId>,
pub fn connected_dids<KArg>( k: KArg ) -> Option<ConnectionRecord<<T as Config>::DidIdentifier, <T as Config>::AccountId, BalanceOf<T>>>where KArg: EncodeLike<LinkableAccountId>,
An auto-generated getter for ConnectedDids
.
source§impl<T: Config> Pallet<T>
impl<T: Config> Pallet<T>
sourcepub fn connected_accounts<KArg1, KArg2>(k1: KArg1, k2: KArg2) -> Option<()>where
KArg1: EncodeLike<<T as Config>::DidIdentifier>,
KArg2: EncodeLike<LinkableAccountId>,
pub fn connected_accounts<KArg1, KArg2>(k1: KArg1, k2: KArg2) -> Option<()>where KArg1: EncodeLike<<T as Config>::DidIdentifier>, KArg2: EncodeLike<LinkableAccountId>,
An auto-generated getter for ConnectedAccounts
.
Trait Implementations§
source§impl<T: Config> BeforeAllRuntimeMigrations for Pallet<T>
impl<T: Config> BeforeAllRuntimeMigrations for Pallet<T>
source§fn before_all_runtime_migrations() -> Weight
fn before_all_runtime_migrations() -> Weight
source§impl<T> Benchmarking for Pallet<T>where
T: Config + Config,
T::AccountId: From<Public> + From<Public> + Into<LinkableAccountId> + Into<AccountId32> + From<AccountId32>,
T::DidIdentifier: From<T::AccountId>,
T::EnsureOrigin: GenerateBenchmarkOrigin<T::RuntimeOrigin, T::AccountId, T::DidIdentifier>,
<T as Config>::Currency: Mutate<T::AccountId>,
impl<T> Benchmarking for Pallet<T>where T: Config + Config, T::AccountId: From<Public> + From<Public> + Into<LinkableAccountId> + Into<AccountId32> + From<AccountId32>, T::DidIdentifier: From<T::AccountId>, T::EnsureOrigin: GenerateBenchmarkOrigin<T::RuntimeOrigin, T::AccountId, T::DidIdentifier>, <T as Config>::Currency: Mutate<T::AccountId>,
source§impl<T: Config> Callable<T> for Pallet<T>where
T::AccountId: Into<LinkableAccountId> + From<AccountId32> + Into<AccountId32>,
impl<T: Config> Callable<T> for Pallet<T>where T::AccountId: Into<LinkableAccountId> + From<AccountId32> + Into<AccountId32>,
type RuntimeCall = Call<T>
source§impl<T: Config> GetStorageVersion for Pallet<T>
impl<T: Config> GetStorageVersion for Pallet<T>
§type CurrentStorageVersion = StorageVersion
type CurrentStorageVersion = StorageVersion
source§fn current_storage_version() -> Self::CurrentStorageVersion
fn current_storage_version() -> Self::CurrentStorageVersion
source§fn on_chain_storage_version() -> StorageVersion
fn on_chain_storage_version() -> StorageVersion
source§impl<T: Config> Hooks<<<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number> for Pallet<T>
impl<T: Config> Hooks<<<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number> for Pallet<T>
source§fn try_state(_n: BlockNumberFor<T>) -> Result<(), TryRuntimeError>
fn try_state(_n: BlockNumberFor<T>) -> Result<(), TryRuntimeError>
§fn on_initialize(_n: BlockNumber) -> Weight
fn on_initialize(_n: BlockNumber) -> Weight
§fn on_finalize(_n: BlockNumber)
fn on_finalize(_n: BlockNumber)
§fn on_idle(_n: BlockNumber, _remaining_weight: Weight) -> Weight
fn on_idle(_n: BlockNumber, _remaining_weight: Weight) -> Weight
Hooks::on_finalize
]). Read more§fn on_runtime_upgrade() -> Weight
fn on_runtime_upgrade() -> Weight
§fn pre_upgrade() -> Result<Vec<u8, Global>, DispatchError>
fn pre_upgrade() -> Result<Vec<u8, Global>, DispatchError>
§fn post_upgrade(_state: Vec<u8, Global>) -> Result<(), DispatchError>
fn post_upgrade(_state: Vec<u8, Global>) -> Result<(), DispatchError>
§fn offchain_worker(_n: BlockNumber)
fn offchain_worker(_n: BlockNumber)
§fn integrity_test()
fn integrity_test()
source§impl<T: Config> IntegrityTest for Pallet<T>
impl<T: Config> IntegrityTest for Pallet<T>
source§fn integrity_test()
fn integrity_test()
Hooks::integrity_test
].source§impl<T: Config> OffchainWorker<<<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number> for Pallet<T>
impl<T: Config> OffchainWorker<<<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number> for Pallet<T>
source§fn offchain_worker(n: BlockNumberFor<T>)
fn offchain_worker(n: BlockNumberFor<T>)
source§impl<T: Config> OnFinalize<<<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number> for Pallet<T>
impl<T: Config> OnFinalize<<<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number> for Pallet<T>
source§fn on_finalize(n: BlockNumberFor<T>)
fn on_finalize(n: BlockNumberFor<T>)
Hooks::on_finalize
].source§impl<T: Config> OnGenesis for Pallet<T>
impl<T: Config> OnGenesis for Pallet<T>
source§fn on_genesis()
fn on_genesis()
source§impl<T: Config> OnIdle<<<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number> for Pallet<T>
impl<T: Config> OnIdle<<<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number> for Pallet<T>
source§impl<T: Config> OnInitialize<<<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number> for Pallet<T>
impl<T: Config> OnInitialize<<<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number> for Pallet<T>
source§fn on_initialize(n: BlockNumberFor<T>) -> Weight
fn on_initialize(n: BlockNumberFor<T>) -> Weight
Hooks::on_initialize
].source§impl<T: Config> OnRuntimeUpgrade for Pallet<T>
impl<T: Config> OnRuntimeUpgrade for Pallet<T>
source§fn on_runtime_upgrade() -> Weight
fn on_runtime_upgrade() -> Weight
Hooks::on_runtime_upgrade
].§fn try_on_runtime_upgrade(checks: bool) -> Result<Weight, DispatchError>
fn try_on_runtime_upgrade(checks: bool) -> Result<Weight, DispatchError>
pre_upgrade
->
on_runtime_upgrade
-> post_upgrade
hooks for a migration. Read moresource§impl<T: Config> PalletInfoAccess for Pallet<T>
impl<T: Config> PalletInfoAccess for Pallet<T>
source§fn module_name() -> &'static str
fn module_name() -> &'static str
source§fn crate_version() -> CrateVersion
fn crate_version() -> CrateVersion
source§impl<T> PartialEq<Pallet<T>> for Pallet<T>
impl<T> PartialEq<Pallet<T>> for Pallet<T>
source§impl<T: Config> TryState<<<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number> for Pallet<T>
impl<T: Config> TryState<<<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number> for Pallet<T>
source§impl<T: Config> WhitelistedStorageKeys for Pallet<T>
impl<T: Config> WhitelistedStorageKeys for Pallet<T>
source§fn whitelisted_storage_keys() -> Vec<TrackedStorageKey>
fn whitelisted_storage_keys() -> Vec<TrackedStorageKey>
Vec<TrackedStorageKey>
indicating the storage keys that
should be whitelisted during benchmarking. This means that those keys
will be excluded from the benchmarking performance calculation.