git.delta.rocks / unique-network / refs/commits / 2be843eb2a54

difftreelog

source

tests/src/eth/api/UniqueRefungibleToken.sol4.4 KiBsourcehistory
1// SPDX-License-Identifier: OTHER2// This code is automatically generated34pragma solidity >=0.8.0 <0.9.0;56// Common stubs holder7interface Dummy {89}1011interface ERC165 is Dummy {12	function supportsInterface(bytes4 interfaceID) external view returns (bool);13}1415// Inline16interface ERC20Events {17	event Transfer(address indexed from, address indexed to, uint256 value);18	event Approval(19		address indexed owner,20		address indexed spender,21		uint256 value22	);23}2425// Selector: 042f110626interface ERC1633UniqueExtensions is Dummy, ERC165 {27	// Selector: setParentNFT(address,uint256) 042f110628	function setParentNFT(address collection, uint256 nftId)29		external30		returns (bool);31}3233// Selector: 5755c3f234interface ERC1633 is Dummy, ERC165 {35	// Selector: parentToken() 80a5400136	function parentToken() external view returns (address);3738	// Selector: parentTokenId() d7f083f339	function parentTokenId() external view returns (uint256);40}4142// Selector: 942e8b2243interface ERC20 is Dummy, ERC165, ERC20Events {44	// @return the name of the token.45	//46	// Selector: name() 06fdde0347	function name() external view returns (string memory);4849	// @return the symbol of the token.50	//51	// Selector: symbol() 95d89b4152	function symbol() external view returns (string memory);5354	// @dev Total number of tokens in existence55	//56	// Selector: totalSupply() 18160ddd57	function totalSupply() external view returns (uint256);5859	// @dev Not supported60	//61	// Selector: decimals() 313ce56762	function decimals() external view returns (uint8);6364	// @dev Gets the balance of the specified address.65	// @param owner The address to query the balance of.66	// @return An uint256 representing the amount owned by the passed address.67	//68	// Selector: balanceOf(address) 70a0823169	function balanceOf(address owner) external view returns (uint256);7071	// @dev Transfer token for a specified address72	// @param to The address to transfer to.73	// @param amount The amount to be transferred.74	//75	// Selector: transfer(address,uint256) a9059cbb76	function transfer(address to, uint256 amount) external returns (bool);7778	// @dev Transfer tokens from one address to another79	// @param from address The address which you want to send tokens from80	// @param to address The address which you want to transfer to81	// @param amount uint256 the amount of tokens to be transferred82	//83	// Selector: transferFrom(address,address,uint256) 23b872dd84	function transferFrom(85		address from,86		address to,87		uint256 amount88	) external returns (bool);8990	// @dev Approve the passed address to spend the specified amount of tokens on behalf of `msg.sender`.91	// Beware that changing an allowance with this method brings the risk that someone may use both the old92	// and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this93	// race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards:94	// https://github.com/ethereum/EIPs/issues/20#issuecomment-26352472995	// @param spender The address which will spend the funds.96	// @param amount The amount of tokens to be spent.97	//98	// Selector: approve(address,uint256) 095ea7b399	function approve(address spender, uint256 amount) external returns (bool);100101	// @dev Function to check the amount of tokens that an owner allowed to a spender.102	// @param owner address The address which owns the funds.103	// @param spender address The address which will spend the funds.104	// @return A uint256 specifying the amount of tokens still available for the spender.105	//106	// Selector: allowance(address,address) dd62ed3e107	function allowance(address owner, address spender)108		external109		view110		returns (uint256);111}112113// Selector: ab8deb37114interface ERC20UniqueExtensions is Dummy, ERC165 {115	// @dev Function that burns an amount of the token of a given account,116	// deducting from the sender's allowance for said account.117	// @param from The account whose tokens will be burnt.118	// @param amount The amount that will be burnt.119	//120	// Selector: burnFrom(address,uint256) 79cc6790121	function burnFrom(address from, uint256 amount) external returns (bool);122123	// @dev Function that changes total amount of the tokens.124	//  Throws if `msg.sender` doesn't owns all of the tokens.125	// @param amount New total amount of the tokens.126	//127	// Selector: repartition(uint256) d2418ca7128	function repartition(uint256 amount) external returns (bool);129}130131interface UniqueRefungibleToken is132	Dummy,133	ERC165,134	ERC20,135	ERC20UniqueExtensions,136	ERC1633,137	ERC1633UniqueExtensions138{}