Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Name:
IterableMapping
Compiler Version
v0.6.12+commit.27d51765
Contract Source Code (Solidity)
/** *Submitted for verification at Etherscan.io on 2021-08-09 */ library IterableMapping { // Iterable mapping from address to uint; struct Map { address[] keys; mapping(address => uint256) values; mapping(address => uint256) indexOf; mapping(address => bool) inserted; } function get(Map storage map, address key) public view returns (uint256) { return map.values[key]; } function getIndexOfKey(Map storage map, address key) public view returns (int256) { if (!map.inserted[key]) { return -1; } return int256(map.indexOf[key]); } function getKeyAtIndex(Map storage map, uint256 index) public view returns (address) { return map.keys[index]; } function size(Map storage map) public view returns (uint256) { return map.keys.length; } function set( Map storage map, address key, uint256 val ) public { if (map.inserted[key]) { map.values[key] = val; } else { map.inserted[key] = true; map.values[key] = val; map.indexOf[key] = map.keys.length; map.keys.push(key); } } function remove(Map storage map, address key) public { if (!map.inserted[key]) { return; } delete map.inserted[key]; delete map.values[key]; uint256 index = map.indexOf[key]; uint256 lastIndex = map.keys.length - 1; address lastKey = map.keys[lastIndex]; map.indexOf[lastKey] = index; delete map.indexOf[key]; map.keys[index] = lastKey; map.keys.pop(); } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract Creation Code
61044e610026600b82828239805160001a60731461001957fe5b30600052607381538281f3fe730000000000000000000000000000000000000000301460806040526004361061006c5760003560e01c806317e142d1146100715780634c60db9c146100af578063732a2ccf146100ea578063bc2b405c14610116578063d1aa9e7e14610155578063deb3d89614610194575b600080fd5b61009d6004803603604081101561008757600080fd5b50803590602001356001600160a01b03166101b1565b60408051918252519081900360200190f35b8180156100bb57600080fd5b506100e8600480360360408110156100d257600080fd5b50803590602001356001600160a01b03166101ff565b005b61009d6004803603604081101561010057600080fd5b50803590602001356001600160a01b031661031e565b81801561012257600080fd5b506100e86004803603606081101561013957600080fd5b508035906001600160a01b03602082013516906040013561033d565b6101786004803603604081101561016b57600080fd5b50803590602001356103e7565b604080516001600160a01b039092168252519081900360200190f35b61009d600480360360208110156101aa57600080fd5b5035610414565b6001600160a01b038116600090815260038301602052604081205460ff166101dc57506000196101f9565b506001600160a01b03811660009081526002830160205260409020545b92915050565b6001600160a01b038116600090815260038301602052604090205460ff166102265761031a565b6001600160a01b03811660009081526003830160209081526040808320805460ff19169055600185018252808320839055600285019091528120548354909160001982019185908390811061027757fe5b60009182526020808320909101546001600160a01b039081168084526002890190925260408084208790559087168352822091909155855490915081908690859081106102c057fe5b600091825260209091200180546001600160a01b0319166001600160a01b039290921691909117905584548590806102f457fe5b600082815260209020810160001990810180546001600160a01b03191690550190555050505b5050565b6001600160a01b03166000908152600191909101602052604090205490565b6001600160a01b038216600090815260038401602052604090205460ff1615610382576001600160a01b038216600090815260018401602052604090208190556103e2565b6001600160a01b03821660008181526003850160209081526040808320805460ff19166001908117909155878101835281842086905587546002890184529184208290558101875586835291200180546001600160a01b03191690911790555b505050565b60008260000182815481106103f857fe5b6000918252602090912001546001600160a01b03169392505050565b549056fea26469706673582212201febe77a818490b5ae22a3137757ff371694cd2aea9c1dd9a28241c07d06959064736f6c634300060c0033
Deployed Bytecode
0x73e3dfd76a146d8df416e497369ee439b3a2c71491301460806040526004361061006c5760003560e01c806317e142d1146100715780634c60db9c146100af578063732a2ccf146100ea578063bc2b405c14610116578063d1aa9e7e14610155578063deb3d89614610194575b600080fd5b61009d6004803603604081101561008757600080fd5b50803590602001356001600160a01b03166101b1565b60408051918252519081900360200190f35b8180156100bb57600080fd5b506100e8600480360360408110156100d257600080fd5b50803590602001356001600160a01b03166101ff565b005b61009d6004803603604081101561010057600080fd5b50803590602001356001600160a01b031661031e565b81801561012257600080fd5b506100e86004803603606081101561013957600080fd5b508035906001600160a01b03602082013516906040013561033d565b6101786004803603604081101561016b57600080fd5b50803590602001356103e7565b604080516001600160a01b039092168252519081900360200190f35b61009d600480360360208110156101aa57600080fd5b5035610414565b6001600160a01b038116600090815260038301602052604081205460ff166101dc57506000196101f9565b506001600160a01b03811660009081526002830160205260409020545b92915050565b6001600160a01b038116600090815260038301602052604090205460ff166102265761031a565b6001600160a01b03811660009081526003830160209081526040808320805460ff19169055600185018252808320839055600285019091528120548354909160001982019185908390811061027757fe5b60009182526020808320909101546001600160a01b039081168084526002890190925260408084208790559087168352822091909155855490915081908690859081106102c057fe5b600091825260209091200180546001600160a01b0319166001600160a01b039290921691909117905584548590806102f457fe5b600082815260209020810160001990810180546001600160a01b03191690550190555050505b5050565b6001600160a01b03166000908152600191909101602052604090205490565b6001600160a01b038216600090815260038401602052604090205460ff1615610382576001600160a01b038216600090815260018401602052604090208190556103e2565b6001600160a01b03821660008181526003850160209081526040808320805460ff19166001908117909155878101835281842086905587546002890184529184208290558101875586835291200180546001600160a01b03191690911790555b505050565b60008260000182815481106103f857fe5b6000918252602090912001546001600160a01b03169392505050565b549056fea26469706673582212201febe77a818490b5ae22a3137757ff371694cd2aea9c1dd9a28241c07d06959064736f6c634300060c0033
Deployed Bytecode Sourcemap
0:1756:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;387:234;;;;;;;;;;;;;;;;-1:-1:-1;387:234:0;;;;;;-1:-1:-1;;;;;387:234:0;;:::i;:::-;;;;;;;;;;;;;;;;1274:479;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;1274:479:0;;;;;;-1:-1:-1;;;;;1274:479:0;;:::i;:::-;;265:114;;;;;;;;;;;;;;;;-1:-1:-1;265:114:0;;;;;;-1:-1:-1;;;;;265:114:0;;:::i;905:361::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;905:361:0;;;-1:-1:-1;;;;;905:361:0;;;;;;;;;;:::i;629:158::-;;;;;;;;;;;;;;;;-1:-1:-1;629:158:0;;;;;;;:::i;:::-;;;;-1:-1:-1;;;;;629:158:0;;;;;;;;;;;;;;795:102;;;;;;;;;;;;;;;;-1:-1:-1;795:102:0;;:::i;387:234::-;-1:-1:-1;;;;;517:17:0;;488:6;517:17;;;:12;;;:17;;;;;;;;512:60;;-1:-1:-1;;;551:9:0;;512:60;-1:-1:-1;;;;;;596:16:0;;;;;;:11;;;:16;;;;;;387:234;;;;;:::o;1274:479::-;-1:-1:-1;;;;;1343:17:0;;;;;;:12;;;:17;;;;;;;;1338:57;;1377:7;;1338:57;-1:-1:-1;;;;;1414:17:0;;;;;;:12;;;:17;;;;;;;;1407:24;;-1:-1:-1;;1407:24:0;;;;1449:10;;:15;;;;;1442:22;;;1493:11;;;:16;;;;;;1540:15;;1493:16;;-1:-1:-1;;1540:19:0;;;1414:3;;1540:19;;1588;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;1588:19:0;;;1620:20;;;:11;;;:20;;;;;;;:28;;;1666:16;;;;;;;1659:23;;;;1695:15;;1588:19;;-1:-1:-1;1588:19:0;;1620:3;;1643:5;;1695:15;;;;;;;;;;;;;;;:25;;-1:-1:-1;;;;;;1695:25:0;-1:-1:-1;;;;;1695:25:0;;;;;;;;;;1731:14;;;;;;;;;;;;;;;;;;-1:-1:-1;;1731:14:0;;;;;-1:-1:-1;;;;;;1731:14:0;;;;;;-1:-1:-1;;;1274:479:0;;;:::o;265:114::-;-1:-1:-1;;;;;356:15:0;329:7;356:15;;;:10;;;;;:15;;;;;;;265:114::o;905:361::-;-1:-1:-1;;;;;1017:17:0;;;;;;:12;;;:17;;;;;;;;1013:246;;;-1:-1:-1;;;;;1051:15:0;;;;;;:10;;;:15;;;;;:21;;;1013:246;;;-1:-1:-1;;;;;1105:17:0;;;;;;:12;;;:17;;;;;;;;:24;;-1:-1:-1;;1105:24:0;1125:4;1105:24;;;;;;1144:10;;;:15;;;;;:21;;;1199:15;;1180:11;;;:16;;;;;:34;;;1229:18;;;;;;;;;;;;-1:-1:-1;;;;;;1229:18:0;;;;;;1013:246;905:361;;;:::o;629:158::-;732:7;764:3;:8;;773:5;764:15;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;764:15:0;;629:158;-1:-1:-1;;;629:158:0:o;795:102::-;874:15;;795:102::o
Swarm Source
ipfs://1febe77a818490b5ae22a3137757ff371694cd2aea9c1dd9a28241c07d069590
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.