Determinism

Variant 368 v393

pallet_contracts::wasm::Determinism

About This Type

Enum type: Determinism.

A tagged union where the first byte selects which variant is active, followed by that variant's data.

Encoding: 1-byte variant index followed by the selected variant's field data.

Variants (2)

IndexNameFieldsDocs
0Enforcednone
1Relaxednone

SCALE Encoding

Rule
1-byte variant index followed by variant-specific field data. 2 possible variants.
Size
variable (1+ bytes)

Examples

Enforced
0x00
00 Variant index 0 = Enforced
Relaxed
0x01
01 Variant index 1 = Relaxed

Code Examples

import { TypeRegistry } from "@polkadot/types";

const registry = new TypeRegistry();

// Encode Determinism — variant "Enforced"
const value = registry.createType("Determinism", "Enforced");
console.log("Hex:", value.toHex());

Referenced By (2)

Type Information

Type ID
368
Kind
Variant
Path
pallet_contracts::wasm::Determinism
Runtime
v393