difftreelog
chore fix code review
in: master
20 files changed
Cargo.lockdiffbeforeafterboth--- a/Cargo.lock
+++ b/Cargo.lock
@@ -12473,7 +12473,7 @@
[[package]]
name = "up-common"
-version = "0.9.25"
+version = "0.9.27"
dependencies = [
"fp-rpc",
"frame-support",
pallets/common/CHANGELOG.mddiffbeforeafterboth--- a/pallets/common/CHANGELOG.md
+++ b/pallets/common/CHANGELOG.md
@@ -5,7 +5,7 @@
## [0.1.6] - 2022-08-16
### Added
-- New Ethereum API methods: changeOwner, changeOwnerSubstrate and verifyOwnerOrAdminSubstrate.
+- New Ethereum API methods: changeOwner, changeOwner(Substrate) and verifyOwnerOrAdmin(Substrate).
<!-- bureaucrate goes here -->
## [v0.1.5] 2022-08-16
pallets/common/src/erc.rsdiffbeforeafterboth--- a/pallets/common/src/erc.rs
+++ b/pallets/common/src/erc.rs
@@ -420,6 +420,7 @@
///
/// @param user account to verify
/// @return "true" if account is the owner or admin
+ #[solidity(rename_selector = "verifyOwnerOrAdmin")]
fn verify_owner_or_admin_substrate(&self, user: uint256) -> Result<bool> {
let user = convert_substrate_address_to_cross_account_id::<T>(user);
Ok(self
@@ -455,6 +456,7 @@
///
/// @dev Owner can be changed only by current owner
/// @param newOwner new owner substrate account
+ #[solidity(rename_selector = "changeOwner")]
fn change_owner_substrate(&mut self, caller: caller, new_owner: uint256) -> Result<void> {
let caller = T::CrossAccountId::from_eth(caller);
let new_owner = convert_substrate_address_to_cross_account_id::<T>(new_owner);
pallets/common/src/lib.rsdiffbeforeafterboth--- a/pallets/common/src/lib.rs
+++ b/pallets/common/src/lib.rs
@@ -204,7 +204,7 @@
/// Save collection to storage.
pub fn save(&self) -> DispatchResult {
- <CollectionById<T>>::insert(self.id, self.collection.clone());
+ <CollectionById<T>>::insert(self.id, &self.collection);
Ok(())
}
pallets/evm-contract-helpers/src/stubs/ContractHelpers.rawdiffbeforeafterbothbinary blob — no preview
pallets/fungible/src/stubs/UniqueFungible.rawdiffbeforeafterbothbinary blob — no preview
pallets/fungible/src/stubs/UniqueFungible.soldiffbeforeafterboth--- a/pallets/fungible/src/stubs/UniqueFungible.sol
+++ b/pallets/fungible/src/stubs/UniqueFungible.sol
@@ -31,7 +31,103 @@
);
}
-// Selector: 07f76b0c
+// Selector: 79cc6790
+contract ERC20UniqueExtensions is Dummy, ERC165 {
+ // Selector: burnFrom(address,uint256) 79cc6790
+ function burnFrom(address from, uint256 amount) public returns (bool) {
+ require(false, stub_error);
+ from;
+ amount;
+ dummy = 0;
+ return false;
+ }
+}
+
+// Selector: 942e8b22
+contract ERC20 is Dummy, ERC165, ERC20Events {
+ // Selector: name() 06fdde03
+ function name() public view returns (string memory) {
+ require(false, stub_error);
+ dummy;
+ return "";
+ }
+
+ // Selector: symbol() 95d89b41
+ function symbol() public view returns (string memory) {
+ require(false, stub_error);
+ dummy;
+ return "";
+ }
+
+ // Selector: totalSupply() 18160ddd
+ function totalSupply() public view returns (uint256) {
+ require(false, stub_error);
+ dummy;
+ return 0;
+ }
+
+ // Selector: decimals() 313ce567
+ function decimals() public view returns (uint8) {
+ require(false, stub_error);
+ dummy;
+ return 0;
+ }
+
+ // Selector: balanceOf(address) 70a08231
+ function balanceOf(address owner) public view returns (uint256) {
+ require(false, stub_error);
+ owner;
+ dummy;
+ return 0;
+ }
+
+ // Selector: transfer(address,uint256) a9059cbb
+ function transfer(address to, uint256 amount) public returns (bool) {
+ require(false, stub_error);
+ to;
+ amount;
+ dummy = 0;
+ return false;
+ }
+
+ // Selector: transferFrom(address,address,uint256) 23b872dd
+ function transferFrom(
+ address from,
+ address to,
+ uint256 amount
+ ) public returns (bool) {
+ require(false, stub_error);
+ from;
+ to;
+ amount;
+ dummy = 0;
+ return false;
+ }
+
+ // Selector: approve(address,uint256) 095ea7b3
+ function approve(address spender, uint256 amount) public returns (bool) {
+ require(false, stub_error);
+ spender;
+ amount;
+ dummy = 0;
+ return false;
+ }
+
+ // Selector: allowance(address,address) dd62ed3e
+ function allowance(address owner, address spender)
+ public
+ view
+ returns (uint256)
+ {
+ require(false, stub_error);
+ owner;
+ spender;
+ dummy;
+ return 0;
+ }
+}
+
+// Selector: f077f83e
contract Collection is Dummy, ERC165 {
// Set collection property.
//
@@ -275,12 +371,8 @@
// @param user account to verify
// @return "true" if account is the owner or admin
//
- // Selector: verifyOwnerOrAdminSubstrate(uint256) fe818e40
- function verifyOwnerOrAdminSubstrate(uint256 user)
- public
- view
- returns (bool)
- {
+ // Selector: verifyOwnerOrAdmin(uint256) a83328e5
+ function verifyOwnerOrAdmin(uint256 user) public view returns (bool) {
require(false, stub_error);
user;
dummy;
@@ -315,107 +407,11 @@
// @dev Owner can be changed only by current owner
// @param newOwner new owner substrate account
//
- // Selector: changeOwnerSubstrate(uint256) 337e2c60
- function changeOwnerSubstrate(uint256 newOwner) public {
+ // Selector: changeOwner(uint256) 924c19f7
+ function changeOwner(uint256 newOwner) public {
require(false, stub_error);
newOwner;
- dummy = 0;
- }
-}
-
-// Selector: 79cc6790
-contract ERC20UniqueExtensions is Dummy, ERC165 {
- // Selector: burnFrom(address,uint256) 79cc6790
- function burnFrom(address from, uint256 amount) public returns (bool) {
- require(false, stub_error);
- from;
- amount;
dummy = 0;
- return false;
- }
-}
-
-// Selector: 942e8b22
-contract ERC20 is Dummy, ERC165, ERC20Events {
- // Selector: name() 06fdde03
- function name() public view returns (string memory) {
- require(false, stub_error);
- dummy;
- return "";
- }
-
- // Selector: symbol() 95d89b41
- function symbol() public view returns (string memory) {
- require(false, stub_error);
- dummy;
- return "";
- }
-
- // Selector: totalSupply() 18160ddd
- function totalSupply() public view returns (uint256) {
- require(false, stub_error);
- dummy;
- return 0;
- }
-
- // Selector: decimals() 313ce567
- function decimals() public view returns (uint8) {
- require(false, stub_error);
- dummy;
- return 0;
- }
-
- // Selector: balanceOf(address) 70a08231
- function balanceOf(address owner) public view returns (uint256) {
- require(false, stub_error);
- owner;
- dummy;
- return 0;
- }
-
- // Selector: transfer(address,uint256) a9059cbb
- function transfer(address to, uint256 amount) public returns (bool) {
- require(false, stub_error);
- to;
- amount;
- dummy = 0;
- return false;
- }
-
- // Selector: transferFrom(address,address,uint256) 23b872dd
- function transferFrom(
- address from,
- address to,
- uint256 amount
- ) public returns (bool) {
- require(false, stub_error);
- from;
- to;
- amount;
- dummy = 0;
- return false;
- }
-
- // Selector: approve(address,uint256) 095ea7b3
- function approve(address spender, uint256 amount) public returns (bool) {
- require(false, stub_error);
- spender;
- amount;
- dummy = 0;
- return false;
- }
-
- // Selector: allowance(address,address) dd62ed3e
- function allowance(address owner, address spender)
- public
- view
- returns (uint256)
- {
- require(false, stub_error);
- owner;
- spender;
- dummy;
- return 0;
}
}
pallets/nonfungible/src/stubs/UniqueNFT.rawdiffbeforeafterbothbinary blob — no preview
pallets/nonfungible/src/stubs/UniqueNFT.soldiffbeforeafterboth--- a/pallets/nonfungible/src/stubs/UniqueNFT.sol
+++ b/pallets/nonfungible/src/stubs/UniqueNFT.sol
@@ -51,298 +51,6 @@
event MintingFinished();
}
-// Selector: 07f76b0c
-contract Collection is Dummy, ERC165 {
- // Set collection property.
- //
- // @param key Property key.
- // @param value Propery value.
- //
- // Selector: setCollectionProperty(string,bytes) 2f073f66
- function setCollectionProperty(string memory key, bytes memory value)
- public
- {
- require(false, stub_error);
- key;
- value;
- dummy = 0;
- }
-
- // Delete collection property.
- //
- // @param key Property key.
- //
- // Selector: deleteCollectionProperty(string) 7b7debce
- function deleteCollectionProperty(string memory key) public {
- require(false, stub_error);
- key;
- dummy = 0;
- }
-
- // Get collection property.
- //
- // @dev Throws error if key not found.
- //
- // @param key Property key.
- // @return bytes The property corresponding to the key.
- //
- // Selector: collectionProperty(string) cf24fd6d
- function collectionProperty(string memory key)
- public
- view
- returns (bytes memory)
- {
- require(false, stub_error);
- key;
- dummy;
- return hex"";
- }
-
- // Set the sponsor of the collection.
- //
- // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
- //
- // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
- //
- // Selector: setCollectionSponsor(address) 7623402e
- function setCollectionSponsor(address sponsor) public {
- require(false, stub_error);
- sponsor;
- dummy = 0;
- }
-
- // Collection sponsorship confirmation.
- //
- // @dev After setting the sponsor for the collection, it must be confirmed with this function.
- //
- // Selector: confirmCollectionSponsorship() 3c50e97a
- function confirmCollectionSponsorship() public {
- require(false, stub_error);
- dummy = 0;
- }
-
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "accountTokenOwnershipLimit",
- // "sponsoredDataSize",
- // "sponsoredDataRateLimit",
- // "tokenLimit",
- // "sponsorTransferTimeout",
- // "sponsorApproveTimeout"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,uint32) 6a3841db
- function setCollectionLimit(string memory limit, uint32 value) public {
- require(false, stub_error);
- limit;
- value;
- dummy = 0;
- }
-
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "ownerCanTransfer",
- // "ownerCanDestroy",
- // "transfersEnabled"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,bool) 993b7fba
- function setCollectionLimit(string memory limit, bool value) public {
- require(false, stub_error);
- limit;
- value;
- dummy = 0;
- }
-
- // Get contract address.
- //
- // Selector: contractAddress() f6b4dfb4
- function contractAddress() public view returns (address) {
- require(false, stub_error);
- dummy;
- return 0x0000000000000000000000000000000000000000;
- }
-
- // Add collection admin by substrate address.
- // @param new_admin Substrate administrator address.
- //
- // Selector: addCollectionAdminSubstrate(uint256) 5730062b
- function addCollectionAdminSubstrate(uint256 newAdmin) public {
- require(false, stub_error);
- newAdmin;
- dummy = 0;
- }
-
- // Remove collection admin by substrate address.
- // @param admin Substrate administrator address.
- //
- // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
- function removeCollectionAdminSubstrate(uint256 admin) public {
- require(false, stub_error);
- admin;
- dummy = 0;
- }
-
- // Add collection admin.
- // @param new_admin Address of the added administrator.
- //
- // Selector: addCollectionAdmin(address) 92e462c7
- function addCollectionAdmin(address newAdmin) public {
- require(false, stub_error);
- newAdmin;
- dummy = 0;
- }
-
- // Remove collection admin.
- //
- // @param new_admin Address of the removed administrator.
- //
- // Selector: removeCollectionAdmin(address) fafd7b42
- function removeCollectionAdmin(address admin) public {
- require(false, stub_error);
- admin;
- dummy = 0;
- }
-
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
- //
- // Selector: setCollectionNesting(bool) 112d4586
- function setCollectionNesting(bool enable) public {
- require(false, stub_error);
- enable;
- dummy = 0;
- }
-
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
- // @param collections Addresses of collections that will be available for nesting.
- //
- // Selector: setCollectionNesting(bool,address[]) 64872396
- function setCollectionNesting(bool enable, address[] memory collections)
- public
- {
- require(false, stub_error);
- enable;
- collections;
- dummy = 0;
- }
-
- // Set the collection access method.
- // @param mode Access mode
- // 0 for Normal
- // 1 for AllowList
- //
- // Selector: setCollectionAccess(uint8) 41835d4c
- function setCollectionAccess(uint8 mode) public {
- require(false, stub_error);
- mode;
- dummy = 0;
- }
-
- // Add the user to the allowed list.
- //
- // @param user Address of a trusted user.
- //
- // Selector: addToCollectionAllowList(address) 67844fe6
- function addToCollectionAllowList(address user) public {
- require(false, stub_error);
- user;
- dummy = 0;
- }
-
- // Remove the user from the allowed list.
- //
- // @param user Address of a removed user.
- //
- // Selector: removeFromCollectionAllowList(address) 85c51acb
- function removeFromCollectionAllowList(address user) public {
- require(false, stub_error);
- user;
- dummy = 0;
- }
-
- // Switch permission for minting.
- //
- // @param mode Enable if "true".
- //
- // Selector: setCollectionMintMode(bool) 00018e84
- function setCollectionMintMode(bool mode) public {
- require(false, stub_error);
- mode;
- dummy = 0;
- }
-
- // Check that account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdmin(address) c2282493
- function verifyOwnerOrAdmin(address user) public view returns (bool) {
- require(false, stub_error);
- user;
- dummy;
- return false;
- }
-
- // Check that substrate account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdminSubstrate(uint256) fe818e40
- function verifyOwnerOrAdminSubstrate(uint256 user)
- public
- view
- returns (bool)
- {
- require(false, stub_error);
- user;
- dummy;
- return false;
- }
-
- // Returns collection type
- //
- // @return `Fungible` or `NFT` or `ReFungible`
- //
- // Selector: uniqueCollectionType() d34b55b8
- function uniqueCollectionType() public returns (string memory) {
- require(false, stub_error);
- dummy = 0;
- return "";
- }
-
- // Changes collection owner to another account
- //
- // @dev Owner can be changed only by current owner
- // @param newOwner new owner account
- //
- // Selector: changeOwner(address) a6f9dae1
- function changeOwner(address newOwner) public {
- require(false, stub_error);
- newOwner;
- dummy = 0;
- }
-
- // Changes collection owner to another substrate account
- //
- // @dev Owner can be changed only by current owner
- // @param newOwner new owner substrate account
- //
- // Selector: changeOwnerSubstrate(uint256) 337e2c60
- function changeOwnerSubstrate(uint256 newOwner) public {
- require(false, stub_error);
- newOwner;
- dummy = 0;
- }
-}
-
// Selector: 41369377
contract TokenProperties is Dummy, ERC165 {
// @notice Set permissions for token property.
@@ -786,6 +494,294 @@
}
}
+// Selector: f077f83e
+contract Collection is Dummy, ERC165 {
+ // Set collection property.
+ //
+ // @param key Property key.
+ // @param value Propery value.
+ //
+ // Selector: setCollectionProperty(string,bytes) 2f073f66
+ function setCollectionProperty(string memory key, bytes memory value)
+ public
+ {
+ require(false, stub_error);
+ key;
+ value;
+ dummy = 0;
+ }
+
+ // Delete collection property.
+ //
+ // @param key Property key.
+ //
+ // Selector: deleteCollectionProperty(string) 7b7debce
+ function deleteCollectionProperty(string memory key) public {
+ require(false, stub_error);
+ key;
+ dummy = 0;
+ }
+
+ // Get collection property.
+ //
+ // @dev Throws error if key not found.
+ //
+ // @param key Property key.
+ // @return bytes The property corresponding to the key.
+ //
+ // Selector: collectionProperty(string) cf24fd6d
+ function collectionProperty(string memory key)
+ public
+ view
+ returns (bytes memory)
+ {
+ require(false, stub_error);
+ key;
+ dummy;
+ return hex"";
+ }
+
+ // Set the sponsor of the collection.
+ //
+ // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ //
+ // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
+ //
+ // Selector: setCollectionSponsor(address) 7623402e
+ function setCollectionSponsor(address sponsor) public {
+ require(false, stub_error);
+ sponsor;
+ dummy = 0;
+ }
+
+ // Collection sponsorship confirmation.
+ //
+ // @dev After setting the sponsor for the collection, it must be confirmed with this function.
+ //
+ // Selector: confirmCollectionSponsorship() 3c50e97a
+ function confirmCollectionSponsorship() public {
+ require(false, stub_error);
+ dummy = 0;
+ }
+
+ // Set limits for the collection.
+ // @dev Throws error if limit not found.
+ // @param limit Name of the limit. Valid names:
+ // "accountTokenOwnershipLimit",
+ // "sponsoredDataSize",
+ // "sponsoredDataRateLimit",
+ // "tokenLimit",
+ // "sponsorTransferTimeout",
+ // "sponsorApproveTimeout"
+ // @param value Value of the limit.
+ //
+ // Selector: setCollectionLimit(string,uint32) 6a3841db
+ function setCollectionLimit(string memory limit, uint32 value) public {
+ require(false, stub_error);
+ limit;
+ value;
+ dummy = 0;
+ }
+
+ // Set limits for the collection.
+ // @dev Throws error if limit not found.
+ // @param limit Name of the limit. Valid names:
+ // "ownerCanTransfer",
+ // "ownerCanDestroy",
+ // "transfersEnabled"
+ // @param value Value of the limit.
+ //
+ // Selector: setCollectionLimit(string,bool) 993b7fba
+ function setCollectionLimit(string memory limit, bool value) public {
+ require(false, stub_error);
+ limit;
+ value;
+ dummy = 0;
+ }
+
+ // Get contract address.
+ //
+ // Selector: contractAddress() f6b4dfb4
+ function contractAddress() public view returns (address) {
+ require(false, stub_error);
+ dummy;
+ return 0x0000000000000000000000000000000000000000;
+ }
+
+ // Add collection admin by substrate address.
+ // @param new_admin Substrate administrator address.
+ //
+ // Selector: addCollectionAdminSubstrate(uint256) 5730062b
+ function addCollectionAdminSubstrate(uint256 newAdmin) public {
+ require(false, stub_error);
+ newAdmin;
+ dummy = 0;
+ }
+
+ // Remove collection admin by substrate address.
+ // @param admin Substrate administrator address.
+ //
+ // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
+ function removeCollectionAdminSubstrate(uint256 admin) public {
+ require(false, stub_error);
+ admin;
+ dummy = 0;
+ }
+
+ // Add collection admin.
+ // @param new_admin Address of the added administrator.
+ //
+ // Selector: addCollectionAdmin(address) 92e462c7
+ function addCollectionAdmin(address newAdmin) public {
+ require(false, stub_error);
+ newAdmin;
+ dummy = 0;
+ }
+
+ // Remove collection admin.
+ //
+ // @param new_admin Address of the removed administrator.
+ //
+ // Selector: removeCollectionAdmin(address) fafd7b42
+ function removeCollectionAdmin(address admin) public {
+ require(false, stub_error);
+ admin;
+ dummy = 0;
+ }
+
+ // Toggle accessibility of collection nesting.
+ //
+ // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
+ //
+ // Selector: setCollectionNesting(bool) 112d4586
+ function setCollectionNesting(bool enable) public {
+ require(false, stub_error);
+ enable;
+ dummy = 0;
+ }
+
+ // Toggle accessibility of collection nesting.
+ //
+ // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
+ // @param collections Addresses of collections that will be available for nesting.
+ //
+ // Selector: setCollectionNesting(bool,address[]) 64872396
+ function setCollectionNesting(bool enable, address[] memory collections)
+ public
+ {
+ require(false, stub_error);
+ enable;
+ collections;
+ dummy = 0;
+ }
+
+ // Set the collection access method.
+ // @param mode Access mode
+ // 0 for Normal
+ // 1 for AllowList
+ //
+ // Selector: setCollectionAccess(uint8) 41835d4c
+ function setCollectionAccess(uint8 mode) public {
+ require(false, stub_error);
+ mode;
+ dummy = 0;
+ }
+
+ // Add the user to the allowed list.
+ //
+ // @param user Address of a trusted user.
+ //
+ // Selector: addToCollectionAllowList(address) 67844fe6
+ function addToCollectionAllowList(address user) public {
+ require(false, stub_error);
+ user;
+ dummy = 0;
+ }
+
+ // Remove the user from the allowed list.
+ //
+ // @param user Address of a removed user.
+ //
+ // Selector: removeFromCollectionAllowList(address) 85c51acb
+ function removeFromCollectionAllowList(address user) public {
+ require(false, stub_error);
+ user;
+ dummy = 0;
+ }
+
+ // Switch permission for minting.
+ //
+ // @param mode Enable if "true".
+ //
+ // Selector: setCollectionMintMode(bool) 00018e84
+ function setCollectionMintMode(bool mode) public {
+ require(false, stub_error);
+ mode;
+ dummy = 0;
+ }
+
+ // Check that account is the owner or admin of the collection
+ //
+ // @param user account to verify
+ // @return "true" if account is the owner or admin
+ //
+ // Selector: verifyOwnerOrAdmin(address) c2282493
+ function verifyOwnerOrAdmin(address user) public view returns (bool) {
+ require(false, stub_error);
+ user;
+ dummy;
+ return false;
+ }
+
+ // Check that substrate account is the owner or admin of the collection
+ //
+ // @param user account to verify
+ // @return "true" if account is the owner or admin
+ //
+ // Selector: verifyOwnerOrAdmin(uint256) a83328e5
+ function verifyOwnerOrAdmin(uint256 user) public view returns (bool) {
+ require(false, stub_error);
+ user;
+ dummy;
+ return false;
+ }
+
+ // Returns collection type
+ //
+ // @return `Fungible` or `NFT` or `ReFungible`
+ //
+ // Selector: uniqueCollectionType() d34b55b8
+ function uniqueCollectionType() public returns (string memory) {
+ require(false, stub_error);
+ dummy = 0;
+ return "";
+ }
+
+ // Changes collection owner to another account
+ //
+ // @dev Owner can be changed only by current owner
+ // @param newOwner new owner account
+ //
+ // Selector: changeOwner(address) a6f9dae1
+ function changeOwner(address newOwner) public {
+ require(false, stub_error);
+ newOwner;
+ dummy = 0;
+ }
+
+ // Changes collection owner to another substrate account
+ //
+ // @dev Owner can be changed only by current owner
+ // @param newOwner new owner substrate account
+ //
+ // Selector: changeOwner(uint256) 924c19f7
+ function changeOwner(uint256 newOwner) public {
+ require(false, stub_error);
+ newOwner;
+ dummy = 0;
+ }
+}
+
contract UniqueNFT is
Dummy,
ERC165,
pallets/refungible/src/stubs/UniqueRefungible.rawdiffbeforeafterbothbinary blob — no preview
pallets/refungible/src/stubs/UniqueRefungible.soldiffbeforeafterboth--- a/pallets/refungible/src/stubs/UniqueRefungible.sol
+++ b/pallets/refungible/src/stubs/UniqueRefungible.sol
@@ -51,298 +51,6 @@
event MintingFinished();
}
-// Selector: 07f76b0c
-contract Collection is Dummy, ERC165 {
- // Set collection property.
- //
- // @param key Property key.
- // @param value Propery value.
- //
- // Selector: setCollectionProperty(string,bytes) 2f073f66
- function setCollectionProperty(string memory key, bytes memory value)
- public
- {
- require(false, stub_error);
- key;
- value;
- dummy = 0;
- }
-
- // Delete collection property.
- //
- // @param key Property key.
- //
- // Selector: deleteCollectionProperty(string) 7b7debce
- function deleteCollectionProperty(string memory key) public {
- require(false, stub_error);
- key;
- dummy = 0;
- }
-
- // Get collection property.
- //
- // @dev Throws error if key not found.
- //
- // @param key Property key.
- // @return bytes The property corresponding to the key.
- //
- // Selector: collectionProperty(string) cf24fd6d
- function collectionProperty(string memory key)
- public
- view
- returns (bytes memory)
- {
- require(false, stub_error);
- key;
- dummy;
- return hex"";
- }
-
- // Set the sponsor of the collection.
- //
- // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
- //
- // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
- //
- // Selector: setCollectionSponsor(address) 7623402e
- function setCollectionSponsor(address sponsor) public {
- require(false, stub_error);
- sponsor;
- dummy = 0;
- }
-
- // Collection sponsorship confirmation.
- //
- // @dev After setting the sponsor for the collection, it must be confirmed with this function.
- //
- // Selector: confirmCollectionSponsorship() 3c50e97a
- function confirmCollectionSponsorship() public {
- require(false, stub_error);
- dummy = 0;
- }
-
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "accountTokenOwnershipLimit",
- // "sponsoredDataSize",
- // "sponsoredDataRateLimit",
- // "tokenLimit",
- // "sponsorTransferTimeout",
- // "sponsorApproveTimeout"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,uint32) 6a3841db
- function setCollectionLimit(string memory limit, uint32 value) public {
- require(false, stub_error);
- limit;
- value;
- dummy = 0;
- }
-
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "ownerCanTransfer",
- // "ownerCanDestroy",
- // "transfersEnabled"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,bool) 993b7fba
- function setCollectionLimit(string memory limit, bool value) public {
- require(false, stub_error);
- limit;
- value;
- dummy = 0;
- }
-
- // Get contract address.
- //
- // Selector: contractAddress() f6b4dfb4
- function contractAddress() public view returns (address) {
- require(false, stub_error);
- dummy;
- return 0x0000000000000000000000000000000000000000;
- }
-
- // Add collection admin by substrate address.
- // @param new_admin Substrate administrator address.
- //
- // Selector: addCollectionAdminSubstrate(uint256) 5730062b
- function addCollectionAdminSubstrate(uint256 newAdmin) public {
- require(false, stub_error);
- newAdmin;
- dummy = 0;
- }
-
- // Remove collection admin by substrate address.
- // @param admin Substrate administrator address.
- //
- // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
- function removeCollectionAdminSubstrate(uint256 admin) public {
- require(false, stub_error);
- admin;
- dummy = 0;
- }
-
- // Add collection admin.
- // @param new_admin Address of the added administrator.
- //
- // Selector: addCollectionAdmin(address) 92e462c7
- function addCollectionAdmin(address newAdmin) public {
- require(false, stub_error);
- newAdmin;
- dummy = 0;
- }
-
- // Remove collection admin.
- //
- // @param new_admin Address of the removed administrator.
- //
- // Selector: removeCollectionAdmin(address) fafd7b42
- function removeCollectionAdmin(address admin) public {
- require(false, stub_error);
- admin;
- dummy = 0;
- }
-
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
- //
- // Selector: setCollectionNesting(bool) 112d4586
- function setCollectionNesting(bool enable) public {
- require(false, stub_error);
- enable;
- dummy = 0;
- }
-
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
- // @param collections Addresses of collections that will be available for nesting.
- //
- // Selector: setCollectionNesting(bool,address[]) 64872396
- function setCollectionNesting(bool enable, address[] memory collections)
- public
- {
- require(false, stub_error);
- enable;
- collections;
- dummy = 0;
- }
-
- // Set the collection access method.
- // @param mode Access mode
- // 0 for Normal
- // 1 for AllowList
- //
- // Selector: setCollectionAccess(uint8) 41835d4c
- function setCollectionAccess(uint8 mode) public {
- require(false, stub_error);
- mode;
- dummy = 0;
- }
-
- // Add the user to the allowed list.
- //
- // @param user Address of a trusted user.
- //
- // Selector: addToCollectionAllowList(address) 67844fe6
- function addToCollectionAllowList(address user) public {
- require(false, stub_error);
- user;
- dummy = 0;
- }
-
- // Remove the user from the allowed list.
- //
- // @param user Address of a removed user.
- //
- // Selector: removeFromCollectionAllowList(address) 85c51acb
- function removeFromCollectionAllowList(address user) public {
- require(false, stub_error);
- user;
- dummy = 0;
- }
-
- // Switch permission for minting.
- //
- // @param mode Enable if "true".
- //
- // Selector: setCollectionMintMode(bool) 00018e84
- function setCollectionMintMode(bool mode) public {
- require(false, stub_error);
- mode;
- dummy = 0;
- }
-
- // Check that account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdmin(address) c2282493
- function verifyOwnerOrAdmin(address user) public view returns (bool) {
- require(false, stub_error);
- user;
- dummy;
- return false;
- }
-
- // Check that substrate account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdminSubstrate(uint256) fe818e40
- function verifyOwnerOrAdminSubstrate(uint256 user)
- public
- view
- returns (bool)
- {
- require(false, stub_error);
- user;
- dummy;
- return false;
- }
-
- // Returns collection type
- //
- // @return `Fungible` or `NFT` or `ReFungible`
- //
- // Selector: uniqueCollectionType() d34b55b8
- function uniqueCollectionType() public returns (string memory) {
- require(false, stub_error);
- dummy = 0;
- return "";
- }
-
- // Changes collection owner to another account
- //
- // @dev Owner can be changed only by current owner
- // @param newOwner new owner account
- //
- // Selector: changeOwner(address) a6f9dae1
- function changeOwner(address newOwner) public {
- require(false, stub_error);
- newOwner;
- dummy = 0;
- }
-
- // Changes collection owner to another substrate account
- //
- // @dev Owner can be changed only by current owner
- // @param newOwner new owner substrate account
- //
- // Selector: changeOwnerSubstrate(uint256) 337e2c60
- function changeOwnerSubstrate(uint256 newOwner) public {
- require(false, stub_error);
- newOwner;
- dummy = 0;
- }
-}
-
// Selector: 41369377
contract TokenProperties is Dummy, ERC165 {
// @notice Set permissions for token property.
@@ -798,6 +506,294 @@
}
}
+// Selector: f077f83e
+contract Collection is Dummy, ERC165 {
+ // Set collection property.
+ //
+ // @param key Property key.
+ // @param value Propery value.
+ //
+ // Selector: setCollectionProperty(string,bytes) 2f073f66
+ function setCollectionProperty(string memory key, bytes memory value)
+ public
+ {
+ require(false, stub_error);
+ key;
+ value;
+ dummy = 0;
+ }
+
+ // Delete collection property.
+ //
+ // @param key Property key.
+ //
+ // Selector: deleteCollectionProperty(string) 7b7debce
+ function deleteCollectionProperty(string memory key) public {
+ require(false, stub_error);
+ key;
+ dummy = 0;
+ }
+
+ // Get collection property.
+ //
+ // @dev Throws error if key not found.
+ //
+ // @param key Property key.
+ // @return bytes The property corresponding to the key.
+ //
+ // Selector: collectionProperty(string) cf24fd6d
+ function collectionProperty(string memory key)
+ public
+ view
+ returns (bytes memory)
+ {
+ require(false, stub_error);
+ key;
+ dummy;
+ return hex"";
+ }
+
+ // Set the sponsor of the collection.
+ //
+ // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ //
+ // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
+ //
+ // Selector: setCollectionSponsor(address) 7623402e
+ function setCollectionSponsor(address sponsor) public {
+ require(false, stub_error);
+ sponsor;
+ dummy = 0;
+ }
+
+ // Collection sponsorship confirmation.
+ //
+ // @dev After setting the sponsor for the collection, it must be confirmed with this function.
+ //
+ // Selector: confirmCollectionSponsorship() 3c50e97a
+ function confirmCollectionSponsorship() public {
+ require(false, stub_error);
+ dummy = 0;
+ }
+
+ // Set limits for the collection.
+ // @dev Throws error if limit not found.
+ // @param limit Name of the limit. Valid names:
+ // "accountTokenOwnershipLimit",
+ // "sponsoredDataSize",
+ // "sponsoredDataRateLimit",
+ // "tokenLimit",
+ // "sponsorTransferTimeout",
+ // "sponsorApproveTimeout"
+ // @param value Value of the limit.
+ //
+ // Selector: setCollectionLimit(string,uint32) 6a3841db
+ function setCollectionLimit(string memory limit, uint32 value) public {
+ require(false, stub_error);
+ limit;
+ value;
+ dummy = 0;
+ }
+
+ // Set limits for the collection.
+ // @dev Throws error if limit not found.
+ // @param limit Name of the limit. Valid names:
+ // "ownerCanTransfer",
+ // "ownerCanDestroy",
+ // "transfersEnabled"
+ // @param value Value of the limit.
+ //
+ // Selector: setCollectionLimit(string,bool) 993b7fba
+ function setCollectionLimit(string memory limit, bool value) public {
+ require(false, stub_error);
+ limit;
+ value;
+ dummy = 0;
+ }
+
+ // Get contract address.
+ //
+ // Selector: contractAddress() f6b4dfb4
+ function contractAddress() public view returns (address) {
+ require(false, stub_error);
+ dummy;
+ return 0x0000000000000000000000000000000000000000;
+ }
+
+ // Add collection admin by substrate address.
+ // @param new_admin Substrate administrator address.
+ //
+ // Selector: addCollectionAdminSubstrate(uint256) 5730062b
+ function addCollectionAdminSubstrate(uint256 newAdmin) public {
+ require(false, stub_error);
+ newAdmin;
+ dummy = 0;
+ }
+
+ // Remove collection admin by substrate address.
+ // @param admin Substrate administrator address.
+ //
+ // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
+ function removeCollectionAdminSubstrate(uint256 admin) public {
+ require(false, stub_error);
+ admin;
+ dummy = 0;
+ }
+
+ // Add collection admin.
+ // @param new_admin Address of the added administrator.
+ //
+ // Selector: addCollectionAdmin(address) 92e462c7
+ function addCollectionAdmin(address newAdmin) public {
+ require(false, stub_error);
+ newAdmin;
+ dummy = 0;
+ }
+
+ // Remove collection admin.
+ //
+ // @param new_admin Address of the removed administrator.
+ //
+ // Selector: removeCollectionAdmin(address) fafd7b42
+ function removeCollectionAdmin(address admin) public {
+ require(false, stub_error);
+ admin;
+ dummy = 0;
+ }
+
+ // Toggle accessibility of collection nesting.
+ //
+ // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
+ //
+ // Selector: setCollectionNesting(bool) 112d4586
+ function setCollectionNesting(bool enable) public {
+ require(false, stub_error);
+ enable;
+ dummy = 0;
+ }
+
+ // Toggle accessibility of collection nesting.
+ //
+ // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
+ // @param collections Addresses of collections that will be available for nesting.
+ //
+ // Selector: setCollectionNesting(bool,address[]) 64872396
+ function setCollectionNesting(bool enable, address[] memory collections)
+ public
+ {
+ require(false, stub_error);
+ enable;
+ collections;
+ dummy = 0;
+ }
+
+ // Set the collection access method.
+ // @param mode Access mode
+ // 0 for Normal
+ // 1 for AllowList
+ //
+ // Selector: setCollectionAccess(uint8) 41835d4c
+ function setCollectionAccess(uint8 mode) public {
+ require(false, stub_error);
+ mode;
+ dummy = 0;
+ }
+
+ // Add the user to the allowed list.
+ //
+ // @param user Address of a trusted user.
+ //
+ // Selector: addToCollectionAllowList(address) 67844fe6
+ function addToCollectionAllowList(address user) public {
+ require(false, stub_error);
+ user;
+ dummy = 0;
+ }
+
+ // Remove the user from the allowed list.
+ //
+ // @param user Address of a removed user.
+ //
+ // Selector: removeFromCollectionAllowList(address) 85c51acb
+ function removeFromCollectionAllowList(address user) public {
+ require(false, stub_error);
+ user;
+ dummy = 0;
+ }
+
+ // Switch permission for minting.
+ //
+ // @param mode Enable if "true".
+ //
+ // Selector: setCollectionMintMode(bool) 00018e84
+ function setCollectionMintMode(bool mode) public {
+ require(false, stub_error);
+ mode;
+ dummy = 0;
+ }
+
+ // Check that account is the owner or admin of the collection
+ //
+ // @param user account to verify
+ // @return "true" if account is the owner or admin
+ //
+ // Selector: verifyOwnerOrAdmin(address) c2282493
+ function verifyOwnerOrAdmin(address user) public view returns (bool) {
+ require(false, stub_error);
+ user;
+ dummy;
+ return false;
+ }
+
+ // Check that substrate account is the owner or admin of the collection
+ //
+ // @param user account to verify
+ // @return "true" if account is the owner or admin
+ //
+ // Selector: verifyOwnerOrAdmin(uint256) a83328e5
+ function verifyOwnerOrAdmin(uint256 user) public view returns (bool) {
+ require(false, stub_error);
+ user;
+ dummy;
+ return false;
+ }
+
+ // Returns collection type
+ //
+ // @return `Fungible` or `NFT` or `ReFungible`
+ //
+ // Selector: uniqueCollectionType() d34b55b8
+ function uniqueCollectionType() public returns (string memory) {
+ require(false, stub_error);
+ dummy = 0;
+ return "";
+ }
+
+ // Changes collection owner to another account
+ //
+ // @dev Owner can be changed only by current owner
+ // @param newOwner new owner account
+ //
+ // Selector: changeOwner(address) a6f9dae1
+ function changeOwner(address newOwner) public {
+ require(false, stub_error);
+ newOwner;
+ dummy = 0;
+ }
+
+ // Changes collection owner to another substrate account
+ //
+ // @dev Owner can be changed only by current owner
+ // @param newOwner new owner substrate account
+ //
+ // Selector: changeOwner(uint256) 924c19f7
+ function changeOwner(uint256 newOwner) public {
+ require(false, stub_error);
+ newOwner;
+ dummy = 0;
+ }
+}
+
contract UniqueRefungible is
Dummy,
ERC165,
pallets/refungible/src/stubs/UniqueRefungibleToken.rawdiffbeforeafterbothbinary blob — no preview
pallets/unique/src/eth/stubs/CollectionHelpers.rawdiffbeforeafterbothbinary blob — no preview
tests/src/eth/api/UniqueFungible.soldiffbeforeafterboth--- a/tests/src/eth/api/UniqueFungible.sol
+++ b/tests/src/eth/api/UniqueFungible.sol
@@ -22,7 +22,50 @@
);
}
-// Selector: 07f76b0c
+// Selector: 79cc6790
+interface ERC20UniqueExtensions is Dummy, ERC165 {
+ // Selector: burnFrom(address,uint256) 79cc6790
+ function burnFrom(address from, uint256 amount) external returns (bool);
+}
+
+// Selector: 942e8b22
+interface ERC20 is Dummy, ERC165, ERC20Events {
+ // Selector: name() 06fdde03
+ function name() external view returns (string memory);
+
+ // Selector: symbol() 95d89b41
+ function symbol() external view returns (string memory);
+
+ // Selector: totalSupply() 18160ddd
+ function totalSupply() external view returns (uint256);
+
+ // Selector: decimals() 313ce567
+ function decimals() external view returns (uint8);
+
+ // Selector: balanceOf(address) 70a08231
+ function balanceOf(address owner) external view returns (uint256);
+
+ // Selector: transfer(address,uint256) a9059cbb
+ function transfer(address to, uint256 amount) external returns (bool);
+
+ // Selector: transferFrom(address,address,uint256) 23b872dd
+ function transferFrom(
+ address from,
+ address to,
+ uint256 amount
+ ) external returns (bool);
+
+ // Selector: approve(address,uint256) 095ea7b3
+ function approve(address spender, uint256 amount) external returns (bool);
+
+ // Selector: allowance(address,address) dd62ed3e
+ function allowance(address owner, address spender)
+ external
+ view
+ returns (uint256);
+}
+
+// Selector: f077f83e
interface Collection is Dummy, ERC165 {
// Set collection property.
//
@@ -182,11 +225,8 @@
// @param user account to verify
// @return "true" if account is the owner or admin
//
- // Selector: verifyOwnerOrAdminSubstrate(uint256) fe818e40
- function verifyOwnerOrAdminSubstrate(uint256 user)
- external
- view
- returns (bool);
+ // Selector: verifyOwnerOrAdmin(uint256) a83328e5
+ function verifyOwnerOrAdmin(uint256 user) external view returns (bool);
// Returns collection type
//
@@ -208,51 +248,8 @@
// @dev Owner can be changed only by current owner
// @param newOwner new owner substrate account
//
- // Selector: changeOwnerSubstrate(uint256) 337e2c60
- function changeOwnerSubstrate(uint256 newOwner) external;
-}
-
-// Selector: 79cc6790
-interface ERC20UniqueExtensions is Dummy, ERC165 {
- // Selector: burnFrom(address,uint256) 79cc6790
- function burnFrom(address from, uint256 amount) external returns (bool);
-}
-
-// Selector: 942e8b22
-interface ERC20 is Dummy, ERC165, ERC20Events {
- // Selector: name() 06fdde03
- function name() external view returns (string memory);
-
- // Selector: symbol() 95d89b41
- function symbol() external view returns (string memory);
-
- // Selector: totalSupply() 18160ddd
- function totalSupply() external view returns (uint256);
-
- // Selector: decimals() 313ce567
- function decimals() external view returns (uint8);
-
- // Selector: balanceOf(address) 70a08231
- function balanceOf(address owner) external view returns (uint256);
-
- // Selector: transfer(address,uint256) a9059cbb
- function transfer(address to, uint256 amount) external returns (bool);
-
- // Selector: transferFrom(address,address,uint256) 23b872dd
- function transferFrom(
- address from,
- address to,
- uint256 amount
- ) external returns (bool);
-
- // Selector: approve(address,uint256) 095ea7b3
- function approve(address spender, uint256 amount) external returns (bool);
-
- // Selector: allowance(address,address) dd62ed3e
- function allowance(address owner, address spender)
- external
- view
- returns (uint256);
+ // Selector: changeOwner(uint256) 924c19f7
+ function changeOwner(uint256 newOwner) external;
}
interface UniqueFungible is
tests/src/eth/api/UniqueNFT.soldiffbeforeafterboth--- a/tests/src/eth/api/UniqueNFT.sol
+++ b/tests/src/eth/api/UniqueNFT.sol
@@ -42,196 +42,6 @@
event MintingFinished();
}
-// Selector: 07f76b0c
-interface Collection is Dummy, ERC165 {
- // Set collection property.
- //
- // @param key Property key.
- // @param value Propery value.
- //
- // Selector: setCollectionProperty(string,bytes) 2f073f66
- function setCollectionProperty(string memory key, bytes memory value)
- external;
-
- // Delete collection property.
- //
- // @param key Property key.
- //
- // Selector: deleteCollectionProperty(string) 7b7debce
- function deleteCollectionProperty(string memory key) external;
-
- // Get collection property.
- //
- // @dev Throws error if key not found.
- //
- // @param key Property key.
- // @return bytes The property corresponding to the key.
- //
- // Selector: collectionProperty(string) cf24fd6d
- function collectionProperty(string memory key)
- external
- view
- returns (bytes memory);
-
- // Set the sponsor of the collection.
- //
- // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
- //
- // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
- //
- // Selector: setCollectionSponsor(address) 7623402e
- function setCollectionSponsor(address sponsor) external;
-
- // Collection sponsorship confirmation.
- //
- // @dev After setting the sponsor for the collection, it must be confirmed with this function.
- //
- // Selector: confirmCollectionSponsorship() 3c50e97a
- function confirmCollectionSponsorship() external;
-
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "accountTokenOwnershipLimit",
- // "sponsoredDataSize",
- // "sponsoredDataRateLimit",
- // "tokenLimit",
- // "sponsorTransferTimeout",
- // "sponsorApproveTimeout"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,uint32) 6a3841db
- function setCollectionLimit(string memory limit, uint32 value) external;
-
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "ownerCanTransfer",
- // "ownerCanDestroy",
- // "transfersEnabled"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,bool) 993b7fba
- function setCollectionLimit(string memory limit, bool value) external;
-
- // Get contract address.
- //
- // Selector: contractAddress() f6b4dfb4
- function contractAddress() external view returns (address);
-
- // Add collection admin by substrate address.
- // @param new_admin Substrate administrator address.
- //
- // Selector: addCollectionAdminSubstrate(uint256) 5730062b
- function addCollectionAdminSubstrate(uint256 newAdmin) external;
-
- // Remove collection admin by substrate address.
- // @param admin Substrate administrator address.
- //
- // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
- function removeCollectionAdminSubstrate(uint256 admin) external;
-
- // Add collection admin.
- // @param new_admin Address of the added administrator.
- //
- // Selector: addCollectionAdmin(address) 92e462c7
- function addCollectionAdmin(address newAdmin) external;
-
- // Remove collection admin.
- //
- // @param new_admin Address of the removed administrator.
- //
- // Selector: removeCollectionAdmin(address) fafd7b42
- function removeCollectionAdmin(address admin) external;
-
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
- //
- // Selector: setCollectionNesting(bool) 112d4586
- function setCollectionNesting(bool enable) external;
-
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
- // @param collections Addresses of collections that will be available for nesting.
- //
- // Selector: setCollectionNesting(bool,address[]) 64872396
- function setCollectionNesting(bool enable, address[] memory collections)
- external;
-
- // Set the collection access method.
- // @param mode Access mode
- // 0 for Normal
- // 1 for AllowList
- //
- // Selector: setCollectionAccess(uint8) 41835d4c
- function setCollectionAccess(uint8 mode) external;
-
- // Add the user to the allowed list.
- //
- // @param user Address of a trusted user.
- //
- // Selector: addToCollectionAllowList(address) 67844fe6
- function addToCollectionAllowList(address user) external;
-
- // Remove the user from the allowed list.
- //
- // @param user Address of a removed user.
- //
- // Selector: removeFromCollectionAllowList(address) 85c51acb
- function removeFromCollectionAllowList(address user) external;
-
- // Switch permission for minting.
- //
- // @param mode Enable if "true".
- //
- // Selector: setCollectionMintMode(bool) 00018e84
- function setCollectionMintMode(bool mode) external;
-
- // Check that account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdmin(address) c2282493
- function verifyOwnerOrAdmin(address user) external view returns (bool);
-
- // Check that substrate account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdminSubstrate(uint256) fe818e40
- function verifyOwnerOrAdminSubstrate(uint256 user)
- external
- view
- returns (bool);
-
- // Returns collection type
- //
- // @return `Fungible` or `NFT` or `ReFungible`
- //
- // Selector: uniqueCollectionType() d34b55b8
- function uniqueCollectionType() external returns (string memory);
-
- // Changes collection owner to another account
- //
- // @dev Owner can be changed only by current owner
- // @param newOwner new owner account
- //
- // Selector: changeOwner(address) a6f9dae1
- function changeOwner(address newOwner) external;
-
- // Changes collection owner to another substrate account
- //
- // @dev Owner can be changed only by current owner
- // @param newOwner new owner substrate account
- //
- // Selector: changeOwnerSubstrate(uint256) 337e2c60
- function changeOwnerSubstrate(uint256 newOwner) external;
-}
-
// Selector: 41369377
interface TokenProperties is Dummy, ERC165 {
// @notice Set permissions for token property.
@@ -517,6 +327,193 @@
returns (bool);
}
+// Selector: f077f83e
+interface Collection is Dummy, ERC165 {
+ // Set collection property.
+ //
+ // @param key Property key.
+ // @param value Propery value.
+ //
+ // Selector: setCollectionProperty(string,bytes) 2f073f66
+ function setCollectionProperty(string memory key, bytes memory value)
+ external;
+
+ // Delete collection property.
+ //
+ // @param key Property key.
+ //
+ // Selector: deleteCollectionProperty(string) 7b7debce
+ function deleteCollectionProperty(string memory key) external;
+
+ // Get collection property.
+ //
+ // @dev Throws error if key not found.
+ //
+ // @param key Property key.
+ // @return bytes The property corresponding to the key.
+ //
+ // Selector: collectionProperty(string) cf24fd6d
+ function collectionProperty(string memory key)
+ external
+ view
+ returns (bytes memory);
+
+ // Set the sponsor of the collection.
+ //
+ // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ //
+ // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
+ //
+ // Selector: setCollectionSponsor(address) 7623402e
+ function setCollectionSponsor(address sponsor) external;
+
+ // Collection sponsorship confirmation.
+ //
+ // @dev After setting the sponsor for the collection, it must be confirmed with this function.
+ //
+ // Selector: confirmCollectionSponsorship() 3c50e97a
+ function confirmCollectionSponsorship() external;
+
+ // Set limits for the collection.
+ // @dev Throws error if limit not found.
+ // @param limit Name of the limit. Valid names:
+ // "accountTokenOwnershipLimit",
+ // "sponsoredDataSize",
+ // "sponsoredDataRateLimit",
+ // "tokenLimit",
+ // "sponsorTransferTimeout",
+ // "sponsorApproveTimeout"
+ // @param value Value of the limit.
+ //
+ // Selector: setCollectionLimit(string,uint32) 6a3841db
+ function setCollectionLimit(string memory limit, uint32 value) external;
+
+ // Set limits for the collection.
+ // @dev Throws error if limit not found.
+ // @param limit Name of the limit. Valid names:
+ // "ownerCanTransfer",
+ // "ownerCanDestroy",
+ // "transfersEnabled"
+ // @param value Value of the limit.
+ //
+ // Selector: setCollectionLimit(string,bool) 993b7fba
+ function setCollectionLimit(string memory limit, bool value) external;
+
+ // Get contract address.
+ //
+ // Selector: contractAddress() f6b4dfb4
+ function contractAddress() external view returns (address);
+
+ // Add collection admin by substrate address.
+ // @param new_admin Substrate administrator address.
+ //
+ // Selector: addCollectionAdminSubstrate(uint256) 5730062b
+ function addCollectionAdminSubstrate(uint256 newAdmin) external;
+
+ // Remove collection admin by substrate address.
+ // @param admin Substrate administrator address.
+ //
+ // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
+ function removeCollectionAdminSubstrate(uint256 admin) external;
+
+ // Add collection admin.
+ // @param new_admin Address of the added administrator.
+ //
+ // Selector: addCollectionAdmin(address) 92e462c7
+ function addCollectionAdmin(address newAdmin) external;
+
+ // Remove collection admin.
+ //
+ // @param new_admin Address of the removed administrator.
+ //
+ // Selector: removeCollectionAdmin(address) fafd7b42
+ function removeCollectionAdmin(address admin) external;
+
+ // Toggle accessibility of collection nesting.
+ //
+ // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
+ //
+ // Selector: setCollectionNesting(bool) 112d4586
+ function setCollectionNesting(bool enable) external;
+
+ // Toggle accessibility of collection nesting.
+ //
+ // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
+ // @param collections Addresses of collections that will be available for nesting.
+ //
+ // Selector: setCollectionNesting(bool,address[]) 64872396
+ function setCollectionNesting(bool enable, address[] memory collections)
+ external;
+
+ // Set the collection access method.
+ // @param mode Access mode
+ // 0 for Normal
+ // 1 for AllowList
+ //
+ // Selector: setCollectionAccess(uint8) 41835d4c
+ function setCollectionAccess(uint8 mode) external;
+
+ // Add the user to the allowed list.
+ //
+ // @param user Address of a trusted user.
+ //
+ // Selector: addToCollectionAllowList(address) 67844fe6
+ function addToCollectionAllowList(address user) external;
+
+ // Remove the user from the allowed list.
+ //
+ // @param user Address of a removed user.
+ //
+ // Selector: removeFromCollectionAllowList(address) 85c51acb
+ function removeFromCollectionAllowList(address user) external;
+
+ // Switch permission for minting.
+ //
+ // @param mode Enable if "true".
+ //
+ // Selector: setCollectionMintMode(bool) 00018e84
+ function setCollectionMintMode(bool mode) external;
+
+ // Check that account is the owner or admin of the collection
+ //
+ // @param user account to verify
+ // @return "true" if account is the owner or admin
+ //
+ // Selector: verifyOwnerOrAdmin(address) c2282493
+ function verifyOwnerOrAdmin(address user) external view returns (bool);
+
+ // Check that substrate account is the owner or admin of the collection
+ //
+ // @param user account to verify
+ // @return "true" if account is the owner or admin
+ //
+ // Selector: verifyOwnerOrAdmin(uint256) a83328e5
+ function verifyOwnerOrAdmin(uint256 user) external view returns (bool);
+
+ // Returns collection type
+ //
+ // @return `Fungible` or `NFT` or `ReFungible`
+ //
+ // Selector: uniqueCollectionType() d34b55b8
+ function uniqueCollectionType() external returns (string memory);
+
+ // Changes collection owner to another account
+ //
+ // @dev Owner can be changed only by current owner
+ // @param newOwner new owner account
+ //
+ // Selector: changeOwner(address) a6f9dae1
+ function changeOwner(address newOwner) external;
+
+ // Changes collection owner to another substrate account
+ //
+ // @dev Owner can be changed only by current owner
+ // @param newOwner new owner substrate account
+ //
+ // Selector: changeOwner(uint256) 924c19f7
+ function changeOwner(uint256 newOwner) external;
+}
+
interface UniqueNFT is
Dummy,
ERC165,
tests/src/eth/api/UniqueRefungible.soldiffbeforeafterboth--- a/tests/src/eth/api/UniqueRefungible.sol
+++ b/tests/src/eth/api/UniqueRefungible.sol
@@ -42,196 +42,6 @@
event MintingFinished();
}
-// Selector: 07f76b0c
-interface Collection is Dummy, ERC165 {
- // Set collection property.
- //
- // @param key Property key.
- // @param value Propery value.
- //
- // Selector: setCollectionProperty(string,bytes) 2f073f66
- function setCollectionProperty(string memory key, bytes memory value)
- external;
-
- // Delete collection property.
- //
- // @param key Property key.
- //
- // Selector: deleteCollectionProperty(string) 7b7debce
- function deleteCollectionProperty(string memory key) external;
-
- // Get collection property.
- //
- // @dev Throws error if key not found.
- //
- // @param key Property key.
- // @return bytes The property corresponding to the key.
- //
- // Selector: collectionProperty(string) cf24fd6d
- function collectionProperty(string memory key)
- external
- view
- returns (bytes memory);
-
- // Set the sponsor of the collection.
- //
- // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
- //
- // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
- //
- // Selector: setCollectionSponsor(address) 7623402e
- function setCollectionSponsor(address sponsor) external;
-
- // Collection sponsorship confirmation.
- //
- // @dev After setting the sponsor for the collection, it must be confirmed with this function.
- //
- // Selector: confirmCollectionSponsorship() 3c50e97a
- function confirmCollectionSponsorship() external;
-
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "accountTokenOwnershipLimit",
- // "sponsoredDataSize",
- // "sponsoredDataRateLimit",
- // "tokenLimit",
- // "sponsorTransferTimeout",
- // "sponsorApproveTimeout"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,uint32) 6a3841db
- function setCollectionLimit(string memory limit, uint32 value) external;
-
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "ownerCanTransfer",
- // "ownerCanDestroy",
- // "transfersEnabled"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,bool) 993b7fba
- function setCollectionLimit(string memory limit, bool value) external;
-
- // Get contract address.
- //
- // Selector: contractAddress() f6b4dfb4
- function contractAddress() external view returns (address);
-
- // Add collection admin by substrate address.
- // @param new_admin Substrate administrator address.
- //
- // Selector: addCollectionAdminSubstrate(uint256) 5730062b
- function addCollectionAdminSubstrate(uint256 newAdmin) external;
-
- // Remove collection admin by substrate address.
- // @param admin Substrate administrator address.
- //
- // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
- function removeCollectionAdminSubstrate(uint256 admin) external;
-
- // Add collection admin.
- // @param new_admin Address of the added administrator.
- //
- // Selector: addCollectionAdmin(address) 92e462c7
- function addCollectionAdmin(address newAdmin) external;
-
- // Remove collection admin.
- //
- // @param new_admin Address of the removed administrator.
- //
- // Selector: removeCollectionAdmin(address) fafd7b42
- function removeCollectionAdmin(address admin) external;
-
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
- //
- // Selector: setCollectionNesting(bool) 112d4586
- function setCollectionNesting(bool enable) external;
-
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
- // @param collections Addresses of collections that will be available for nesting.
- //
- // Selector: setCollectionNesting(bool,address[]) 64872396
- function setCollectionNesting(bool enable, address[] memory collections)
- external;
-
- // Set the collection access method.
- // @param mode Access mode
- // 0 for Normal
- // 1 for AllowList
- //
- // Selector: setCollectionAccess(uint8) 41835d4c
- function setCollectionAccess(uint8 mode) external;
-
- // Add the user to the allowed list.
- //
- // @param user Address of a trusted user.
- //
- // Selector: addToCollectionAllowList(address) 67844fe6
- function addToCollectionAllowList(address user) external;
-
- // Remove the user from the allowed list.
- //
- // @param user Address of a removed user.
- //
- // Selector: removeFromCollectionAllowList(address) 85c51acb
- function removeFromCollectionAllowList(address user) external;
-
- // Switch permission for minting.
- //
- // @param mode Enable if "true".
- //
- // Selector: setCollectionMintMode(bool) 00018e84
- function setCollectionMintMode(bool mode) external;
-
- // Check that account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdmin(address) c2282493
- function verifyOwnerOrAdmin(address user) external view returns (bool);
-
- // Check that substrate account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdminSubstrate(uint256) fe818e40
- function verifyOwnerOrAdminSubstrate(uint256 user)
- external
- view
- returns (bool);
-
- // Returns collection type
- //
- // @return `Fungible` or `NFT` or `ReFungible`
- //
- // Selector: uniqueCollectionType() d34b55b8
- function uniqueCollectionType() external returns (string memory);
-
- // Changes collection owner to another account
- //
- // @dev Owner can be changed only by current owner
- // @param newOwner new owner account
- //
- // Selector: changeOwner(address) a6f9dae1
- function changeOwner(address newOwner) external;
-
- // Changes collection owner to another substrate account
- //
- // @dev Owner can be changed only by current owner
- // @param newOwner new owner substrate account
- //
- // Selector: changeOwnerSubstrate(uint256) 337e2c60
- function changeOwnerSubstrate(uint256 newOwner) external;
-}
-
// Selector: 41369377
interface TokenProperties is Dummy, ERC165 {
// @notice Set permissions for token property.
@@ -527,6 +337,193 @@
returns (address);
}
+// Selector: f077f83e
+interface Collection is Dummy, ERC165 {
+ // Set collection property.
+ //
+ // @param key Property key.
+ // @param value Propery value.
+ //
+ // Selector: setCollectionProperty(string,bytes) 2f073f66
+ function setCollectionProperty(string memory key, bytes memory value)
+ external;
+
+ // Delete collection property.
+ //
+ // @param key Property key.
+ //
+ // Selector: deleteCollectionProperty(string) 7b7debce
+ function deleteCollectionProperty(string memory key) external;
+
+ // Get collection property.
+ //
+ // @dev Throws error if key not found.
+ //
+ // @param key Property key.
+ // @return bytes The property corresponding to the key.
+ //
+ // Selector: collectionProperty(string) cf24fd6d
+ function collectionProperty(string memory key)
+ external
+ view
+ returns (bytes memory);
+
+ // Set the sponsor of the collection.
+ //
+ // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ //
+ // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
+ //
+ // Selector: setCollectionSponsor(address) 7623402e
+ function setCollectionSponsor(address sponsor) external;
+
+ // Collection sponsorship confirmation.
+ //
+ // @dev After setting the sponsor for the collection, it must be confirmed with this function.
+ //
+ // Selector: confirmCollectionSponsorship() 3c50e97a
+ function confirmCollectionSponsorship() external;
+
+ // Set limits for the collection.
+ // @dev Throws error if limit not found.
+ // @param limit Name of the limit. Valid names:
+ // "accountTokenOwnershipLimit",
+ // "sponsoredDataSize",
+ // "sponsoredDataRateLimit",
+ // "tokenLimit",
+ // "sponsorTransferTimeout",
+ // "sponsorApproveTimeout"
+ // @param value Value of the limit.
+ //
+ // Selector: setCollectionLimit(string,uint32) 6a3841db
+ function setCollectionLimit(string memory limit, uint32 value) external;
+
+ // Set limits for the collection.
+ // @dev Throws error if limit not found.
+ // @param limit Name of the limit. Valid names:
+ // "ownerCanTransfer",
+ // "ownerCanDestroy",
+ // "transfersEnabled"
+ // @param value Value of the limit.
+ //
+ // Selector: setCollectionLimit(string,bool) 993b7fba
+ function setCollectionLimit(string memory limit, bool value) external;
+
+ // Get contract address.
+ //
+ // Selector: contractAddress() f6b4dfb4
+ function contractAddress() external view returns (address);
+
+ // Add collection admin by substrate address.
+ // @param new_admin Substrate administrator address.
+ //
+ // Selector: addCollectionAdminSubstrate(uint256) 5730062b
+ function addCollectionAdminSubstrate(uint256 newAdmin) external;
+
+ // Remove collection admin by substrate address.
+ // @param admin Substrate administrator address.
+ //
+ // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
+ function removeCollectionAdminSubstrate(uint256 admin) external;
+
+ // Add collection admin.
+ // @param new_admin Address of the added administrator.
+ //
+ // Selector: addCollectionAdmin(address) 92e462c7
+ function addCollectionAdmin(address newAdmin) external;
+
+ // Remove collection admin.
+ //
+ // @param new_admin Address of the removed administrator.
+ //
+ // Selector: removeCollectionAdmin(address) fafd7b42
+ function removeCollectionAdmin(address admin) external;
+
+ // Toggle accessibility of collection nesting.
+ //
+ // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
+ //
+ // Selector: setCollectionNesting(bool) 112d4586
+ function setCollectionNesting(bool enable) external;
+
+ // Toggle accessibility of collection nesting.
+ //
+ // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
+ // @param collections Addresses of collections that will be available for nesting.
+ //
+ // Selector: setCollectionNesting(bool,address[]) 64872396
+ function setCollectionNesting(bool enable, address[] memory collections)
+ external;
+
+ // Set the collection access method.
+ // @param mode Access mode
+ // 0 for Normal
+ // 1 for AllowList
+ //
+ // Selector: setCollectionAccess(uint8) 41835d4c
+ function setCollectionAccess(uint8 mode) external;
+
+ // Add the user to the allowed list.
+ //
+ // @param user Address of a trusted user.
+ //
+ // Selector: addToCollectionAllowList(address) 67844fe6
+ function addToCollectionAllowList(address user) external;
+
+ // Remove the user from the allowed list.
+ //
+ // @param user Address of a removed user.
+ //
+ // Selector: removeFromCollectionAllowList(address) 85c51acb
+ function removeFromCollectionAllowList(address user) external;
+
+ // Switch permission for minting.
+ //
+ // @param mode Enable if "true".
+ //
+ // Selector: setCollectionMintMode(bool) 00018e84
+ function setCollectionMintMode(bool mode) external;
+
+ // Check that account is the owner or admin of the collection
+ //
+ // @param user account to verify
+ // @return "true" if account is the owner or admin
+ //
+ // Selector: verifyOwnerOrAdmin(address) c2282493
+ function verifyOwnerOrAdmin(address user) external view returns (bool);
+
+ // Check that substrate account is the owner or admin of the collection
+ //
+ // @param user account to verify
+ // @return "true" if account is the owner or admin
+ //
+ // Selector: verifyOwnerOrAdmin(uint256) a83328e5
+ function verifyOwnerOrAdmin(uint256 user) external view returns (bool);
+
+ // Returns collection type
+ //
+ // @return `Fungible` or `NFT` or `ReFungible`
+ //
+ // Selector: uniqueCollectionType() d34b55b8
+ function uniqueCollectionType() external returns (string memory);
+
+ // Changes collection owner to another account
+ //
+ // @dev Owner can be changed only by current owner
+ // @param newOwner new owner account
+ //
+ // Selector: changeOwner(address) a6f9dae1
+ function changeOwner(address newOwner) external;
+
+ // Changes collection owner to another substrate account
+ //
+ // @dev Owner can be changed only by current owner
+ // @param newOwner new owner substrate account
+ //
+ // Selector: changeOwner(uint256) 924c19f7
+ function changeOwner(uint256 newOwner) external;
+}
+
interface UniqueRefungible is
Dummy,
ERC165,
tests/src/eth/collectionAdmin.test.tsdiffbeforeafterboth--- a/tests/src/eth/collectionAdmin.test.ts
+++ b/tests/src/eth/collectionAdmin.test.ts
@@ -373,11 +373,11 @@
const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
expect(await collectionEvm.methods.verifyOwnerOrAdmin(owner).call()).to.be.true;
- expect(await collectionEvm.methods.verifyOwnerOrAdminSubstrate(newOwner.addressRaw).call()).to.be.false;
- await collectionEvm.methods.changeOwnerSubstrate(newOwner.addressRaw).send();
+ expect(await collectionEvm.methods['verifyOwnerOrAdmin(uint256)'](newOwner.addressRaw).call()).to.be.false;
+ await collectionEvm.methods['changeOwner(uint256)'](newOwner.addressRaw).send();
expect(await collectionEvm.methods.verifyOwnerOrAdmin(owner).call()).to.be.false;
- expect(await collectionEvm.methods.verifyOwnerOrAdminSubstrate(newOwner.addressRaw).call()).to.be.true;
+ expect(await collectionEvm.methods['verifyOwnerOrAdmin(uint256)'](newOwner.addressRaw).call()).to.be.true;
});
itWeb3('change owner call fee', async ({web3, api, privateKeyWrapper}) => {
@@ -390,7 +390,7 @@
const {collectionIdAddress} = await getCollectionAddressFromResult(api, result);
const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
- const cost = await recordEthFee(api, owner, () => collectionEvm.methods.changeOwnerSubstrate(newOwner.addressRaw).send());
+ const cost = await recordEthFee(api, owner, () => collectionEvm.methods['changeOwner(uint256)'](newOwner.addressRaw).send());
expect(cost < BigInt(0.2 * Number(UNIQUE)));
expect(cost > 0);
});
@@ -406,7 +406,7 @@
const {collectionIdAddress} = await getCollectionAddressFromResult(api, result);
const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
- await expect(collectionEvm.methods.changeOwnerSubstrate(newOwner.addressRaw).send({from: otherReceiver})).to.be.rejected;
- expect(await collectionEvm.methods.verifyOwnerOrAdminSubstrate(newOwner.addressRaw).call()).to.be.false;
+ await expect(collectionEvm.methods['changeOwner(uint256)'](newOwner.addressRaw).send({from: otherReceiver})).to.be.rejected;
+ expect(await collectionEvm.methods['verifyOwnerOrAdmin(uint256)'](newOwner.addressRaw).call()).to.be.false;
});
});
\ No newline at end of file
tests/src/eth/fungibleAbi.jsondiffbeforeafterboth--- a/tests/src/eth/fungibleAbi.json
+++ b/tests/src/eth/fungibleAbi.json
@@ -117,7 +117,7 @@
},
{
"inputs": [
- { "internalType": "address", "name": "newOwner", "type": "address" }
+ { "internalType": "uint256", "name": "newOwner", "type": "uint256" }
],
"name": "changeOwner",
"outputs": [],
@@ -126,9 +126,9 @@
},
{
"inputs": [
- { "internalType": "uint256", "name": "newOwner", "type": "uint256" }
+ { "internalType": "address", "name": "newOwner", "type": "address" }
],
- "name": "changeOwnerSubstrate",
+ "name": "changeOwner",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
@@ -329,7 +329,7 @@
},
{
"inputs": [
- { "internalType": "address", "name": "user", "type": "address" }
+ { "internalType": "uint256", "name": "user", "type": "uint256" }
],
"name": "verifyOwnerOrAdmin",
"outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
@@ -338,9 +338,9 @@
},
{
"inputs": [
- { "internalType": "uint256", "name": "user", "type": "uint256" }
+ { "internalType": "address", "name": "user", "type": "address" }
],
- "name": "verifyOwnerOrAdminSubstrate",
+ "name": "verifyOwnerOrAdmin",
"outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
"stateMutability": "view",
"type": "function"
tests/src/eth/nonFungibleAbi.jsondiffbeforeafterboth--- a/tests/src/eth/nonFungibleAbi.json
+++ b/tests/src/eth/nonFungibleAbi.json
@@ -147,7 +147,7 @@
},
{
"inputs": [
- { "internalType": "address", "name": "newOwner", "type": "address" }
+ { "internalType": "uint256", "name": "newOwner", "type": "uint256" }
],
"name": "changeOwner",
"outputs": [],
@@ -156,9 +156,9 @@
},
{
"inputs": [
- { "internalType": "uint256", "name": "newOwner", "type": "uint256" }
+ { "internalType": "address", "name": "newOwner", "type": "address" }
],
- "name": "changeOwnerSubstrate",
+ "name": "changeOwner",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
@@ -554,7 +554,7 @@
},
{
"inputs": [
- { "internalType": "address", "name": "user", "type": "address" }
+ { "internalType": "uint256", "name": "user", "type": "uint256" }
],
"name": "verifyOwnerOrAdmin",
"outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
@@ -563,9 +563,9 @@
},
{
"inputs": [
- { "internalType": "uint256", "name": "user", "type": "uint256" }
+ { "internalType": "address", "name": "user", "type": "address" }
],
- "name": "verifyOwnerOrAdminSubstrate",
+ "name": "verifyOwnerOrAdmin",
"outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
"stateMutability": "view",
"type": "function"
tests/src/eth/reFungibleAbi.jsondiffbeforeafterboth1[2 {3 "anonymous": false,4 "inputs": [5 {6 "indexed": true,7 "internalType": "address",8 "name": "owner",9 "type": "address"10 },11 {12 "indexed": true,13 "internalType": "address",14 "name": "approved",15 "type": "address"16 },17 {18 "indexed": true,19 "internalType": "uint256",20 "name": "tokenId",21 "type": "uint256"22 }23 ],24 "name": "Approval",25 "type": "event"26 },27 {28 "anonymous": false,29 "inputs": [30 {31 "indexed": true,32 "internalType": "address",33 "name": "owner",34 "type": "address"35 },36 {37 "indexed": true,38 "internalType": "address",39 "name": "operator",40 "type": "address"41 },42 {43 "indexed": false,44 "internalType": "bool",45 "name": "approved",46 "type": "bool"47 }48 ],49 "name": "ApprovalForAll",50 "type": "event"51 },52 {53 "anonymous": false,54 "inputs": [],55 "name": "MintingFinished",56 "type": "event"57 },58 {59 "anonymous": false,60 "inputs": [61 {62 "indexed": true,63 "internalType": "address",64 "name": "from",65 "type": "address"66 },67 {68 "indexed": true,69 "internalType": "address",70 "name": "to",71 "type": "address"72 },73 {74 "indexed": true,75 "internalType": "uint256",76 "name": "tokenId",77 "type": "uint256"78 }79 ],80 "name": "Transfer",81 "type": "event"82 },83 {84 "inputs": [85 { "internalType": "address", "name": "newAdmin", "type": "address" }86 ],87 "name": "addCollectionAdmin",88 "outputs": [],89 "stateMutability": "nonpayable",90 "type": "function"91 },92 {93 "inputs": [94 { "internalType": "uint256", "name": "newAdmin", "type": "uint256" }95 ],96 "name": "addCollectionAdminSubstrate",97 "outputs": [],98 "stateMutability": "nonpayable",99 "type": "function"100 },101 {102 "inputs": [103 { "internalType": "address", "name": "user", "type": "address" }104 ],105 "name": "addToCollectionAllowList",106 "outputs": [],107 "stateMutability": "nonpayable",108 "type": "function"109 },110 {111 "inputs": [112 { "internalType": "address", "name": "approved", "type": "address" },113 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }114 ],115 "name": "approve",116 "outputs": [],117 "stateMutability": "nonpayable",118 "type": "function"119 },120 {121 "inputs": [122 { "internalType": "address", "name": "owner", "type": "address" }123 ],124 "name": "balanceOf",125 "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],126 "stateMutability": "view",127 "type": "function"128 },129 {130 "inputs": [131 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }132 ],133 "name": "burn",134 "outputs": [],135 "stateMutability": "nonpayable",136 "type": "function"137 },138 {139 "inputs": [140 { "internalType": "address", "name": "from", "type": "address" },141 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }142 ],143 "name": "burnFrom",144 "outputs": [],145 "stateMutability": "nonpayable",146 "type": "function"147 },148 {149 "inputs": [150 { "internalType": "address", "name": "newOwner", "type": "address" }151 ],152 "name": "changeOwner",153 "outputs": [],154 "stateMutability": "nonpayable",155 "type": "function"156 },157 {158 "inputs": [159 { "internalType": "uint256", "name": "newOwner", "type": "uint256" }160 ],161 "name": "changeOwnerSubstrate",162 "outputs": [],163 "stateMutability": "nonpayable",164 "type": "function"165 },166 {167 "inputs": [{ "internalType": "string", "name": "key", "type": "string" }],168 "name": "collectionProperty",169 "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }],170 "stateMutability": "view",171 "type": "function"172 },173 {174 "inputs": [],175 "name": "confirmCollectionSponsorship",176 "outputs": [],177 "stateMutability": "nonpayable",178 "type": "function"179 },180 {181 "inputs": [],182 "name": "contractAddress",183 "outputs": [{ "internalType": "address", "name": "", "type": "address" }],184 "stateMutability": "view",185 "type": "function"186 },187 {188 "inputs": [{ "internalType": "string", "name": "key", "type": "string" }],189 "name": "deleteCollectionProperty",190 "outputs": [],191 "stateMutability": "nonpayable",192 "type": "function"193 },194 {195 "inputs": [196 { "internalType": "uint256", "name": "tokenId", "type": "uint256" },197 { "internalType": "string", "name": "key", "type": "string" }198 ],199 "name": "deleteProperty",200 "outputs": [],201 "stateMutability": "nonpayable",202 "type": "function"203 },204 {205 "inputs": [],206 "name": "finishMinting",207 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],208 "stateMutability": "nonpayable",209 "type": "function"210 },211 {212 "inputs": [213 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }214 ],215 "name": "getApproved",216 "outputs": [{ "internalType": "address", "name": "", "type": "address" }],217 "stateMutability": "view",218 "type": "function"219 },220 {221 "inputs": [222 { "internalType": "address", "name": "owner", "type": "address" },223 { "internalType": "address", "name": "operator", "type": "address" }224 ],225 "name": "isApprovedForAll",226 "outputs": [{ "internalType": "address", "name": "", "type": "address" }],227 "stateMutability": "view",228 "type": "function"229 },230 {231 "inputs": [232 { "internalType": "address", "name": "to", "type": "address" },233 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }234 ],235 "name": "mint",236 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],237 "stateMutability": "nonpayable",238 "type": "function"239 },240 {241 "inputs": [242 { "internalType": "address", "name": "to", "type": "address" },243 { "internalType": "uint256[]", "name": "tokenIds", "type": "uint256[]" }244 ],245 "name": "mintBulk",246 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],247 "stateMutability": "nonpayable",248 "type": "function"249 },250 {251 "inputs": [252 { "internalType": "address", "name": "to", "type": "address" },253 {254 "components": [255 { "internalType": "uint256", "name": "field_0", "type": "uint256" },256 { "internalType": "string", "name": "field_1", "type": "string" }257 ],258 "internalType": "struct Tuple0[]",259 "name": "tokens",260 "type": "tuple[]"261 }262 ],263 "name": "mintBulkWithTokenURI",264 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],265 "stateMutability": "nonpayable",266 "type": "function"267 },268 {269 "inputs": [270 { "internalType": "address", "name": "to", "type": "address" },271 { "internalType": "uint256", "name": "tokenId", "type": "uint256" },272 { "internalType": "string", "name": "tokenUri", "type": "string" }273 ],274 "name": "mintWithTokenURI",275 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],276 "stateMutability": "nonpayable",277 "type": "function"278 },279 {280 "inputs": [],281 "name": "mintingFinished",282 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],283 "stateMutability": "view",284 "type": "function"285 },286 {287 "inputs": [],288 "name": "name",289 "outputs": [{ "internalType": "string", "name": "", "type": "string" }],290 "stateMutability": "view",291 "type": "function"292 },293 {294 "inputs": [],295 "name": "nextTokenId",296 "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],297 "stateMutability": "view",298 "type": "function"299 },300 {301 "inputs": [302 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }303 ],304 "name": "ownerOf",305 "outputs": [{ "internalType": "address", "name": "", "type": "address" }],306 "stateMutability": "view",307 "type": "function"308 },309 {310 "inputs": [311 { "internalType": "uint256", "name": "tokenId", "type": "uint256" },312 { "internalType": "string", "name": "key", "type": "string" }313 ],314 "name": "property",315 "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }],316 "stateMutability": "view",317 "type": "function"318 },319 {320 "inputs": [321 { "internalType": "address", "name": "admin", "type": "address" }322 ],323 "name": "removeCollectionAdmin",324 "outputs": [],325 "stateMutability": "nonpayable",326 "type": "function"327 },328 {329 "inputs": [330 { "internalType": "uint256", "name": "admin", "type": "uint256" }331 ],332 "name": "removeCollectionAdminSubstrate",333 "outputs": [],334 "stateMutability": "nonpayable",335 "type": "function"336 },337 {338 "inputs": [339 { "internalType": "address", "name": "user", "type": "address" }340 ],341 "name": "removeFromCollectionAllowList",342 "outputs": [],343 "stateMutability": "nonpayable",344 "type": "function"345 },346 {347 "inputs": [348 { "internalType": "address", "name": "from", "type": "address" },349 { "internalType": "address", "name": "to", "type": "address" },350 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }351 ],352 "name": "safeTransferFrom",353 "outputs": [],354 "stateMutability": "nonpayable",355 "type": "function"356 },357 {358 "inputs": [359 { "internalType": "address", "name": "from", "type": "address" },360 { "internalType": "address", "name": "to", "type": "address" },361 { "internalType": "uint256", "name": "tokenId", "type": "uint256" },362 { "internalType": "bytes", "name": "data", "type": "bytes" }363 ],364 "name": "safeTransferFromWithData",365 "outputs": [],366 "stateMutability": "nonpayable",367 "type": "function"368 },369 {370 "inputs": [371 { "internalType": "address", "name": "operator", "type": "address" },372 { "internalType": "bool", "name": "approved", "type": "bool" }373 ],374 "name": "setApprovalForAll",375 "outputs": [],376 "stateMutability": "nonpayable",377 "type": "function"378 },379 {380 "inputs": [{ "internalType": "uint8", "name": "mode", "type": "uint8" }],381 "name": "setCollectionAccess",382 "outputs": [],383 "stateMutability": "nonpayable",384 "type": "function"385 },386 {387 "inputs": [388 { "internalType": "string", "name": "limit", "type": "string" },389 { "internalType": "uint32", "name": "value", "type": "uint32" }390 ],391 "name": "setCollectionLimit",392 "outputs": [],393 "stateMutability": "nonpayable",394 "type": "function"395 },396 {397 "inputs": [398 { "internalType": "string", "name": "limit", "type": "string" },399 { "internalType": "bool", "name": "value", "type": "bool" }400 ],401 "name": "setCollectionLimit",402 "outputs": [],403 "stateMutability": "nonpayable",404 "type": "function"405 },406 {407 "inputs": [{ "internalType": "bool", "name": "mode", "type": "bool" }],408 "name": "setCollectionMintMode",409 "outputs": [],410 "stateMutability": "nonpayable",411 "type": "function"412 },413 {414 "inputs": [{ "internalType": "bool", "name": "enable", "type": "bool" }],415 "name": "setCollectionNesting",416 "outputs": [],417 "stateMutability": "nonpayable",418 "type": "function"419 },420 {421 "inputs": [422 { "internalType": "bool", "name": "enable", "type": "bool" },423 {424 "internalType": "address[]",425 "name": "collections",426 "type": "address[]"427 }428 ],429 "name": "setCollectionNesting",430 "outputs": [],431 "stateMutability": "nonpayable",432 "type": "function"433 },434 {435 "inputs": [436 { "internalType": "string", "name": "key", "type": "string" },437 { "internalType": "bytes", "name": "value", "type": "bytes" }438 ],439 "name": "setCollectionProperty",440 "outputs": [],441 "stateMutability": "nonpayable",442 "type": "function"443 },444 {445 "inputs": [446 { "internalType": "address", "name": "sponsor", "type": "address" }447 ],448 "name": "setCollectionSponsor",449 "outputs": [],450 "stateMutability": "nonpayable",451 "type": "function"452 },453 {454 "inputs": [455 { "internalType": "uint256", "name": "tokenId", "type": "uint256" },456 { "internalType": "string", "name": "key", "type": "string" },457 { "internalType": "bytes", "name": "value", "type": "bytes" }458 ],459 "name": "setProperty",460 "outputs": [],461 "stateMutability": "nonpayable",462 "type": "function"463 },464 {465 "inputs": [466 { "internalType": "string", "name": "key", "type": "string" },467 { "internalType": "bool", "name": "isMutable", "type": "bool" },468 { "internalType": "bool", "name": "collectionAdmin", "type": "bool" },469 { "internalType": "bool", "name": "tokenOwner", "type": "bool" }470 ],471 "name": "setTokenPropertyPermission",472 "outputs": [],473 "stateMutability": "nonpayable",474 "type": "function"475 },476 {477 "inputs": [478 { "internalType": "bytes4", "name": "interfaceID", "type": "bytes4" }479 ],480 "name": "supportsInterface",481 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],482 "stateMutability": "view",483 "type": "function"484 },485 {486 "inputs": [],487 "name": "symbol",488 "outputs": [{ "internalType": "string", "name": "", "type": "string" }],489 "stateMutability": "view",490 "type": "function"491 },492 {493 "inputs": [494 { "internalType": "uint256", "name": "index", "type": "uint256" }495 ],496 "name": "tokenByIndex",497 "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],498 "stateMutability": "view",499 "type": "function"500 },501 {502 "inputs": [503 { "internalType": "uint256", "name": "token", "type": "uint256" }504 ],505 "name": "tokenContractAddress",506 "outputs": [{ "internalType": "address", "name": "", "type": "address" }],507 "stateMutability": "view",508 "type": "function"509 },510 {511 "inputs": [512 { "internalType": "address", "name": "owner", "type": "address" },513 { "internalType": "uint256", "name": "index", "type": "uint256" }514 ],515 "name": "tokenOfOwnerByIndex",516 "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],517 "stateMutability": "view",518 "type": "function"519 },520 {521 "inputs": [522 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }523 ],524 "name": "tokenURI",525 "outputs": [{ "internalType": "string", "name": "", "type": "string" }],526 "stateMutability": "view",527 "type": "function"528 },529 {530 "inputs": [],531 "name": "totalSupply",532 "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],533 "stateMutability": "view",534 "type": "function"535 },536 {537 "inputs": [538 { "internalType": "address", "name": "to", "type": "address" },539 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }540 ],541 "name": "transfer",542 "outputs": [],543 "stateMutability": "nonpayable",544 "type": "function"545 },546 {547 "inputs": [548 { "internalType": "address", "name": "from", "type": "address" },549 { "internalType": "address", "name": "to", "type": "address" },550 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }551 ],552 "name": "transferFrom",553 "outputs": [],554 "stateMutability": "nonpayable",555 "type": "function"556 },557 {558 "inputs": [],559 "name": "uniqueCollectionType",560 "outputs": [{ "internalType": "string", "name": "", "type": "string" }],561 "stateMutability": "nonpayable",562 "type": "function"563 },564 {565 "inputs": [566 { "internalType": "address", "name": "user", "type": "address" }567 ],568 "name": "verifyOwnerOrAdmin",569 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],570 "stateMutability": "view",571 "type": "function"572 },573 {574 "inputs": [575 { "internalType": "uint256", "name": "user", "type": "uint256" }576 ],577 "name": "verifyOwnerOrAdminSubstrate",578 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],579 "stateMutability": "view",580 "type": "function"581 }582]1[2 {3 "anonymous": false,4 "inputs": [5 {6 "indexed": true,7 "internalType": "address",8 "name": "owner",9 "type": "address"10 },11 {12 "indexed": true,13 "internalType": "address",14 "name": "approved",15 "type": "address"16 },17 {18 "indexed": true,19 "internalType": "uint256",20 "name": "tokenId",21 "type": "uint256"22 }23 ],24 "name": "Approval",25 "type": "event"26 },27 {28 "anonymous": false,29 "inputs": [30 {31 "indexed": true,32 "internalType": "address",33 "name": "owner",34 "type": "address"35 },36 {37 "indexed": true,38 "internalType": "address",39 "name": "operator",40 "type": "address"41 },42 {43 "indexed": false,44 "internalType": "bool",45 "name": "approved",46 "type": "bool"47 }48 ],49 "name": "ApprovalForAll",50 "type": "event"51 },52 {53 "anonymous": false,54 "inputs": [],55 "name": "MintingFinished",56 "type": "event"57 },58 {59 "anonymous": false,60 "inputs": [61 {62 "indexed": true,63 "internalType": "address",64 "name": "from",65 "type": "address"66 },67 {68 "indexed": true,69 "internalType": "address",70 "name": "to",71 "type": "address"72 },73 {74 "indexed": true,75 "internalType": "uint256",76 "name": "tokenId",77 "type": "uint256"78 }79 ],80 "name": "Transfer",81 "type": "event"82 },83 {84 "inputs": [85 { "internalType": "address", "name": "newAdmin", "type": "address" }86 ],87 "name": "addCollectionAdmin",88 "outputs": [],89 "stateMutability": "nonpayable",90 "type": "function"91 },92 {93 "inputs": [94 { "internalType": "uint256", "name": "newAdmin", "type": "uint256" }95 ],96 "name": "addCollectionAdminSubstrate",97 "outputs": [],98 "stateMutability": "nonpayable",99 "type": "function"100 },101 {102 "inputs": [103 { "internalType": "address", "name": "user", "type": "address" }104 ],105 "name": "addToCollectionAllowList",106 "outputs": [],107 "stateMutability": "nonpayable",108 "type": "function"109 },110 {111 "inputs": [112 { "internalType": "address", "name": "approved", "type": "address" },113 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }114 ],115 "name": "approve",116 "outputs": [],117 "stateMutability": "nonpayable",118 "type": "function"119 },120 {121 "inputs": [122 { "internalType": "address", "name": "owner", "type": "address" }123 ],124 "name": "balanceOf",125 "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],126 "stateMutability": "view",127 "type": "function"128 },129 {130 "inputs": [131 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }132 ],133 "name": "burn",134 "outputs": [],135 "stateMutability": "nonpayable",136 "type": "function"137 },138 {139 "inputs": [140 { "internalType": "address", "name": "from", "type": "address" },141 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }142 ],143 "name": "burnFrom",144 "outputs": [],145 "stateMutability": "nonpayable",146 "type": "function"147 },148 {149 "inputs": [150 { "internalType": "uint256", "name": "newOwner", "type": "uint256" }151 ],152 "name": "changeOwner",153 "outputs": [],154 "stateMutability": "nonpayable",155 "type": "function"156 },157 {158 "inputs": [159 { "internalType": "address", "name": "newOwner", "type": "address" }160 ],161 "name": "changeOwner",162 "outputs": [],163 "stateMutability": "nonpayable",164 "type": "function"165 },166 {167 "inputs": [{ "internalType": "string", "name": "key", "type": "string" }],168 "name": "collectionProperty",169 "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }],170 "stateMutability": "view",171 "type": "function"172 },173 {174 "inputs": [],175 "name": "confirmCollectionSponsorship",176 "outputs": [],177 "stateMutability": "nonpayable",178 "type": "function"179 },180 {181 "inputs": [],182 "name": "contractAddress",183 "outputs": [{ "internalType": "address", "name": "", "type": "address" }],184 "stateMutability": "view",185 "type": "function"186 },187 {188 "inputs": [{ "internalType": "string", "name": "key", "type": "string" }],189 "name": "deleteCollectionProperty",190 "outputs": [],191 "stateMutability": "nonpayable",192 "type": "function"193 },194 {195 "inputs": [196 { "internalType": "uint256", "name": "tokenId", "type": "uint256" },197 { "internalType": "string", "name": "key", "type": "string" }198 ],199 "name": "deleteProperty",200 "outputs": [],201 "stateMutability": "nonpayable",202 "type": "function"203 },204 {205 "inputs": [],206 "name": "finishMinting",207 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],208 "stateMutability": "nonpayable",209 "type": "function"210 },211 {212 "inputs": [213 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }214 ],215 "name": "getApproved",216 "outputs": [{ "internalType": "address", "name": "", "type": "address" }],217 "stateMutability": "view",218 "type": "function"219 },220 {221 "inputs": [222 { "internalType": "address", "name": "owner", "type": "address" },223 { "internalType": "address", "name": "operator", "type": "address" }224 ],225 "name": "isApprovedForAll",226 "outputs": [{ "internalType": "address", "name": "", "type": "address" }],227 "stateMutability": "view",228 "type": "function"229 },230 {231 "inputs": [232 { "internalType": "address", "name": "to", "type": "address" },233 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }234 ],235 "name": "mint",236 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],237 "stateMutability": "nonpayable",238 "type": "function"239 },240 {241 "inputs": [242 { "internalType": "address", "name": "to", "type": "address" },243 { "internalType": "uint256[]", "name": "tokenIds", "type": "uint256[]" }244 ],245 "name": "mintBulk",246 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],247 "stateMutability": "nonpayable",248 "type": "function"249 },250 {251 "inputs": [252 { "internalType": "address", "name": "to", "type": "address" },253 {254 "components": [255 { "internalType": "uint256", "name": "field_0", "type": "uint256" },256 { "internalType": "string", "name": "field_1", "type": "string" }257 ],258 "internalType": "struct Tuple0[]",259 "name": "tokens",260 "type": "tuple[]"261 }262 ],263 "name": "mintBulkWithTokenURI",264 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],265 "stateMutability": "nonpayable",266 "type": "function"267 },268 {269 "inputs": [270 { "internalType": "address", "name": "to", "type": "address" },271 { "internalType": "uint256", "name": "tokenId", "type": "uint256" },272 { "internalType": "string", "name": "tokenUri", "type": "string" }273 ],274 "name": "mintWithTokenURI",275 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],276 "stateMutability": "nonpayable",277 "type": "function"278 },279 {280 "inputs": [],281 "name": "mintingFinished",282 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],283 "stateMutability": "view",284 "type": "function"285 },286 {287 "inputs": [],288 "name": "name",289 "outputs": [{ "internalType": "string", "name": "", "type": "string" }],290 "stateMutability": "view",291 "type": "function"292 },293 {294 "inputs": [],295 "name": "nextTokenId",296 "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],297 "stateMutability": "view",298 "type": "function"299 },300 {301 "inputs": [302 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }303 ],304 "name": "ownerOf",305 "outputs": [{ "internalType": "address", "name": "", "type": "address" }],306 "stateMutability": "view",307 "type": "function"308 },309 {310 "inputs": [311 { "internalType": "uint256", "name": "tokenId", "type": "uint256" },312 { "internalType": "string", "name": "key", "type": "string" }313 ],314 "name": "property",315 "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }],316 "stateMutability": "view",317 "type": "function"318 },319 {320 "inputs": [321 { "internalType": "address", "name": "admin", "type": "address" }322 ],323 "name": "removeCollectionAdmin",324 "outputs": [],325 "stateMutability": "nonpayable",326 "type": "function"327 },328 {329 "inputs": [330 { "internalType": "uint256", "name": "admin", "type": "uint256" }331 ],332 "name": "removeCollectionAdminSubstrate",333 "outputs": [],334 "stateMutability": "nonpayable",335 "type": "function"336 },337 {338 "inputs": [339 { "internalType": "address", "name": "user", "type": "address" }340 ],341 "name": "removeFromCollectionAllowList",342 "outputs": [],343 "stateMutability": "nonpayable",344 "type": "function"345 },346 {347 "inputs": [348 { "internalType": "address", "name": "from", "type": "address" },349 { "internalType": "address", "name": "to", "type": "address" },350 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }351 ],352 "name": "safeTransferFrom",353 "outputs": [],354 "stateMutability": "nonpayable",355 "type": "function"356 },357 {358 "inputs": [359 { "internalType": "address", "name": "from", "type": "address" },360 { "internalType": "address", "name": "to", "type": "address" },361 { "internalType": "uint256", "name": "tokenId", "type": "uint256" },362 { "internalType": "bytes", "name": "data", "type": "bytes" }363 ],364 "name": "safeTransferFromWithData",365 "outputs": [],366 "stateMutability": "nonpayable",367 "type": "function"368 },369 {370 "inputs": [371 { "internalType": "address", "name": "operator", "type": "address" },372 { "internalType": "bool", "name": "approved", "type": "bool" }373 ],374 "name": "setApprovalForAll",375 "outputs": [],376 "stateMutability": "nonpayable",377 "type": "function"378 },379 {380 "inputs": [{ "internalType": "uint8", "name": "mode", "type": "uint8" }],381 "name": "setCollectionAccess",382 "outputs": [],383 "stateMutability": "nonpayable",384 "type": "function"385 },386 {387 "inputs": [388 { "internalType": "string", "name": "limit", "type": "string" },389 { "internalType": "uint32", "name": "value", "type": "uint32" }390 ],391 "name": "setCollectionLimit",392 "outputs": [],393 "stateMutability": "nonpayable",394 "type": "function"395 },396 {397 "inputs": [398 { "internalType": "string", "name": "limit", "type": "string" },399 { "internalType": "bool", "name": "value", "type": "bool" }400 ],401 "name": "setCollectionLimit",402 "outputs": [],403 "stateMutability": "nonpayable",404 "type": "function"405 },406 {407 "inputs": [{ "internalType": "bool", "name": "mode", "type": "bool" }],408 "name": "setCollectionMintMode",409 "outputs": [],410 "stateMutability": "nonpayable",411 "type": "function"412 },413 {414 "inputs": [{ "internalType": "bool", "name": "enable", "type": "bool" }],415 "name": "setCollectionNesting",416 "outputs": [],417 "stateMutability": "nonpayable",418 "type": "function"419 },420 {421 "inputs": [422 { "internalType": "bool", "name": "enable", "type": "bool" },423 {424 "internalType": "address[]",425 "name": "collections",426 "type": "address[]"427 }428 ],429 "name": "setCollectionNesting",430 "outputs": [],431 "stateMutability": "nonpayable",432 "type": "function"433 },434 {435 "inputs": [436 { "internalType": "string", "name": "key", "type": "string" },437 { "internalType": "bytes", "name": "value", "type": "bytes" }438 ],439 "name": "setCollectionProperty",440 "outputs": [],441 "stateMutability": "nonpayable",442 "type": "function"443 },444 {445 "inputs": [446 { "internalType": "address", "name": "sponsor", "type": "address" }447 ],448 "name": "setCollectionSponsor",449 "outputs": [],450 "stateMutability": "nonpayable",451 "type": "function"452 },453 {454 "inputs": [455 { "internalType": "uint256", "name": "tokenId", "type": "uint256" },456 { "internalType": "string", "name": "key", "type": "string" },457 { "internalType": "bytes", "name": "value", "type": "bytes" }458 ],459 "name": "setProperty",460 "outputs": [],461 "stateMutability": "nonpayable",462 "type": "function"463 },464 {465 "inputs": [466 { "internalType": "string", "name": "key", "type": "string" },467 { "internalType": "bool", "name": "isMutable", "type": "bool" },468 { "internalType": "bool", "name": "collectionAdmin", "type": "bool" },469 { "internalType": "bool", "name": "tokenOwner", "type": "bool" }470 ],471 "name": "setTokenPropertyPermission",472 "outputs": [],473 "stateMutability": "nonpayable",474 "type": "function"475 },476 {477 "inputs": [478 { "internalType": "bytes4", "name": "interfaceID", "type": "bytes4" }479 ],480 "name": "supportsInterface",481 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],482 "stateMutability": "view",483 "type": "function"484 },485 {486 "inputs": [],487 "name": "symbol",488 "outputs": [{ "internalType": "string", "name": "", "type": "string" }],489 "stateMutability": "view",490 "type": "function"491 },492 {493 "inputs": [494 { "internalType": "uint256", "name": "index", "type": "uint256" }495 ],496 "name": "tokenByIndex",497 "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],498 "stateMutability": "view",499 "type": "function"500 },501 {502 "inputs": [503 { "internalType": "uint256", "name": "token", "type": "uint256" }504 ],505 "name": "tokenContractAddress",506 "outputs": [{ "internalType": "address", "name": "", "type": "address" }],507 "stateMutability": "view",508 "type": "function"509 },510 {511 "inputs": [512 { "internalType": "address", "name": "owner", "type": "address" },513 { "internalType": "uint256", "name": "index", "type": "uint256" }514 ],515 "name": "tokenOfOwnerByIndex",516 "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],517 "stateMutability": "view",518 "type": "function"519 },520 {521 "inputs": [522 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }523 ],524 "name": "tokenURI",525 "outputs": [{ "internalType": "string", "name": "", "type": "string" }],526 "stateMutability": "view",527 "type": "function"528 },529 {530 "inputs": [],531 "name": "totalSupply",532 "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],533 "stateMutability": "view",534 "type": "function"535 },536 {537 "inputs": [538 { "internalType": "address", "name": "to", "type": "address" },539 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }540 ],541 "name": "transfer",542 "outputs": [],543 "stateMutability": "nonpayable",544 "type": "function"545 },546 {547 "inputs": [548 { "internalType": "address", "name": "from", "type": "address" },549 { "internalType": "address", "name": "to", "type": "address" },550 { "internalType": "uint256", "name": "tokenId", "type": "uint256" }551 ],552 "name": "transferFrom",553 "outputs": [],554 "stateMutability": "nonpayable",555 "type": "function"556 },557 {558 "inputs": [],559 "name": "uniqueCollectionType",560 "outputs": [{ "internalType": "string", "name": "", "type": "string" }],561 "stateMutability": "nonpayable",562 "type": "function"563 },564 {565 "inputs": [566 { "internalType": "uint256", "name": "user", "type": "uint256" }567 ],568 "name": "verifyOwnerOrAdmin",569 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],570 "stateMutability": "view",571 "type": "function"572 },573 {574 "inputs": [575 { "internalType": "address", "name": "user", "type": "address" }576 ],577 "name": "verifyOwnerOrAdmin",578 "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],579 "stateMutability": "view",580 "type": "function"581 }582]