Put all mapping of InterfaceRegistry in one file (#1200)

* Remove module augmentation

* Put all definitions in one file

* Add back compacts
This commit is contained in:
Amaury Martiny
2019-07-26 13:53:12 +02:00
committed by Jaco Greeff
parent 2a37b8746d
commit ec0b9a84a3
20 changed files with 469 additions and 538 deletions
+433
View File
@@ -2,6 +2,24 @@
import { Compact, Option, Vec } from './codec';
import { AccountId, AccountIndex, Address, Block, Bool, Bytes, ConsensusEngineId, Data, Digest, DigestItem, Event, Extrinsic, ExtrinsicEra, Fixed64, H160, H256, H512, Header, I128, I16, I256, I32, I64, I8, ImmortalEra, Method, Moment, MortalEra, Null, Origin, SignaturePayload, StorageHasher, StorageKey, Text, Type, U128, U16, U256, U32, U64, U8, Vote, bool, i128, i16, i256, i32, i64, i8, u128, u16, u256, u32, u64, u8, usize } from './primitive';
import { AccountIdOf, Balance, BalanceOf, BlockNumber, Ed25519Signature, Hash, Index, Justification, KeyTypeId, KeyValue, LockIdentifier, Perbill, Permill, Phantom, SessionKeys, Signature, Sr25519Signature, StorageData, ValidatorId, Weight, WeightMultiplier } from './interfaces/runtime';
import { AuthorityId } from './interfaces/consensus';
import { Keys, SessionIndex } from './interfaces/session';
import { AuthorityWeight, NextAuthority, PendingPause, PendingResume, StoredPendingChange, StoredState } from './interfaces/grandpa';
import { ApprovalFlag, SetIndex, VoteIndex, VoteThreshold, VoterInfo } from './interfaces/elections';
import { InclusionHeight, Uncle, UncleEntryItem } from './interfaces/authorship';
import { BabeWeight } from './interfaces/babe';
import { BalanceLock, VestingSchedule, WithdrawReasons } from './interfaces/balances';
import { MemberCount, ProposalIndex, Votes } from './interfaces/collective';
import { AliveContractInfo, CodeHash, ContractInfo, ContractStorageKey, Gas, PrefabWasmModule, PrefabWasmModuleReserved, Schedule, SeedOf, TombstoneContractInfo, TrieId } from './interfaces/contracts';
import { Conviction, PropIndex, Proposal, ReferendumIndex, ReferendumInfo } from './interfaces/democracy';
import { AccountInfo, Amount, AssetOf, InherentOfflineReport, LockPeriods, NewAccountOutcome, OpaqueKey, SessionKey } from './interfaces/deprecated';
import { Heartbeat, OpaqueMultiaddr, OpaqueNetworkState, OpaquePeerId } from './interfaces/imOnline';
import { AttestedCandidate, AuctionIndex, BalanceUpload, Bidder, CandidateReceipt, CollatorSignature, EgressQueueRoot, HeadData, IncomingParachain, IncomingParachainDeploy, IncomingParachainFixed, LeasePeriod, LeasePeriodOf, NewBidder, ParaId, ParaIdOf, ParachainDispatchOrigin, SlotRange, SubId, UpwardMessage, ValidatorIndex, ValidityAttestation, ValidityVote, WinningData, WinningDataEntry } from './interfaces/parachains';
import { EraIndex, EraRewards, Exposure, IndividualExposure, MomentOf, RewardDestination, StakingLedger, UnlockChunk, ValidatorPrefs } from './interfaces/staking';
import { DigestOf, EventId, EventIndex, EventRecord, EventRecord0to76, Key, Phase } from './interfaces/system';
import { TreasuryProposal } from './interfaces/treasury';
import { ApiId, ChainProperties, Consensus, ExtrinsicStatus, Health, KeyValueOption, NetworkState, PeerInfo, PreRuntime, RuntimeVersion, RuntimeVersionApi, Seal, SealV0, SignedBlock, StorageChangeSet } from './interfaces/rpc';
export interface InterfaceRegistry {
AccountId: AccountId;
@@ -187,4 +205,419 @@ export interface InterfaceRegistry {
SignaturePayload: SignaturePayload;
'Option<SignaturePayload>': Option<SignaturePayload>;
'Vec<SignaturePayload>': Vec<SignaturePayload>;
AccountIdOf: AccountIdOf;
'Option<AccountIdOf>': Option<AccountIdOf>;
'Vec<AccountIdOf>': Vec<AccountIdOf>;
Balance: Balance;
'Compact<Balance>': Compact<Balance>;
'Option<Balance>': Option<Balance>;
'Vec<Balance>': Vec<Balance>;
BalanceOf: BalanceOf;
'Option<BalanceOf>': Option<BalanceOf>;
'Vec<BalanceOf>': Vec<BalanceOf>;
BlockNumber: BlockNumber;
'Compact<BlockNumber>': Compact<BlockNumber>;
'Option<BlockNumber>': Option<BlockNumber>;
'Vec<BlockNumber>': Vec<BlockNumber>;
Hash: Hash;
'Option<Hash>': Option<Hash>;
'Vec<Hash>': Vec<Hash>;
Justification: Justification;
'Option<Justification>': Option<Justification>;
'Vec<Justification>': Vec<Justification>;
KeyTypeId: KeyTypeId;
'Compact<KeyTypeId>': Compact<KeyTypeId>;
'Option<KeyTypeId>': Option<KeyTypeId>;
'Vec<KeyTypeId>': Vec<KeyTypeId>;
LockIdentifier: LockIdentifier;
'Option<LockIdentifier>': Option<LockIdentifier>;
'Vec<LockIdentifier>': Vec<LockIdentifier>;
Index: Index;
'Compact<Index>': Compact<Index>;
'Option<Index>': Option<Index>;
'Vec<Index>': Vec<Index>;
Perbill: Perbill;
'Compact<Perbill>': Compact<Perbill>;
'Option<Perbill>': Option<Perbill>;
'Vec<Perbill>': Vec<Perbill>;
Permill: Permill;
'Compact<Permill>': Compact<Permill>;
'Option<Permill>': Option<Permill>;
'Vec<Permill>': Vec<Permill>;
Phantom: Phantom;
'Option<Phantom>': Option<Phantom>;
'Vec<Phantom>': Vec<Phantom>;
SessionKeys: SessionKeys;
'Option<SessionKeys>': Option<SessionKeys>;
'Vec<SessionKeys>': Vec<SessionKeys>;
Signature: Signature;
'Option<Signature>': Option<Signature>;
'Vec<Signature>': Vec<Signature>;
Ed25519Signature: Ed25519Signature;
'Option<Ed25519Signature>': Option<Ed25519Signature>;
'Vec<Ed25519Signature>': Vec<Ed25519Signature>;
Sr25519Signature: Sr25519Signature;
'Option<Sr25519Signature>': Option<Sr25519Signature>;
'Vec<Sr25519Signature>': Vec<Sr25519Signature>;
StorageData: StorageData;
'Option<StorageData>': Option<StorageData>;
'Vec<StorageData>': Vec<StorageData>;
KeyValue: KeyValue;
'Option<KeyValue>': Option<KeyValue>;
'Vec<KeyValue>': Vec<KeyValue>;
ValidatorId: ValidatorId;
'Option<ValidatorId>': Option<ValidatorId>;
'Vec<ValidatorId>': Vec<ValidatorId>;
Weight: Weight;
'Compact<Weight>': Compact<Weight>;
'Option<Weight>': Option<Weight>;
'Vec<Weight>': Vec<Weight>;
WeightMultiplier: WeightMultiplier;
'Option<WeightMultiplier>': Option<WeightMultiplier>;
'Vec<WeightMultiplier>': Vec<WeightMultiplier>;
AuthorityId: AuthorityId;
'Option<AuthorityId>': Option<AuthorityId>;
'Vec<AuthorityId>': Vec<AuthorityId>;
SessionIndex: SessionIndex;
'Compact<SessionIndex>': Compact<SessionIndex>;
'Option<SessionIndex>': Option<SessionIndex>;
'Vec<SessionIndex>': Vec<SessionIndex>;
Keys: Keys;
'Option<Keys>': Option<Keys>;
'Vec<Keys>': Vec<Keys>;
AuthorityWeight: AuthorityWeight;
'Compact<AuthorityWeight>': Compact<AuthorityWeight>;
'Option<AuthorityWeight>': Option<AuthorityWeight>;
'Vec<AuthorityWeight>': Vec<AuthorityWeight>;
NextAuthority: NextAuthority;
'Option<NextAuthority>': Option<NextAuthority>;
'Vec<NextAuthority>': Vec<NextAuthority>;
PendingPause: PendingPause;
'Option<PendingPause>': Option<PendingPause>;
'Vec<PendingPause>': Vec<PendingPause>;
PendingResume: PendingResume;
'Option<PendingResume>': Option<PendingResume>;
'Vec<PendingResume>': Vec<PendingResume>;
StoredPendingChange: StoredPendingChange;
'Option<StoredPendingChange>': Option<StoredPendingChange>;
'Vec<StoredPendingChange>': Vec<StoredPendingChange>;
StoredState: StoredState;
'Option<StoredState>': Option<StoredState>;
'Vec<StoredState>': Vec<StoredState>;
ApprovalFlag: ApprovalFlag;
'Compact<ApprovalFlag>': Compact<ApprovalFlag>;
'Option<ApprovalFlag>': Option<ApprovalFlag>;
'Vec<ApprovalFlag>': Vec<ApprovalFlag>;
SetIndex: SetIndex;
'Compact<SetIndex>': Compact<SetIndex>;
'Option<SetIndex>': Option<SetIndex>;
'Vec<SetIndex>': Vec<SetIndex>;
VoteIndex: VoteIndex;
'Compact<VoteIndex>': Compact<VoteIndex>;
'Option<VoteIndex>': Option<VoteIndex>;
'Vec<VoteIndex>': Vec<VoteIndex>;
VoterInfo: VoterInfo;
'Option<VoterInfo>': Option<VoterInfo>;
'Vec<VoterInfo>': Vec<VoterInfo>;
VoteThreshold: VoteThreshold;
'Option<VoteThreshold>': Option<VoteThreshold>;
'Vec<VoteThreshold>': Vec<VoteThreshold>;
InclusionHeight: InclusionHeight;
'Option<InclusionHeight>': Option<InclusionHeight>;
'Vec<InclusionHeight>': Vec<InclusionHeight>;
Uncle: Uncle;
'Option<Uncle>': Option<Uncle>;
'Vec<Uncle>': Vec<Uncle>;
UncleEntryItem: UncleEntryItem;
'Option<UncleEntryItem>': Option<UncleEntryItem>;
'Vec<UncleEntryItem>': Vec<UncleEntryItem>;
BabeWeight: BabeWeight;
'Compact<BabeWeight>': Compact<BabeWeight>;
'Option<BabeWeight>': Option<BabeWeight>;
'Vec<BabeWeight>': Vec<BabeWeight>;
VestingSchedule: VestingSchedule;
'Option<VestingSchedule>': Option<VestingSchedule>;
'Vec<VestingSchedule>': Vec<VestingSchedule>;
WithdrawReasons: WithdrawReasons;
'Option<WithdrawReasons>': Option<WithdrawReasons>;
'Vec<WithdrawReasons>': Vec<WithdrawReasons>;
BalanceLock: BalanceLock;
'Option<BalanceLock>': Option<BalanceLock>;
'Vec<BalanceLock>': Vec<BalanceLock>;
MemberCount: MemberCount;
'Compact<MemberCount>': Compact<MemberCount>;
'Option<MemberCount>': Option<MemberCount>;
'Vec<MemberCount>': Vec<MemberCount>;
ProposalIndex: ProposalIndex;
'Compact<ProposalIndex>': Compact<ProposalIndex>;
'Option<ProposalIndex>': Option<ProposalIndex>;
'Vec<ProposalIndex>': Vec<ProposalIndex>;
Votes: Votes;
'Option<Votes>': Option<Votes>;
'Vec<Votes>': Vec<Votes>;
CodeHash: CodeHash;
'Option<CodeHash>': Option<CodeHash>;
'Vec<CodeHash>': Vec<CodeHash>;
TrieId: TrieId;
'Option<TrieId>': Option<TrieId>;
'Vec<TrieId>': Vec<TrieId>;
AliveContractInfo: AliveContractInfo;
'Option<AliveContractInfo>': Option<AliveContractInfo>;
'Vec<AliveContractInfo>': Vec<AliveContractInfo>;
TombstoneContractInfo: TombstoneContractInfo;
'Option<TombstoneContractInfo>': Option<TombstoneContractInfo>;
'Vec<TombstoneContractInfo>': Vec<TombstoneContractInfo>;
ContractInfo: ContractInfo;
'Option<ContractInfo>': Option<ContractInfo>;
'Vec<ContractInfo>': Vec<ContractInfo>;
ContractStorageKey: ContractStorageKey;
'Option<ContractStorageKey>': Option<ContractStorageKey>;
'Vec<ContractStorageKey>': Vec<ContractStorageKey>;
Gas: Gas;
'Compact<Gas>': Compact<Gas>;
'Option<Gas>': Option<Gas>;
'Vec<Gas>': Vec<Gas>;
PrefabWasmModuleReserved: PrefabWasmModuleReserved;
'Option<PrefabWasmModuleReserved>': Option<PrefabWasmModuleReserved>;
'Vec<PrefabWasmModuleReserved>': Vec<PrefabWasmModuleReserved>;
PrefabWasmModule: PrefabWasmModule;
'Option<PrefabWasmModule>': Option<PrefabWasmModule>;
'Vec<PrefabWasmModule>': Vec<PrefabWasmModule>;
Schedule: Schedule;
'Option<Schedule>': Option<Schedule>;
'Vec<Schedule>': Vec<Schedule>;
SeedOf: SeedOf;
'Option<SeedOf>': Option<SeedOf>;
'Vec<SeedOf>': Vec<SeedOf>;
Conviction: Conviction;
'Option<Conviction>': Option<Conviction>;
'Vec<Conviction>': Vec<Conviction>;
PropIndex: PropIndex;
'Compact<PropIndex>': Compact<PropIndex>;
'Option<PropIndex>': Option<PropIndex>;
'Vec<PropIndex>': Vec<PropIndex>;
Proposal: Proposal;
'Option<Proposal>': Option<Proposal>;
'Vec<Proposal>': Vec<Proposal>;
ReferendumIndex: ReferendumIndex;
'Compact<ReferendumIndex>': Compact<ReferendumIndex>;
'Option<ReferendumIndex>': Option<ReferendumIndex>;
'Vec<ReferendumIndex>': Vec<ReferendumIndex>;
ReferendumInfo: ReferendumInfo;
'Option<ReferendumInfo>': Option<ReferendumInfo>;
'Vec<ReferendumInfo>': Vec<ReferendumInfo>;
NewAccountOutcome: NewAccountOutcome;
'Option<NewAccountOutcome>': Option<NewAccountOutcome>;
'Vec<NewAccountOutcome>': Vec<NewAccountOutcome>;
Amount: Amount;
'Option<Amount>': Option<Amount>;
'Vec<Amount>': Vec<Amount>;
AssetOf: AssetOf;
'Compact<AssetOf>': Compact<AssetOf>;
'Option<AssetOf>': Option<AssetOf>;
'Vec<AssetOf>': Vec<AssetOf>;
AccountInfo: AccountInfo;
'Option<AccountInfo>': Option<AccountInfo>;
'Vec<AccountInfo>': Vec<AccountInfo>;
LockPeriods: LockPeriods;
'Option<LockPeriods>': Option<LockPeriods>;
'Vec<LockPeriods>': Vec<LockPeriods>;
InherentOfflineReport: InherentOfflineReport;
'Option<InherentOfflineReport>': Option<InherentOfflineReport>;
'Vec<InherentOfflineReport>': Vec<InherentOfflineReport>;
SessionKey: SessionKey;
'Option<SessionKey>': Option<SessionKey>;
'Vec<SessionKey>': Vec<SessionKey>;
OpaqueKey: OpaqueKey;
'Option<OpaqueKey>': Option<OpaqueKey>;
'Vec<OpaqueKey>': Vec<OpaqueKey>;
OpaqueMultiaddr: OpaqueMultiaddr;
'Option<OpaqueMultiaddr>': Option<OpaqueMultiaddr>;
'Vec<OpaqueMultiaddr>': Vec<OpaqueMultiaddr>;
OpaquePeerId: OpaquePeerId;
'Option<OpaquePeerId>': Option<OpaquePeerId>;
'Vec<OpaquePeerId>': Vec<OpaquePeerId>;
OpaqueNetworkState: OpaqueNetworkState;
'Option<OpaqueNetworkState>': Option<OpaqueNetworkState>;
'Vec<OpaqueNetworkState>': Vec<OpaqueNetworkState>;
Heartbeat: Heartbeat;
'Option<Heartbeat>': Option<Heartbeat>;
'Vec<Heartbeat>': Vec<Heartbeat>;
AuctionIndex: AuctionIndex;
'Compact<AuctionIndex>': Compact<AuctionIndex>;
'Option<AuctionIndex>': Option<AuctionIndex>;
'Vec<AuctionIndex>': Vec<AuctionIndex>;
CollatorSignature: CollatorSignature;
'Option<CollatorSignature>': Option<CollatorSignature>;
'Vec<CollatorSignature>': Vec<CollatorSignature>;
ValidityAttestation: ValidityAttestation;
'Option<ValidityAttestation>': Option<ValidityAttestation>;
'Vec<ValidityAttestation>': Vec<ValidityAttestation>;
ParaId: ParaId;
'Compact<ParaId>': Compact<ParaId>;
'Option<ParaId>': Option<ParaId>;
'Vec<ParaId>': Vec<ParaId>;
ParaIdOf: ParaIdOf;
'Option<ParaIdOf>': Option<ParaIdOf>;
'Vec<ParaIdOf>': Vec<ParaIdOf>;
ValidatorIndex: ValidatorIndex;
'Compact<ValidatorIndex>': Compact<ValidatorIndex>;
'Option<ValidatorIndex>': Option<ValidatorIndex>;
'Vec<ValidatorIndex>': Vec<ValidatorIndex>;
ValidityVote: ValidityVote;
'Option<ValidityVote>': Option<ValidityVote>;
'Vec<ValidityVote>': Vec<ValidityVote>;
BalanceUpload: BalanceUpload;
'Option<BalanceUpload>': Option<BalanceUpload>;
'Vec<BalanceUpload>': Vec<BalanceUpload>;
EgressQueueRoot: EgressQueueRoot;
'Option<EgressQueueRoot>': Option<EgressQueueRoot>;
'Vec<EgressQueueRoot>': Vec<EgressQueueRoot>;
HeadData: HeadData;
'Option<HeadData>': Option<HeadData>;
'Vec<HeadData>': Vec<HeadData>;
CandidateReceipt: CandidateReceipt;
'Option<CandidateReceipt>': Option<CandidateReceipt>;
'Vec<CandidateReceipt>': Vec<CandidateReceipt>;
AttestedCandidate: AttestedCandidate;
'Option<AttestedCandidate>': Option<AttestedCandidate>;
'Vec<AttestedCandidate>': Vec<AttestedCandidate>;
SubId: SubId;
'Compact<SubId>': Compact<SubId>;
'Option<SubId>': Option<SubId>;
'Vec<SubId>': Vec<SubId>;
NewBidder: NewBidder;
'Option<NewBidder>': Option<NewBidder>;
'Vec<NewBidder>': Vec<NewBidder>;
Bidder: Bidder;
'Option<Bidder>': Option<Bidder>;
'Vec<Bidder>': Vec<Bidder>;
IncomingParachainDeploy: IncomingParachainDeploy;
'Option<IncomingParachainDeploy>': Option<IncomingParachainDeploy>;
'Vec<IncomingParachainDeploy>': Vec<IncomingParachainDeploy>;
IncomingParachainFixed: IncomingParachainFixed;
'Option<IncomingParachainFixed>': Option<IncomingParachainFixed>;
'Vec<IncomingParachainFixed>': Vec<IncomingParachainFixed>;
IncomingParachain: IncomingParachain;
'Option<IncomingParachain>': Option<IncomingParachain>;
'Vec<IncomingParachain>': Vec<IncomingParachain>;
LeasePeriod: LeasePeriod;
'Option<LeasePeriod>': Option<LeasePeriod>;
'Vec<LeasePeriod>': Vec<LeasePeriod>;
LeasePeriodOf: LeasePeriodOf;
'Option<LeasePeriodOf>': Option<LeasePeriodOf>;
'Vec<LeasePeriodOf>': Vec<LeasePeriodOf>;
ParachainDispatchOrigin: ParachainDispatchOrigin;
'Option<ParachainDispatchOrigin>': Option<ParachainDispatchOrigin>;
'Vec<ParachainDispatchOrigin>': Vec<ParachainDispatchOrigin>;
SlotRange: SlotRange;
'Option<SlotRange>': Option<SlotRange>;
'Vec<SlotRange>': Vec<SlotRange>;
UpwardMessage: UpwardMessage;
'Option<UpwardMessage>': Option<UpwardMessage>;
'Vec<UpwardMessage>': Vec<UpwardMessage>;
WinningDataEntry: WinningDataEntry;
'Option<WinningDataEntry>': Option<WinningDataEntry>;
'Vec<WinningDataEntry>': Vec<WinningDataEntry>;
WinningData: WinningData;
'Option<WinningData>': Option<WinningData>;
'Vec<WinningData>': Vec<WinningData>;
EraIndex: EraIndex;
'Compact<EraIndex>': Compact<EraIndex>;
'Option<EraIndex>': Option<EraIndex>;
'Vec<EraIndex>': Vec<EraIndex>;
EraRewards: EraRewards;
'Option<EraRewards>': Option<EraRewards>;
'Vec<EraRewards>': Vec<EraRewards>;
IndividualExposure: IndividualExposure;
'Option<IndividualExposure>': Option<IndividualExposure>;
'Vec<IndividualExposure>': Vec<IndividualExposure>;
Exposure: Exposure;
'Option<Exposure>': Option<Exposure>;
'Vec<Exposure>': Vec<Exposure>;
MomentOf: MomentOf;
'Option<MomentOf>': Option<MomentOf>;
'Vec<MomentOf>': Vec<MomentOf>;
RewardDestination: RewardDestination;
'Option<RewardDestination>': Option<RewardDestination>;
'Vec<RewardDestination>': Vec<RewardDestination>;
UnlockChunk: UnlockChunk;
'Option<UnlockChunk>': Option<UnlockChunk>;
'Vec<UnlockChunk>': Vec<UnlockChunk>;
StakingLedger: StakingLedger;
'Option<StakingLedger>': Option<StakingLedger>;
'Vec<StakingLedger>': Vec<StakingLedger>;
ValidatorPrefs: ValidatorPrefs;
'Option<ValidatorPrefs>': Option<ValidatorPrefs>;
'Vec<ValidatorPrefs>': Vec<ValidatorPrefs>;
DigestOf: DigestOf;
'Option<DigestOf>': Option<DigestOf>;
'Vec<DigestOf>': Vec<DigestOf>;
EventId: EventId;
'Option<EventId>': Option<EventId>;
'Vec<EventId>': Vec<EventId>;
EventIndex: EventIndex;
'Compact<EventIndex>': Compact<EventIndex>;
'Option<EventIndex>': Option<EventIndex>;
'Vec<EventIndex>': Vec<EventIndex>;
Key: Key;
'Option<Key>': Option<Key>;
'Vec<Key>': Vec<Key>;
Phase: Phase;
'Option<Phase>': Option<Phase>;
'Vec<Phase>': Vec<Phase>;
EventRecord0to76: EventRecord0to76;
'Option<EventRecord0to76>': Option<EventRecord0to76>;
'Vec<EventRecord0to76>': Vec<EventRecord0to76>;
EventRecord: EventRecord;
'Option<EventRecord>': Option<EventRecord>;
'Vec<EventRecord>': Vec<EventRecord>;
TreasuryProposal: TreasuryProposal;
'Option<TreasuryProposal>': Option<TreasuryProposal>;
'Vec<TreasuryProposal>': Vec<TreasuryProposal>;
ApiId: ApiId;
'Option<ApiId>': Option<ApiId>;
'Vec<ApiId>': Vec<ApiId>;
ChainProperties: ChainProperties;
'Option<ChainProperties>': Option<ChainProperties>;
'Vec<ChainProperties>': Vec<ChainProperties>;
Consensus: Consensus;
'Option<Consensus>': Option<Consensus>;
'Vec<Consensus>': Vec<Consensus>;
ExtrinsicStatus: ExtrinsicStatus;
'Option<ExtrinsicStatus>': Option<ExtrinsicStatus>;
'Vec<ExtrinsicStatus>': Vec<ExtrinsicStatus>;
Health: Health;
'Option<Health>': Option<Health>;
'Vec<Health>': Vec<Health>;
KeyValueOption: KeyValueOption;
'Option<KeyValueOption>': Option<KeyValueOption>;
'Vec<KeyValueOption>': Vec<KeyValueOption>;
NetworkState: NetworkState;
'Option<NetworkState>': Option<NetworkState>;
'Vec<NetworkState>': Vec<NetworkState>;
PeerInfo: PeerInfo;
'Option<PeerInfo>': Option<PeerInfo>;
'Vec<PeerInfo>': Vec<PeerInfo>;
PreRuntime: PreRuntime;
'Option<PreRuntime>': Option<PreRuntime>;
'Vec<PreRuntime>': Vec<PreRuntime>;
RuntimeVersionApi: RuntimeVersionApi;
'Option<RuntimeVersionApi>': Option<RuntimeVersionApi>;
'Vec<RuntimeVersionApi>': Vec<RuntimeVersionApi>;
RuntimeVersion: RuntimeVersion;
'Option<RuntimeVersion>': Option<RuntimeVersion>;
'Vec<RuntimeVersion>': Vec<RuntimeVersion>;
SealV0: SealV0;
'Option<SealV0>': Option<SealV0>;
'Vec<SealV0>': Vec<SealV0>;
Seal: Seal;
'Option<Seal>': Option<Seal>;
'Vec<Seal>': Vec<Seal>;
SignedBlock: SignedBlock;
'Option<SignedBlock>': Option<SignedBlock>;
'Vec<SignedBlock>': Vec<SignedBlock>;
StorageChangeSet: StorageChangeSet;
'Option<StorageChangeSet>': Option<StorageChangeSet>;
'Vec<StorageChangeSet>': Vec<StorageChangeSet>;
}
@@ -1,7 +1,7 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Codec } from '../../types';
import { Enum, Option, Vec } from '../../codec';
import { Enum, Option } from '../../codec';
import { AccountId } from '../../primitive';
import { BlockNumber, Hash } from '../runtime';
@@ -22,17 +22,3 @@ export interface UncleEntryItem extends Enum {
/** Uncle */
readonly asUncle: Uncle;
}
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
InclusionHeight: InclusionHeight;
'Option<InclusionHeight>': Option<InclusionHeight>;
'Vec<InclusionHeight>': Vec<InclusionHeight>;
Uncle: Uncle;
'Option<Uncle>': Option<Uncle>;
'Vec<Uncle>': Vec<Uncle>;
UncleEntryItem: UncleEntryItem;
'Option<UncleEntryItem>': Option<UncleEntryItem>;
'Vec<UncleEntryItem>': Vec<UncleEntryItem>;
}
}
@@ -1,16 +1,6 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Compact, Option, Vec } from '../../codec';
import { u64 } from '../../primitive';
/** u64 */
export type BabeWeight = u64;
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
BabeWeight: BabeWeight;
'Compact<BabeWeight>': Compact<BabeWeight>;
'Option<BabeWeight>': Option<BabeWeight>;
'Vec<BabeWeight>': Vec<BabeWeight>;
}
}
@@ -1,6 +1,6 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Option, Set, Struct, Vec } from '../../codec';
import { Set, Struct } from '../../codec';
import { Balance, BlockNumber, LockIdentifier } from '../runtime';
/** Struct */
@@ -34,17 +34,3 @@ export interface WithdrawReasons extends Set {
/** boolean */
readonly isFee: boolean;
}
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
VestingSchedule: VestingSchedule;
'Option<VestingSchedule>': Option<VestingSchedule>;
'Vec<VestingSchedule>': Vec<VestingSchedule>;
WithdrawReasons: WithdrawReasons;
'Option<WithdrawReasons>': Option<WithdrawReasons>;
'Vec<WithdrawReasons>': Vec<WithdrawReasons>;
BalanceLock: BalanceLock;
'Option<BalanceLock>': Option<BalanceLock>;
'Vec<BalanceLock>': Vec<BalanceLock>;
}
}
@@ -1,6 +1,6 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Compact, Option, Struct, Vec } from '../../codec';
import { Struct, Vec } from '../../codec';
import { AccountId, u32, u64 } from '../../primitive';
/** u64 */
@@ -20,19 +20,3 @@ export interface Votes extends Struct {
/** Vec<AccountId> */
readonly nays: Vec<AccountId>;
}
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
MemberCount: MemberCount;
'Compact<MemberCount>': Compact<MemberCount>;
'Option<MemberCount>': Option<MemberCount>;
'Vec<MemberCount>': Vec<MemberCount>;
ProposalIndex: ProposalIndex;
'Compact<ProposalIndex>': Compact<ProposalIndex>;
'Option<ProposalIndex>': Option<ProposalIndex>;
'Vec<ProposalIndex>': Vec<ProposalIndex>;
Votes: Votes;
'Option<Votes>': Option<Votes>;
'Vec<Votes>': Vec<Votes>;
}
}
@@ -1,15 +1,6 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Option, Vec } from '../../codec';
import { AccountId } from '../../primitive';
/** AccountId */
export type AuthorityId = AccountId;
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
AuthorityId: AuthorityId;
'Option<AuthorityId>': Option<AuthorityId>;
'Vec<AuthorityId>': Vec<AuthorityId>;
}
}
@@ -100,42 +100,3 @@ export type TombstoneContractInfo = Hash;
/** Bytes */
export type TrieId = Bytes;
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
CodeHash: CodeHash;
'Option<CodeHash>': Option<CodeHash>;
'Vec<CodeHash>': Vec<CodeHash>;
TrieId: TrieId;
'Option<TrieId>': Option<TrieId>;
'Vec<TrieId>': Vec<TrieId>;
AliveContractInfo: AliveContractInfo;
'Option<AliveContractInfo>': Option<AliveContractInfo>;
'Vec<AliveContractInfo>': Vec<AliveContractInfo>;
TombstoneContractInfo: TombstoneContractInfo;
'Option<TombstoneContractInfo>': Option<TombstoneContractInfo>;
'Vec<TombstoneContractInfo>': Vec<TombstoneContractInfo>;
ContractInfo: ContractInfo;
'Option<ContractInfo>': Option<ContractInfo>;
'Vec<ContractInfo>': Vec<ContractInfo>;
ContractStorageKey: ContractStorageKey;
'Option<ContractStorageKey>': Option<ContractStorageKey>;
'Vec<ContractStorageKey>': Vec<ContractStorageKey>;
Gas: Gas;
'Compact<Gas>': Compact<Gas>;
'Option<Gas>': Option<Gas>;
'Vec<Gas>': Vec<Gas>;
PrefabWasmModuleReserved: PrefabWasmModuleReserved;
'Option<PrefabWasmModuleReserved>': Option<PrefabWasmModuleReserved>;
'Vec<PrefabWasmModuleReserved>': Vec<PrefabWasmModuleReserved>;
PrefabWasmModule: PrefabWasmModule;
'Option<PrefabWasmModule>': Option<PrefabWasmModule>;
'Vec<PrefabWasmModule>': Vec<PrefabWasmModule>;
Schedule: Schedule;
'Option<Schedule>': Option<Schedule>;
'Vec<Schedule>': Vec<Schedule>;
SeedOf: SeedOf;
'Option<SeedOf>': Option<SeedOf>;
'Vec<SeedOf>': Vec<SeedOf>;
}
}
@@ -1,6 +1,6 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Compact, Enum, Option, Struct, Vec } from '../../codec';
import { Enum, Struct } from '../../codec';
import { Method, u32 } from '../../primitive';
import { BlockNumber } from '../runtime';
import { VoteThreshold } from '../elections';
@@ -41,25 +41,3 @@ export interface ReferendumInfo extends Struct {
/** BlockNumber */
readonly delay: BlockNumber;
}
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
Conviction: Conviction;
'Option<Conviction>': Option<Conviction>;
'Vec<Conviction>': Vec<Conviction>;
PropIndex: PropIndex;
'Compact<PropIndex>': Compact<PropIndex>;
'Option<PropIndex>': Option<PropIndex>;
'Vec<PropIndex>': Vec<PropIndex>;
Proposal: Proposal;
'Option<Proposal>': Option<Proposal>;
'Vec<Proposal>': Vec<Proposal>;
ReferendumIndex: ReferendumIndex;
'Compact<ReferendumIndex>': Compact<ReferendumIndex>;
'Option<ReferendumIndex>': Option<ReferendumIndex>;
'Vec<ReferendumIndex>': Vec<ReferendumIndex>;
ReferendumInfo: ReferendumInfo;
'Option<ReferendumInfo>': Option<ReferendumInfo>;
'Vec<ReferendumInfo>': Vec<ReferendumInfo>;
}
}
@@ -1,6 +1,6 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Compact, Enum, Option, Struct, Vec } from '../../codec';
import { Enum, Struct } from '../../codec';
import { AccountId, Bytes, Null, i8, u32, u64 } from '../../primitive';
import { Balance } from '../runtime';
@@ -39,33 +39,3 @@ export type OpaqueKey = Bytes;
/** AccountId */
export type SessionKey = AccountId;
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
NewAccountOutcome: NewAccountOutcome;
'Option<NewAccountOutcome>': Option<NewAccountOutcome>;
'Vec<NewAccountOutcome>': Vec<NewAccountOutcome>;
Amount: Amount;
'Option<Amount>': Option<Amount>;
'Vec<Amount>': Vec<Amount>;
AssetOf: AssetOf;
'Compact<AssetOf>': Compact<AssetOf>;
'Option<AssetOf>': Option<AssetOf>;
'Vec<AssetOf>': Vec<AssetOf>;
AccountInfo: AccountInfo;
'Option<AccountInfo>': Option<AccountInfo>;
'Vec<AccountInfo>': Vec<AccountInfo>;
LockPeriods: LockPeriods;
'Option<LockPeriods>': Option<LockPeriods>;
'Vec<LockPeriods>': Vec<LockPeriods>;
InherentOfflineReport: InherentOfflineReport;
'Option<InherentOfflineReport>': Option<InherentOfflineReport>;
'Vec<InherentOfflineReport>': Vec<InherentOfflineReport>;
SessionKey: SessionKey;
'Option<SessionKey>': Option<SessionKey>;
'Vec<SessionKey>': Vec<SessionKey>;
OpaqueKey: OpaqueKey;
'Option<OpaqueKey>': Option<OpaqueKey>;
'Vec<OpaqueKey>': Vec<OpaqueKey>;
}
}
@@ -1,6 +1,6 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Compact, Enum, Option, Struct, Vec } from '../../codec';
import { Enum, Struct } from '../../codec';
import { u32 } from '../../primitive';
import { Balance } from '../runtime';
@@ -34,26 +34,3 @@ export interface VoteThreshold extends Enum {
/** 2:: Simple majority */
readonly isSimpleMajority: boolean;
}
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
ApprovalFlag: ApprovalFlag;
'Compact<ApprovalFlag>': Compact<ApprovalFlag>;
'Option<ApprovalFlag>': Option<ApprovalFlag>;
'Vec<ApprovalFlag>': Vec<ApprovalFlag>;
SetIndex: SetIndex;
'Compact<SetIndex>': Compact<SetIndex>;
'Option<SetIndex>': Option<SetIndex>;
'Vec<SetIndex>': Vec<SetIndex>;
VoteIndex: VoteIndex;
'Compact<VoteIndex>': Compact<VoteIndex>;
'Option<VoteIndex>': Option<VoteIndex>;
'Vec<VoteIndex>': Vec<VoteIndex>;
VoterInfo: VoterInfo;
'Option<VoterInfo>': Option<VoterInfo>;
'Vec<VoterInfo>': Vec<VoterInfo>;
VoteThreshold: VoteThreshold;
'Option<VoteThreshold>': Option<VoteThreshold>;
'Vec<VoteThreshold>': Vec<VoteThreshold>;
}
}
+1 -25
View File
@@ -1,7 +1,7 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Codec } from '../../types';
import { Compact, Enum, Option, Struct, Vec } from '../../codec';
import { Enum, Struct, Vec } from '../../codec';
import { u64 } from '../../primitive';
import { BlockNumber } from '../runtime';
import { AuthorityId } from '../consensus';
@@ -53,27 +53,3 @@ export interface StoredState extends Enum {
/** PendingResume */
readonly asPendingResume: PendingResume;
}
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
AuthorityWeight: AuthorityWeight;
'Compact<AuthorityWeight>': Compact<AuthorityWeight>;
'Option<AuthorityWeight>': Option<AuthorityWeight>;
'Vec<AuthorityWeight>': Vec<AuthorityWeight>;
NextAuthority: NextAuthority;
'Option<NextAuthority>': Option<NextAuthority>;
'Vec<NextAuthority>': Vec<NextAuthority>;
PendingPause: PendingPause;
'Option<PendingPause>': Option<PendingPause>;
'Vec<PendingPause>': Vec<PendingPause>;
PendingResume: PendingResume;
'Option<PendingResume>': Option<PendingResume>;
'Vec<PendingResume>': Vec<PendingResume>;
StoredPendingChange: StoredPendingChange;
'Option<StoredPendingChange>': Option<StoredPendingChange>;
'Vec<StoredPendingChange>': Vec<StoredPendingChange>;
StoredState: StoredState;
'Option<StoredState>': Option<StoredState>;
'Vec<StoredState>': Vec<StoredState>;
}
}
@@ -1,6 +1,6 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Option, Struct, Vec } from '../../codec';
import { Struct, Vec } from '../../codec';
import { Bytes } from '../../primitive';
import { BlockNumber } from '../runtime';
import { AuthorityId } from '../consensus';
@@ -31,20 +31,3 @@ export interface OpaqueNetworkState extends Struct {
/** Bytes */
export type OpaquePeerId = Bytes;
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
OpaqueMultiaddr: OpaqueMultiaddr;
'Option<OpaqueMultiaddr>': Option<OpaqueMultiaddr>;
'Vec<OpaqueMultiaddr>': Vec<OpaqueMultiaddr>;
OpaquePeerId: OpaquePeerId;
'Option<OpaquePeerId>': Option<OpaquePeerId>;
'Vec<OpaquePeerId>': Vec<OpaquePeerId>;
OpaqueNetworkState: OpaqueNetworkState;
'Option<OpaqueNetworkState>': Option<OpaqueNetworkState>;
'Vec<OpaqueNetworkState>': Vec<OpaqueNetworkState>;
Heartbeat: Heartbeat;
'Option<Heartbeat>': Option<Heartbeat>;
'Vec<Heartbeat>': Vec<Heartbeat>;
}
}
@@ -1,7 +1,7 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Codec } from '../../types';
import { Compact, Enum, Option, Struct, Vec } from '../../codec';
import { Enum, Struct, Vec } from '../../codec';
import { AccountId, Bytes, u32, u64 } from '../../primitive';
import { BalanceOf, BlockNumber, Hash, Signature } from '../runtime';
@@ -180,87 +180,3 @@ export type WinningData = Vec<WinningDataEntry>;
/** [AccountId, ParaIdOf, BalanceOf] & Codec */
export type WinningDataEntry = [AccountId, ParaIdOf, BalanceOf] & Codec;
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
AuctionIndex: AuctionIndex;
'Compact<AuctionIndex>': Compact<AuctionIndex>;
'Option<AuctionIndex>': Option<AuctionIndex>;
'Vec<AuctionIndex>': Vec<AuctionIndex>;
CollatorSignature: CollatorSignature;
'Option<CollatorSignature>': Option<CollatorSignature>;
'Vec<CollatorSignature>': Vec<CollatorSignature>;
ValidityAttestation: ValidityAttestation;
'Option<ValidityAttestation>': Option<ValidityAttestation>;
'Vec<ValidityAttestation>': Vec<ValidityAttestation>;
ParaId: ParaId;
'Compact<ParaId>': Compact<ParaId>;
'Option<ParaId>': Option<ParaId>;
'Vec<ParaId>': Vec<ParaId>;
ParaIdOf: ParaIdOf;
'Option<ParaIdOf>': Option<ParaIdOf>;
'Vec<ParaIdOf>': Vec<ParaIdOf>;
ValidatorIndex: ValidatorIndex;
'Compact<ValidatorIndex>': Compact<ValidatorIndex>;
'Option<ValidatorIndex>': Option<ValidatorIndex>;
'Vec<ValidatorIndex>': Vec<ValidatorIndex>;
ValidityVote: ValidityVote;
'Option<ValidityVote>': Option<ValidityVote>;
'Vec<ValidityVote>': Vec<ValidityVote>;
BalanceUpload: BalanceUpload;
'Option<BalanceUpload>': Option<BalanceUpload>;
'Vec<BalanceUpload>': Vec<BalanceUpload>;
EgressQueueRoot: EgressQueueRoot;
'Option<EgressQueueRoot>': Option<EgressQueueRoot>;
'Vec<EgressQueueRoot>': Vec<EgressQueueRoot>;
HeadData: HeadData;
'Option<HeadData>': Option<HeadData>;
'Vec<HeadData>': Vec<HeadData>;
CandidateReceipt: CandidateReceipt;
'Option<CandidateReceipt>': Option<CandidateReceipt>;
'Vec<CandidateReceipt>': Vec<CandidateReceipt>;
AttestedCandidate: AttestedCandidate;
'Option<AttestedCandidate>': Option<AttestedCandidate>;
'Vec<AttestedCandidate>': Vec<AttestedCandidate>;
SubId: SubId;
'Compact<SubId>': Compact<SubId>;
'Option<SubId>': Option<SubId>;
'Vec<SubId>': Vec<SubId>;
NewBidder: NewBidder;
'Option<NewBidder>': Option<NewBidder>;
'Vec<NewBidder>': Vec<NewBidder>;
Bidder: Bidder;
'Option<Bidder>': Option<Bidder>;
'Vec<Bidder>': Vec<Bidder>;
IncomingParachainDeploy: IncomingParachainDeploy;
'Option<IncomingParachainDeploy>': Option<IncomingParachainDeploy>;
'Vec<IncomingParachainDeploy>': Vec<IncomingParachainDeploy>;
IncomingParachainFixed: IncomingParachainFixed;
'Option<IncomingParachainFixed>': Option<IncomingParachainFixed>;
'Vec<IncomingParachainFixed>': Vec<IncomingParachainFixed>;
IncomingParachain: IncomingParachain;
'Option<IncomingParachain>': Option<IncomingParachain>;
'Vec<IncomingParachain>': Vec<IncomingParachain>;
LeasePeriod: LeasePeriod;
'Option<LeasePeriod>': Option<LeasePeriod>;
'Vec<LeasePeriod>': Vec<LeasePeriod>;
LeasePeriodOf: LeasePeriodOf;
'Option<LeasePeriodOf>': Option<LeasePeriodOf>;
'Vec<LeasePeriodOf>': Vec<LeasePeriodOf>;
ParachainDispatchOrigin: ParachainDispatchOrigin;
'Option<ParachainDispatchOrigin>': Option<ParachainDispatchOrigin>;
'Vec<ParachainDispatchOrigin>': Vec<ParachainDispatchOrigin>;
SlotRange: SlotRange;
'Option<SlotRange>': Option<SlotRange>;
'Vec<SlotRange>': Vec<SlotRange>;
UpwardMessage: UpwardMessage;
'Option<UpwardMessage>': Option<UpwardMessage>;
'Vec<UpwardMessage>': Vec<UpwardMessage>;
WinningDataEntry: WinningDataEntry;
'Option<WinningDataEntry>': Option<WinningDataEntry>;
'Vec<WinningDataEntry>': Vec<WinningDataEntry>;
WinningData: WinningData;
'Option<WinningData>': Option<WinningData>;
'Vec<WinningData>': Vec<WinningData>;
}
}
@@ -119,53 +119,3 @@ export interface StorageChangeSet extends Struct {
/** Vec<KeyValueOption> */
readonly changes: Vec<KeyValueOption>;
}
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
ApiId: ApiId;
'Option<ApiId>': Option<ApiId>;
'Vec<ApiId>': Vec<ApiId>;
ChainProperties: ChainProperties;
'Option<ChainProperties>': Option<ChainProperties>;
'Vec<ChainProperties>': Vec<ChainProperties>;
Consensus: Consensus;
'Option<Consensus>': Option<Consensus>;
'Vec<Consensus>': Vec<Consensus>;
ExtrinsicStatus: ExtrinsicStatus;
'Option<ExtrinsicStatus>': Option<ExtrinsicStatus>;
'Vec<ExtrinsicStatus>': Vec<ExtrinsicStatus>;
Health: Health;
'Option<Health>': Option<Health>;
'Vec<Health>': Vec<Health>;
KeyValueOption: KeyValueOption;
'Option<KeyValueOption>': Option<KeyValueOption>;
'Vec<KeyValueOption>': Vec<KeyValueOption>;
NetworkState: NetworkState;
'Option<NetworkState>': Option<NetworkState>;
'Vec<NetworkState>': Vec<NetworkState>;
PeerInfo: PeerInfo;
'Option<PeerInfo>': Option<PeerInfo>;
'Vec<PeerInfo>': Vec<PeerInfo>;
PreRuntime: PreRuntime;
'Option<PreRuntime>': Option<PreRuntime>;
'Vec<PreRuntime>': Vec<PreRuntime>;
RuntimeVersionApi: RuntimeVersionApi;
'Option<RuntimeVersionApi>': Option<RuntimeVersionApi>;
'Vec<RuntimeVersionApi>': Vec<RuntimeVersionApi>;
RuntimeVersion: RuntimeVersion;
'Option<RuntimeVersion>': Option<RuntimeVersion>;
'Vec<RuntimeVersion>': Vec<RuntimeVersion>;
SealV0: SealV0;
'Option<SealV0>': Option<SealV0>;
'Vec<SealV0>': Vec<SealV0>;
Seal: Seal;
'Option<Seal>': Option<Seal>;
'Vec<Seal>': Vec<Seal>;
SignedBlock: SignedBlock;
'Option<SignedBlock>': Option<SignedBlock>;
'Vec<SignedBlock>': Vec<SignedBlock>;
StorageChangeSet: StorageChangeSet;
'Option<StorageChangeSet>': Option<StorageChangeSet>;
'Vec<StorageChangeSet>': Vec<StorageChangeSet>;
}
}
+1 -76
View File
@@ -1,7 +1,7 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Codec } from '../../types';
import { Compact, Option, Struct, Vec } from '../../codec';
import { Struct, Vec } from '../../codec';
import { AccountId, Bytes, Fixed64, H256, H512, Null, StorageKey, u128, u32, u64, u8 } from '../../primitive';
/** AccountId */
@@ -69,78 +69,3 @@ export type Weight = u32;
/** Fixed64 */
export type WeightMultiplier = Fixed64;
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
AccountIdOf: AccountIdOf;
'Option<AccountIdOf>': Option<AccountIdOf>;
'Vec<AccountIdOf>': Vec<AccountIdOf>;
Balance: Balance;
'Compact<Balance>': Compact<Balance>;
'Option<Balance>': Option<Balance>;
'Vec<Balance>': Vec<Balance>;
BalanceOf: BalanceOf;
'Option<BalanceOf>': Option<BalanceOf>;
'Vec<BalanceOf>': Vec<BalanceOf>;
BlockNumber: BlockNumber;
'Compact<BlockNumber>': Compact<BlockNumber>;
'Option<BlockNumber>': Option<BlockNumber>;
'Vec<BlockNumber>': Vec<BlockNumber>;
Hash: Hash;
'Option<Hash>': Option<Hash>;
'Vec<Hash>': Vec<Hash>;
Justification: Justification;
'Option<Justification>': Option<Justification>;
'Vec<Justification>': Vec<Justification>;
KeyTypeId: KeyTypeId;
'Compact<KeyTypeId>': Compact<KeyTypeId>;
'Option<KeyTypeId>': Option<KeyTypeId>;
'Vec<KeyTypeId>': Vec<KeyTypeId>;
LockIdentifier: LockIdentifier;
'Option<LockIdentifier>': Option<LockIdentifier>;
'Vec<LockIdentifier>': Vec<LockIdentifier>;
Index: Index;
'Compact<Index>': Compact<Index>;
'Option<Index>': Option<Index>;
'Vec<Index>': Vec<Index>;
Perbill: Perbill;
'Compact<Perbill>': Compact<Perbill>;
'Option<Perbill>': Option<Perbill>;
'Vec<Perbill>': Vec<Perbill>;
Permill: Permill;
'Compact<Permill>': Compact<Permill>;
'Option<Permill>': Option<Permill>;
'Vec<Permill>': Vec<Permill>;
Phantom: Phantom;
'Option<Phantom>': Option<Phantom>;
'Vec<Phantom>': Vec<Phantom>;
SessionKeys: SessionKeys;
'Option<SessionKeys>': Option<SessionKeys>;
'Vec<SessionKeys>': Vec<SessionKeys>;
Signature: Signature;
'Option<Signature>': Option<Signature>;
'Vec<Signature>': Vec<Signature>;
Ed25519Signature: Ed25519Signature;
'Option<Ed25519Signature>': Option<Ed25519Signature>;
'Vec<Ed25519Signature>': Vec<Ed25519Signature>;
Sr25519Signature: Sr25519Signature;
'Option<Sr25519Signature>': Option<Sr25519Signature>;
'Vec<Sr25519Signature>': Vec<Sr25519Signature>;
StorageData: StorageData;
'Option<StorageData>': Option<StorageData>;
'Vec<StorageData>': Vec<StorageData>;
KeyValue: KeyValue;
'Option<KeyValue>': Option<KeyValue>;
'Vec<KeyValue>': Vec<KeyValue>;
ValidatorId: ValidatorId;
'Option<ValidatorId>': Option<ValidatorId>;
'Vec<ValidatorId>': Vec<ValidatorId>;
Weight: Weight;
'Compact<Weight>': Compact<Weight>;
'Option<Weight>': Option<Weight>;
'Vec<Weight>': Vec<Weight>;
WeightMultiplier: WeightMultiplier;
'Option<WeightMultiplier>': Option<WeightMultiplier>;
'Vec<WeightMultiplier>': Vec<WeightMultiplier>;
}
}
@@ -1,6 +1,5 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Compact, Option, Vec } from '../../codec';
import { u32 } from '../../primitive';
import { SessionKeys } from '../runtime';
@@ -9,15 +8,3 @@ export type Keys = SessionKeys;
/** u32 */
export type SessionIndex = u32;
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
SessionIndex: SessionIndex;
'Compact<SessionIndex>': Compact<SessionIndex>;
'Option<SessionIndex>': Option<SessionIndex>;
'Vec<SessionIndex>': Vec<SessionIndex>;
Keys: Keys;
'Option<Keys>': Option<Keys>;
'Vec<Keys>': Vec<Keys>;
}
}
+1 -34
View File
@@ -1,6 +1,6 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Compact, Enum, Option, Struct, Vec } from '../../codec';
import { Compact, Enum, Struct, Vec } from '../../codec';
import { AccountId, Moment, u32 } from '../../primitive';
import { Balance, BlockNumber } from '../runtime';
@@ -73,36 +73,3 @@ export interface ValidatorPrefs extends Struct {
/** Compact<Balance> */
readonly validatorPayment: Compact<Balance>;
}
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
EraIndex: EraIndex;
'Compact<EraIndex>': Compact<EraIndex>;
'Option<EraIndex>': Option<EraIndex>;
'Vec<EraIndex>': Vec<EraIndex>;
EraRewards: EraRewards;
'Option<EraRewards>': Option<EraRewards>;
'Vec<EraRewards>': Vec<EraRewards>;
IndividualExposure: IndividualExposure;
'Option<IndividualExposure>': Option<IndividualExposure>;
'Vec<IndividualExposure>': Vec<IndividualExposure>;
Exposure: Exposure;
'Option<Exposure>': Option<Exposure>;
'Vec<Exposure>': Vec<Exposure>;
MomentOf: MomentOf;
'Option<MomentOf>': Option<MomentOf>;
'Vec<MomentOf>': Vec<MomentOf>;
RewardDestination: RewardDestination;
'Option<RewardDestination>': Option<RewardDestination>;
'Vec<RewardDestination>': Vec<RewardDestination>;
UnlockChunk: UnlockChunk;
'Option<UnlockChunk>': Option<UnlockChunk>;
'Vec<UnlockChunk>': Vec<UnlockChunk>;
StakingLedger: StakingLedger;
'Option<StakingLedger>': Option<StakingLedger>;
'Vec<StakingLedger>': Vec<StakingLedger>;
ValidatorPrefs: ValidatorPrefs;
'Option<ValidatorPrefs>': Option<ValidatorPrefs>;
'Vec<ValidatorPrefs>': Vec<ValidatorPrefs>;
}
}
+1 -28
View File
@@ -1,6 +1,6 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Compact, Enum, Option, Struct, Vec } from '../../codec';
import { Enum, Struct, Vec } from '../../codec';
import { Bytes, Digest, Event, u32, u8 } from '../../primitive';
import { Hash } from '../runtime';
@@ -43,30 +43,3 @@ export interface Phase extends Enum {
/** 1:: Finalization */
readonly isFinalization: boolean;
}
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
DigestOf: DigestOf;
'Option<DigestOf>': Option<DigestOf>;
'Vec<DigestOf>': Vec<DigestOf>;
EventId: EventId;
'Option<EventId>': Option<EventId>;
'Vec<EventId>': Vec<EventId>;
EventIndex: EventIndex;
'Compact<EventIndex>': Compact<EventIndex>;
'Option<EventIndex>': Option<EventIndex>;
'Vec<EventIndex>': Vec<EventIndex>;
Key: Key;
'Option<Key>': Option<Key>;
'Vec<Key>': Vec<Key>;
Phase: Phase;
'Option<Phase>': Option<Phase>;
'Vec<Phase>': Vec<Phase>;
EventRecord0to76: EventRecord0to76;
'Option<EventRecord0to76>': Option<EventRecord0to76>;
'Vec<EventRecord0to76>': Vec<EventRecord0to76>;
EventRecord: EventRecord;
'Option<EventRecord>': Option<EventRecord>;
'Vec<EventRecord>': Vec<EventRecord>;
}
}
@@ -1,6 +1,6 @@
// Auto-generated via `yarn build:interfaces`, do not edit
import { Option, Struct, Vec } from '../../codec';
import { Struct } from '../../codec';
import { AccountId } from '../../primitive';
import { Balance } from '../runtime';
@@ -15,11 +15,3 @@ export interface TreasuryProposal extends Struct {
/** Balance */
readonly bond: Balance;
}
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
TreasuryProposal: TreasuryProposal;
'Option<TreasuryProposal>': Option<TreasuryProposal>;
'Vec<TreasuryProposal>': Vec<TreasuryProposal>;
}
}
+23 -17
View File
@@ -267,17 +267,6 @@ function getDerivedTypes (type: string, primitiveName: string, imports: TypeImpo
.join('\n');
}
// Do module augmentation on srml types to populate InterfaceRegistry
function interfaceRegistry (types: Record<string, any>, imports: TypeImports): string {
return `
declare module '@polkadot/types/interfaceRegistry' {
export interface InterfaceRegistry {
${Object.keys(types).map((type): string => getDerivedTypes(type, types[type], imports, 4)).join('\n')}
}
}`;
}
function generateTsDef (defName: string, { types }: { types: Record<string, any> }): void {
// handlers are defined externally to use - this means that when we do a
// `generators[typedef.info](...)` TS will show any unhandled types. Rather
@@ -312,7 +301,6 @@ function generateTsDef (defName: string, { types }: { types: Record<string, any>
});
const sortedDefs = interfaces.sort((a, b): number => a[0].localeCompare(b[0])).map(([, definition]): string => definition).join('\n\n');
const interfaceReg = interfaceRegistry(types, { codecTypes, localTypes, ownTypes, primitiveTypes });
const header = createImportCode(HEADER, [
{
file: '../../types',
@@ -332,7 +320,7 @@ function generateTsDef (defName: string, { types }: { types: Record<string, any>
}))
]);
fs.writeFileSync(`packages/types/src/interfaces/${defName}/types.ts`, header.concat(sortedDefs).concat(interfaceReg).concat(FOOTER), { flag: 'w' });
fs.writeFileSync(`packages/types/src/interfaces/${defName}/types.ts`, header.concat(sortedDefs).concat(FOOTER), { flag: 'w' });
fs.writeFileSync(`packages/types/src/interfaces/${defName}/index.ts`, HEADER.concat(`export * from './types';`).concat(FOOTER), { flag: 'w' });
}
@@ -349,14 +337,18 @@ fs.writeFileSync(`packages/types/src/interfaces/index.ts`, HEADER.concat(`export
function generateInterfaceRegistry (): void {
const codecTypes: TypeExist = {};
const localTypes: LocalExist = {};
const localTypes: LocalExist = Object.keys(definitions).reduce((localTypes: Record<string, TypeExist>, moduleName): Record<string, TypeExist> => {
localTypes[moduleName] = {};
return localTypes;
}, {});
const ownTypes: string[] = [];
const primitiveTypes: TypeExist = {};
const substrateTypes: TypeExist = {};
const imports = { codecTypes, localTypes, ownTypes, primitiveTypes, substrateTypes };
const body = Object.keys(primitiveClasses).reduce((accumulator, primitiveName): string => {
const primitives = Object.keys(primitiveClasses).reduce((accumulator, primitiveName): string => {
setImports(imports, [primitiveName]);
return [
@@ -365,6 +357,16 @@ function generateInterfaceRegistry (): void {
].join('\n');
}, '');
// eslint-disable-next-line @typescript-eslint/no-unused-vars
const srml = Object.entries(definitions).reduce((accumulator, [_defName, { types }]): string => {
setImports(imports, Object.keys(types));
return [
accumulator,
...Object.keys(types).map((type): string => getDerivedTypes(type, (types as any)[type], imports, 2))
].join('\n');
}, '');
const header = createImportCode(HEADER, [
{
file: './codec',
@@ -373,7 +375,11 @@ function generateInterfaceRegistry (): void {
{
file: './primitive',
types: Object.keys(primitiveTypes)
}
},
...Object.keys(localTypes).map((moduleName): { file: string; types: string[] } => ({
file: `./interfaces/${moduleName}`,
types: Object.keys(localTypes[moduleName])
}))
]);
const interfaceStart = 'export interface InterfaceRegistry {';
@@ -381,7 +387,7 @@ function generateInterfaceRegistry (): void {
fs.writeFileSync(
`packages/types/src/interfaceRegistry.ts`,
header.concat(interfaceStart).concat(body).concat(interfaceEnd).concat(FOOTER)
header.concat(interfaceStart).concat(primitives).concat(srml).concat(interfaceEnd).concat(FOOTER)
, { flag: 'w' }
);
}