Timestamp::Call
Variant 135 v411pallet_timestamp::pallet::Call
Contains a variant per dispatchable extrinsic that this pallet has.
About This Type
Call enum for the Call pallet.
Contains all dispatchable functions (extrinsics) for the Call pallet. Each variant represents a different callable function with its parameters.
Variants (1)
| Index | Name | Fields | Docs |
|---|---|---|---|
| 0 | set | now: Compact<u64> | Set the current time. This call should be invoked exactly once per block. It will panic at the finalization phase, if this call hasn't been invoked by that time. The timestamp should be greater than the previous one by the amount specified by [`Config::MinimumPeriod`]. The dispatch origin for this call must be _None_. This dispatch class is _Mandatory_ to ensure it gets executed in the block. Be aware that changing the complexity of this call could result exhausting the resources in a block to execute any other calls. ## Complexity - `O(1)` (Note that implementations of `OnTimestampSet` must also be `O(1)`) - 1 storage read and 1 storage mutation (codec `O(1)` because of `DidUpdate::take` in `on_finalize`) - 1 event handler `on_timestamp_set`. Must be `O(1)`. |
SCALE Encoding
- Rule
- 1-byte variant index followed by variant-specific field data. 1 possible variants.
- Size
- variable (1+ bytes)
Examples
set = set(now)
0x00<field0>00 Variant index 0 = setfield 0 now: Compact<u64>Code Examples
import { TypeRegistry } from "@polkadot/types";
const registry = new TypeRegistry();
// Encode Timestamp::Call — variant "set"
const value = registry.createType("Timestamp::Call", { set: { now: 0 } });
console.log("Hex:", value.toHex());Type Parameters
T
Referenced By (23)
#249 RuntimeCall via System#249 RuntimeCall via Timestamp#249 RuntimeCall via Grandpa#249 RuntimeCall via Balances#249 RuntimeCall via SubtensorModule#249 RuntimeCall via Utility#249 RuntimeCall via Sudo#249 RuntimeCall via Multisig#249 RuntimeCall via Preimage#249 RuntimeCall via Scheduler#249 RuntimeCall via Proxy#249 RuntimeCall via Registry#249 RuntimeCall via Commitments#249 RuntimeCall via AdminUtils#249 RuntimeCall via SafeMode#249 RuntimeCall via Ethereum#249 RuntimeCall via EVM#249 RuntimeCall via BaseFee#249 RuntimeCall via Drand#249 RuntimeCall via Crowdloan
and 3 more...
Also See
Type Information
- Type ID
- 135
- Kind
- Variant
- Path
- pallet_timestamp::pallet::Call
- Runtime
- v411