referrerpolicy=no-referrer-when-downgrade

staging_xcm_builder/
lib.rs

1// Copyright (C) Parity Technologies (UK) Ltd.
2// This file is part of Polkadot.
3
4// Polkadot is free software: you can redistribute it and/or modify
5// it under the terms of the GNU General Public License as published by
6// the Free Software Foundation, either version 3 of the License, or
7// (at your option) any later version.
8
9// Polkadot is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12// GNU General Public License for more details.
13
14// You should have received a copy of the GNU General Public License
15// along with Polkadot.  If not, see <http://www.gnu.org/licenses/>.
16
17//! # XCM-Builder
18//!
19//! Types and helpers for *building* XCM configuration.
20
21#![cfg_attr(not(feature = "std"), no_std)]
22
23extern crate alloc;
24extern crate core;
25
26#[cfg(test)]
27mod tests;
28
29#[cfg(feature = "std")]
30pub mod test_utils;
31
32mod asset_conversion;
33pub use asset_conversion::{
34	AsPrefixedGeneralIndex, ConvertedConcreteId, MatchClasslessInstances, MatchInClassInstances,
35	MatchedConvertedConcreteId,
36};
37
38mod asset_exchange;
39pub use asset_exchange::SingleAssetExchangeAdapter;
40
41mod barriers;
42pub use barriers::{
43	AllowExplicitUnpaidExecutionFrom, AllowHrmpNotificationsFromRelayChain,
44	AllowKnownQueryResponses, AllowSubscriptionsFrom, AllowTopLevelPaidExecutionFrom,
45	AllowUnpaidExecutionFrom, DenyRecursively, DenyReserveTransferToRelayChain, DenyThenTry,
46	IsChildSystemParachain, IsParentsOnly, IsSiblingSystemParachain, RespectSuspension,
47	TakeWeightCredit, TrailingSetTopicAsId, WithComputedOrigin,
48};
49
50mod controller;
51pub use controller::{
52	Controller, ExecuteController, ExecuteControllerWeightInfo, QueryController,
53	QueryControllerWeightInfo, QueryHandler, SendController, SendControllerWeightInfo,
54};
55
56mod forwarder;
57pub use forwarder::TeleportForwarderForAccountId32;
58
59mod fee_handling;
60pub use fee_handling::{
61	deposit_or_burn_fee, HandleFee, SendXcmFeeToAccount, XcmFeeManagerFromComponents,
62};
63
64mod filter_asset_location;
65pub use filter_asset_location::{AllAssets, Case, LocationWithAssetFilters, NativeAsset};
66
67mod fungible_adapter;
68pub use fungible_adapter::{FungibleAdapter, FungibleMutateAdapter, FungibleTransferAdapter};
69
70mod fungibles_adapter;
71pub use fungibles_adapter::{
72	AssetChecking, DualMint, FungiblesAdapter, FungiblesMutateAdapter, FungiblesTransferAdapter,
73	LocalMint, MintLocation, NoChecking, NonLocalMint,
74};
75
76mod location_conversion;
77pub use location_conversion::{
78	Account32Hash, AccountId32Aliases, AccountKey20Aliases, AliasesIntoAccountId32,
79	ChildParachainConvertsVia, DescribeAccountId32Terminal, DescribeAccountIdTerminal,
80	DescribeAccountKey20Terminal, DescribeAllTerminal, DescribeBodyTerminal, DescribeFamily,
81	DescribeLocation, DescribePalletTerminal, DescribeTerminus, DescribeTreasuryVoiceTerminal,
82	ExternalConsensusLocationsConverterFor, GlobalConsensusConvertsFor,
83	GlobalConsensusParachainConvertsFor, HashedDescription, LegacyDescribeForeignChainAccount,
84	LocalTreasuryVoiceConvertsVia, ParentIsPreset, SiblingParachainConvertsVia,
85};
86
87mod matches_location;
88pub use matches_location::{
89	StartsWith, StartsWithExplicitGlobalConsensus, WithLatestLocationConverter,
90};
91
92mod matches_token;
93pub use matches_token::IsConcrete;
94
95mod matcher;
96pub use matcher::{CreateMatcher, MatchXcm, Matcher};
97
98pub mod unique_instances;
99
100mod nonfungibles_adapter;
101pub use nonfungibles_adapter::{
102	NonFungiblesAdapter, NonFungiblesMutateAdapter, NonFungiblesTransferAdapter,
103};
104
105mod nonfungible_adapter;
106pub use nonfungible_adapter::{
107	NonFungibleAdapter, NonFungibleMutateAdapter, NonFungibleTransferAdapter,
108};
109
110mod origin_aliases;
111pub use origin_aliases::*;
112
113mod origin_conversion;
114pub use origin_conversion::{
115	BackingToPlurality, ChildParachainAsNative, ChildSystemParachainAsSuperuser, EnsureXcmOrigin,
116	LocationAsSuperuser, OriginToPluralityVoice, ParentAsSuperuser, RelayChainAsNative,
117	SiblingParachainAsNative, SiblingSystemParachainAsSuperuser, SignedAccountId32AsNative,
118	SignedAccountKey20AsNative, SignedToAccountId32, SovereignSignedViaLocation,
119};
120
121mod pay;
122pub use pay::{
123	FixedLocation, LocatableAssetId, PayAccountId32OnChainOverXcm, PayOverXcm, PayOverXcmWithHelper,
124};
125
126mod process_xcm_message;
127pub use process_xcm_message::ProcessXcmMessage;
128
129mod routing;
130pub use routing::{
131	EnsureDecodableXcm, EnsureDelivery, InspectMessageQueues, WithTopicSource, WithUniqueTopic,
132};
133
134mod transactional;
135pub use transactional::FrameTransactionalProcessor;
136
137mod transfer;
138pub use transfer::{Transfer, TransferOverXcm, TransferOverXcmHelper, TransferStatus};
139
140mod universal_exports;
141pub use universal_exports::{
142	ensure_is_remote, BridgeBlobDispatcher, BridgeMessage, DispatchBlob, DispatchBlobError,
143	ExporterFor, HaulBlob, HaulBlobError, HaulBlobExporter, LocalExporter, NetworkExportTable,
144	NetworkExportTableItem, SovereignPaidRemoteExporter, UnpaidRemoteExporter,
145};
146
147mod weight;
148pub use weight::{
149	FixedRateOfFungible, FixedWeightBounds, TakeRevenue, UsingComponents, WeightInfoBounds,
150};