import "solidity-scale-codec/src/Xcm/v5/Junction/Junction.sol";File-Level Functions
function parachain(struct ParachainParams params) internal pure returns (struct Junction)function accountId32(struct AccountId32Params params) internal pure returns (struct Junction)function accountIndex64(struct AccountIndex64Params params) internal pure returns (struct Junction)function accountKey20(struct AccountKey20Params params) internal pure returns (struct Junction)function palletInstance(struct PalletInstanceParams params) internal pure returns (struct Junction)function generalIndex(struct GeneralIndexParams params) internal pure returns (struct Junction)function generalKey(struct GeneralKeyParams params) internal pure returns (struct Junction)function onlyChild() internal pure returns (struct Junction)function plurality(struct PluralityParams params) internal pure returns (struct Junction)function globalConsensus() internal pure returns (struct Junction)
parachain(struct ParachainParams params)
function parachain(struct ParachainParams params) internal pure returns (struct Junction)Creates a `Parachain` junction with the given parachain ID.
accountId32(struct AccountId32Params params)
function accountId32(struct AccountId32Params params) internal pure returns (struct Junction)Creates an `AccountId32` junction with the specified parameters.
accountIndex64(struct AccountIndex64Params params)
function accountIndex64(struct AccountIndex64Params params) internal pure returns (struct Junction)Creates an `AccountIndex64` junction with the specified parameters.
accountKey20(struct AccountKey20Params params)
function accountKey20(struct AccountKey20Params params) internal pure returns (struct Junction)Creates an `AccountKey20` junction with the specified parameters.
palletInstance(struct PalletInstanceParams params)
function palletInstance(struct PalletInstanceParams params) internal pure returns (struct Junction)Creates a `PalletInstance` junction with the given instance index.
generalIndex(struct GeneralIndexParams params)
function generalIndex(struct GeneralIndexParams params) internal pure returns (struct Junction)Creates a `GeneralIndex` junction with the given index.
generalKey(struct GeneralKeyParams params)
function generalKey(struct GeneralKeyParams params) internal pure returns (struct Junction)Creates a `GeneralKey` junction with the given key.
onlyChild()
function onlyChild() internal pure returns (struct Junction)Creates an `OnlyChild` junction, which represents the unambiguous child in the context.
globalConsensus(struct GlobalConsensusParams params)
function globalConsensus(struct GlobalConsensusParams params) internal pure returns (struct Junction)Creates a `GlobalConsensus` junction, which represents a global network capable of externalizing its own consensus.
plurality(struct PluralityParams params)
function plurality(struct PluralityParams params) internal pure returns (struct Junction)Creates a `Plurality` junction with the specified body ID and body part.
globalConsensus()
function globalConsensus() internal pure returns (struct Junction)Creates a `GlobalConsensus` junction, which represents a global network capable of externalizing its own consensus.
File-Level Structs
ParachainParams
struct ParachainParamsParameters for a `Parachain` junction.
| Field | Type | Description |
|---|---|---|
parachainId | uint32 | The parachain identifier. |
AccountId32Params
struct AccountId32ParamsParameters for an `AccountId32` junction, containing optional network information and a 32-byte account identifier.
| Field | Type | Description |
|---|---|---|
false | if | - |
network | NetworkId | - |
id | bytes32 | The 32-byte identifier for the account. |
PluralityParams
struct PluralityParamsParameters for an `Plurality` junction
| Field | Type | Description |
|---|---|---|
id | BodyId | The identifier for the body of the plurality. See `BodyId` enum for details. |
part | BodyPart | The part of the body that is relevant for this junction. See `BodyPart` struct for details. |
AccountIndex64Params
struct AccountIndex64ParamsParameters for an `AccountIndex64` junction, containing optional network information and a 64-bit account index.
| Field | Type | Description |
|---|---|---|
false | if | - |
false | if | - |
index | uint64 | The 8-byte index identifier for the account. |
AccountKey20Params
struct AccountKey20ParamsParameters for an `AccountKey20` junction, containing optional network information and a 20-byte account key.
| Field | Type | Description |
|---|---|---|
false | if | - |
false | if | - |
key | address | The 20-byte key identifier for the account, represented as an `address` in Solidity. |
GeneralKeyParams
struct GeneralKeyParamsParameters for an `GeneralKey` junction
| Field | Type | Description |
|---|---|---|
length | uint8 | The length of the byte array acting as a key within the context location. This should be between 1 and 32, inclusive, to ensure valid encoding and decoding. |
key | bytes32 | The byte array acting as a key within the context location. |
PalletInstanceParams
struct PalletInstanceParamsParameters for a `PalletInstance` junction.
| Field | Type | Description |
|---|---|---|
instance | uint8 | The pallet instance index. |
GeneralIndexParams
struct GeneralIndexParamsParameters for a `GeneralIndex` junction.
| Field | Type | Description |
|---|---|---|
index | uint128 | The general compact index within context. |
GlobalConsensusParams
struct GlobalConsensusParamsParameters for a `GlobalConsensus` junction.
| Field | Type | Description |
|---|---|---|
network | NetworkId | The `NetworkId` associated with the global consensus, See `NetworkId` struct for details. |
Junction
struct JunctionA single item in a path to describe the relative location of a consensus system. Each item assumes a pre-existing location as its context and is defined in terms of it.
| Field | Type | Description |
|---|---|---|
variant | JunctionVariant | variant The type of the junction, determining how to interpret the payload. See `JunctionVariant` enum for possible values. |
payload | bytes | payload The SCALE-encoded data specific to the junction type. The structure of this data varies based on `variant`. |
File-Level Enums
JunctionVariant
enum JunctionVariant| Variant | Description |
|---|---|
Parachain | An indexed parachain belonging to and operated by the context. |
AccountId32 | - |
AccountIndex64 | Generally used when the context is a Frame-based chain. |
AccountKey20 | A 20-byte identifier for an account of a specific network that is respected as a sovereign endpoint within the context. |
PalletInstance | An instanced, indexed pallet that forms a constituent part of the context. |
GeneralIndex | A non-descript index within the context location. NOTE: Try to avoid using this and instead use a more specific item. |
GeneralKey | A nondescript array datum, 32 bytes, acting as a key within the context location. NOTE: Try to avoid using this and instead use a more specific item. |
OnlyChild | The unambiguous child. Not currently used except as a fallback when deriving context. |
Plurality | A pluralistic body existing within consensus. |
GlobalConsensus | A global network capable of externalizing its own consensus. This is not generally meaningful outside of the universal level. |
Junction
Kind: source