File: src/Xcm/v5/BodyId/BodyId.sol
BodyId
Kind: source
Structs
struct BodyId
An identifier of a pluralistic body.
| Field | Type | Description |
|---|---|---|
variant | enum BodyIdVariant | The type of BodyId, which determines how to interpret the payload |
payload | bytes | For Moniker and Index types, this will hold the relevant data |
struct MonikerParams
Parameters for the Moniker variant.
| Field | Type | Description |
|---|---|---|
name | bytes4 | The 4-byte name of the moniker body. |
struct IndexParams
Parameters for the Index variant.
| Field | Type | Description |
|---|---|---|
index | uint32 | The index of the body. |
Enums
enum BodyIdVariant
Discriminant for the different types of BodyIds in XCM v5. Each variant corresponds to a specific structure of the payload.
| Variant | Description |
|---|---|
Unit | The only body in its context. |
Moniker | A named body. |
Index | An indexed body. |
Executive | The unambiguous executive body (for Polkadot, this would be the Polkadot council). |
Technical | The unambiguous technical body (for Polkadot, this would be the Technical Committee). |
Legislative | The unambiguous legislative body (for Polkadot, this could be considered the opinion of a majority of lock-voters). |
Judicial | The unambiguous judicial body (this doesn’t exist on Polkadot, but if it were to get a “grand oracle”, it may be considered as that). |
Defense | The unambiguous defense body (for Polkadot, an opinion on the topic given via a public referendum on the `staking_admin` track). |
Administration | The unambiguous administration body (for Polkadot, an opinion on the topic given via a public referendum on the `general_admin` track). |
Treasury | The unambiguous treasury body (for Polkadot, an opinion on the topic given via a public referendum on the `treasurer` track). |
Top-Level Functions
function unit() internal pure returns (struct BodyId)- Creates a
BodyIdrepresenting aUnitbody.
- Creates a
function moniker(struct MonikerParams params) internal pure returns (struct BodyId)- Creates a
BodyIdrepresenting aMonikerbody with the given 4-byte name.
- Creates a
function index(struct IndexParams params) internal pure returns (struct BodyId)- Creates a
BodyIdrepresenting anIndexbody with the given index.
- Creates a
function executive() internal pure returns (struct BodyId)- Creates a
BodyIdrepresenting anExecutivebody.
- Creates a
function technical() internal pure returns (struct BodyId)- Creates a
BodyIdrepresenting aTechnicalbody.
- Creates a
function legislative() internal pure returns (struct BodyId)- Creates a
BodyIdrepresenting aLegislativebody.
- Creates a
function judicial() internal pure returns (struct BodyId)- Creates a
BodyIdrepresenting aJudicialbody.
- Creates a
function defense() internal pure returns (struct BodyId)- Creates a
BodyIdrepresenting aDefensebody.
- Creates a
function administration() internal pure returns (struct BodyId)- Creates a
BodyIdrepresenting anAdministrationbody.
- Creates a
function treasury() internal pure returns (struct BodyId)- Creates a
BodyIdrepresenting aTreasurybody.
- Creates a