git.delta.rocks / unique-network / refs/commits / 803eec048f65

difftreelog

source

pallets/unique/src/weights.rs9.5 KiBsourcehistory
1// Template adopted from https://github.com/paritytech/substrate/blob/master/.maintain/frame-weight-template.hbs23//! Autogenerated weights for pallet_unique4//!5//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev6//! DATE: 2023-01-29, STEPS: `50`, REPEAT: 80, LOW RANGE: `[]`, HIGH RANGE: `[]`7//! EXECUTION: None, WASM-EXECUTION: Compiled, CHAIN: None, DB CACHE: 102489// Executed Command:10// target/release/unique-collator11// benchmark12// pallet13// --pallet14// pallet-unique15// --wasm-execution16// compiled17// --extrinsic18// *19// --template20// .maintain/frame-weight-template.hbs21// --steps=5022// --repeat=8023// --heap-pages=409624// --output=./pallets/unique/src/weights.rs2526#![cfg_attr(rustfmt, rustfmt_skip)]27#![allow(unused_parens)]28#![allow(unused_imports)]29#![allow(missing_docs)]30#![allow(clippy::unnecessary_cast)]3132use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};33use sp_std::marker::PhantomData;3435/// Weight functions needed for pallet_unique.36pub trait WeightInfo {37	fn create_collection() -> Weight;38	fn destroy_collection() -> Weight;39	fn add_to_allow_list() -> Weight;40	fn remove_from_allow_list() -> Weight;41	fn change_collection_owner() -> Weight;42	fn add_collection_admin() -> Weight;43	fn remove_collection_admin() -> Weight;44	fn set_collection_sponsor() -> Weight;45	fn confirm_sponsorship() -> Weight;46	fn remove_collection_sponsor() -> Weight;47	fn set_transfers_enabled_flag() -> Weight;48	fn set_collection_limits() -> Weight;49	fn force_repair_collection() -> Weight;50}5152/// Weights for pallet_unique using the Substrate node and recommended hardware.53pub struct SubstrateWeight<T>(PhantomData<T>);54impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {55	// Storage: Common CreatedCollectionCount (r:1 w:1)56	// Storage: Common DestroyedCollectionCount (r:1 w:0)57	// Storage: System Account (r:2 w:2)58	// Storage: Common CollectionPropertyPermissions (r:0 w:1)59	// Storage: Common CollectionProperties (r:0 w:1)60	// Storage: Common CollectionById (r:0 w:1)61	fn create_collection() -> Weight {62		Weight::from_ref_time(43_527_000 as u64)63			.saturating_add(T::DbWeight::get().reads(4 as u64))64			.saturating_add(T::DbWeight::get().writes(6 as u64))65	}66	// Storage: Common CollectionById (r:1 w:1)67	// Storage: Nonfungible TokenData (r:1 w:0)68	// Storage: Common DestroyedCollectionCount (r:1 w:1)69	// Storage: Nonfungible TokensMinted (r:0 w:1)70	// Storage: Nonfungible TokensBurnt (r:0 w:1)71	// Storage: Common AdminAmount (r:0 w:1)72	// Storage: Common CollectionProperties (r:0 w:1)73	fn destroy_collection() -> Weight {74		Weight::from_ref_time(59_528_000 as u64)75			.saturating_add(T::DbWeight::get().reads(3 as u64))76			.saturating_add(T::DbWeight::get().writes(6 as u64))77	}78	// Storage: Common CollectionById (r:1 w:0)79	// Storage: Common Allowlist (r:0 w:1)80	fn add_to_allow_list() -> Weight {81		Weight::from_ref_time(27_970_000 as u64)82			.saturating_add(T::DbWeight::get().reads(1 as u64))83			.saturating_add(T::DbWeight::get().writes(1 as u64))84	}85	// Storage: Common CollectionById (r:1 w:0)86	// Storage: Common Allowlist (r:0 w:1)87	fn remove_from_allow_list() -> Weight {88		Weight::from_ref_time(27_736_000 as u64)89			.saturating_add(T::DbWeight::get().reads(1 as u64))90			.saturating_add(T::DbWeight::get().writes(1 as u64))91	}92	// Storage: Common CollectionById (r:1 w:1)93	fn change_collection_owner() -> Weight {94		Weight::from_ref_time(26_991_000 as u64)95			.saturating_add(T::DbWeight::get().reads(1 as u64))96			.saturating_add(T::DbWeight::get().writes(1 as u64))97	}98	// Storage: Common CollectionById (r:1 w:0)99	// Storage: Common IsAdmin (r:1 w:1)100	// Storage: Common AdminAmount (r:1 w:1)101	fn add_collection_admin() -> Weight {102		Weight::from_ref_time(30_851_000 as u64)103			.saturating_add(T::DbWeight::get().reads(3 as u64))104			.saturating_add(T::DbWeight::get().writes(2 as u64))105	}106	// Storage: Common CollectionById (r:1 w:0)107	// Storage: Common IsAdmin (r:1 w:1)108	// Storage: Common AdminAmount (r:1 w:1)109	fn remove_collection_admin() -> Weight {110		Weight::from_ref_time(34_432_000 as u64)111			.saturating_add(T::DbWeight::get().reads(3 as u64))112			.saturating_add(T::DbWeight::get().writes(2 as u64))113	}114	// Storage: Common CollectionById (r:1 w:1)115	fn set_collection_sponsor() -> Weight {116		Weight::from_ref_time(26_862_000 as u64)117			.saturating_add(T::DbWeight::get().reads(1 as u64))118			.saturating_add(T::DbWeight::get().writes(1 as u64))119	}120	// Storage: Common CollectionById (r:1 w:1)121	fn confirm_sponsorship() -> Weight {122		Weight::from_ref_time(26_711_000 as u64)123			.saturating_add(T::DbWeight::get().reads(1 as u64))124			.saturating_add(T::DbWeight::get().writes(1 as u64))125	}126	// Storage: Common CollectionById (r:1 w:1)127	fn remove_collection_sponsor() -> Weight {128		Weight::from_ref_time(38_546_000 as u64)129			.saturating_add(T::DbWeight::get().reads(1 as u64))130			.saturating_add(T::DbWeight::get().writes(1 as u64))131	}132	// Storage: Common CollectionById (r:1 w:1)133	fn set_transfers_enabled_flag() -> Weight {134		Weight::from_ref_time(13_251_000 as u64)135			.saturating_add(T::DbWeight::get().reads(1 as u64))136			.saturating_add(T::DbWeight::get().writes(1 as u64))137	}138	// Storage: Common CollectionById (r:1 w:1)139	fn set_collection_limits() -> Weight {140		Weight::from_ref_time(27_754_000 as u64)141			.saturating_add(T::DbWeight::get().reads(1 as u64))142			.saturating_add(T::DbWeight::get().writes(1 as u64))143	}144	// Storage: Common CollectionProperties (r:1 w:1)145	fn force_repair_collection() -> Weight {146		Weight::from_ref_time(10_871_000 as u64)147			.saturating_add(T::DbWeight::get().reads(1 as u64))148			.saturating_add(T::DbWeight::get().writes(1 as u64))149	}150}151152// For backwards compatibility and tests153impl WeightInfo for () {154	// Storage: Common CreatedCollectionCount (r:1 w:1)155	// Storage: Common DestroyedCollectionCount (r:1 w:0)156	// Storage: System Account (r:2 w:2)157	// Storage: Common CollectionPropertyPermissions (r:0 w:1)158	// Storage: Common CollectionProperties (r:0 w:1)159	// Storage: Common CollectionById (r:0 w:1)160	fn create_collection() -> Weight {161		Weight::from_ref_time(43_527_000 as u64)162			.saturating_add(RocksDbWeight::get().reads(4 as u64))163			.saturating_add(RocksDbWeight::get().writes(6 as u64))164	}165	// Storage: Common CollectionById (r:1 w:1)166	// Storage: Nonfungible TokenData (r:1 w:0)167	// Storage: Common DestroyedCollectionCount (r:1 w:1)168	// Storage: Nonfungible TokensMinted (r:0 w:1)169	// Storage: Nonfungible TokensBurnt (r:0 w:1)170	// Storage: Common AdminAmount (r:0 w:1)171	// Storage: Common CollectionProperties (r:0 w:1)172	fn destroy_collection() -> Weight {173		Weight::from_ref_time(59_528_000 as u64)174			.saturating_add(RocksDbWeight::get().reads(3 as u64))175			.saturating_add(RocksDbWeight::get().writes(6 as u64))176	}177	// Storage: Common CollectionById (r:1 w:0)178	// Storage: Common Allowlist (r:0 w:1)179	fn add_to_allow_list() -> Weight {180		Weight::from_ref_time(27_970_000 as u64)181			.saturating_add(RocksDbWeight::get().reads(1 as u64))182			.saturating_add(RocksDbWeight::get().writes(1 as u64))183	}184	// Storage: Common CollectionById (r:1 w:0)185	// Storage: Common Allowlist (r:0 w:1)186	fn remove_from_allow_list() -> Weight {187		Weight::from_ref_time(27_736_000 as u64)188			.saturating_add(RocksDbWeight::get().reads(1 as u64))189			.saturating_add(RocksDbWeight::get().writes(1 as u64))190	}191	// Storage: Common CollectionById (r:1 w:1)192	fn change_collection_owner() -> Weight {193		Weight::from_ref_time(26_991_000 as u64)194			.saturating_add(RocksDbWeight::get().reads(1 as u64))195			.saturating_add(RocksDbWeight::get().writes(1 as u64))196	}197	// Storage: Common CollectionById (r:1 w:0)198	// Storage: Common IsAdmin (r:1 w:1)199	// Storage: Common AdminAmount (r:1 w:1)200	fn add_collection_admin() -> Weight {201		Weight::from_ref_time(30_851_000 as u64)202			.saturating_add(RocksDbWeight::get().reads(3 as u64))203			.saturating_add(RocksDbWeight::get().writes(2 as u64))204	}205	// Storage: Common CollectionById (r:1 w:0)206	// Storage: Common IsAdmin (r:1 w:1)207	// Storage: Common AdminAmount (r:1 w:1)208	fn remove_collection_admin() -> Weight {209		Weight::from_ref_time(34_432_000 as u64)210			.saturating_add(RocksDbWeight::get().reads(3 as u64))211			.saturating_add(RocksDbWeight::get().writes(2 as u64))212	}213	// Storage: Common CollectionById (r:1 w:1)214	fn set_collection_sponsor() -> Weight {215		Weight::from_ref_time(26_862_000 as u64)216			.saturating_add(RocksDbWeight::get().reads(1 as u64))217			.saturating_add(RocksDbWeight::get().writes(1 as u64))218	}219	// Storage: Common CollectionById (r:1 w:1)220	fn confirm_sponsorship() -> Weight {221		Weight::from_ref_time(26_711_000 as u64)222			.saturating_add(RocksDbWeight::get().reads(1 as u64))223			.saturating_add(RocksDbWeight::get().writes(1 as u64))224	}225	// Storage: Common CollectionById (r:1 w:1)226	fn remove_collection_sponsor() -> Weight {227		Weight::from_ref_time(38_546_000 as u64)228			.saturating_add(RocksDbWeight::get().reads(1 as u64))229			.saturating_add(RocksDbWeight::get().writes(1 as u64))230	}231	// Storage: Common CollectionById (r:1 w:1)232	fn set_transfers_enabled_flag() -> Weight {233		Weight::from_ref_time(13_251_000 as u64)234			.saturating_add(RocksDbWeight::get().reads(1 as u64))235			.saturating_add(RocksDbWeight::get().writes(1 as u64))236	}237	// Storage: Common CollectionById (r:1 w:1)238	fn set_collection_limits() -> Weight {239		Weight::from_ref_time(27_754_000 as u64)240			.saturating_add(RocksDbWeight::get().reads(1 as u64))241			.saturating_add(RocksDbWeight::get().writes(1 as u64))242	}243	// Storage: Common CollectionProperties (r:1 w:1)244	fn force_repair_collection() -> Weight {245		Weight::from_ref_time(10_871_000 as u64)246			.saturating_add(RocksDbWeight::get().reads(1 as u64))247			.saturating_add(RocksDbWeight::get().writes(1 as u64))248	}249}