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:
OneETHPriceOracle
Compiler Version
v0.8.21+commit.d9974bed
Optimization Enabled:
Yes with 10000 runs
Other Settings:
shanghai EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.21; import { UtilLib } from "../utils/UtilLib.sol"; import { IPriceFetcher } from "../interfaces/IPriceFetcher.sol"; /// @title OneETHPriceOracle Contract /// @notice contract that returns 1e18 as the exchange rate of asset/ETH contract OneETHPriceOracle is IPriceFetcher { /// @return assetPrice 1e18 as the exchange rate of asset/ETH function getAssetPrice(address) external pure returns (uint256) { return 1e18; } }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.21; /// @title UtilLib - Utility library /// @notice Utility functions library UtilLib { error ZeroAddressNotAllowed(); /// @dev zero address check modifier /// @param address_ address to check function checkNonZeroAddress(address address_) internal pure { if (address_ == address(0)) revert ZeroAddressNotAllowed(); } }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.21; interface IPriceFetcher { function getAssetPrice(address asset) external view returns (uint256); }
{ "remappings": [ "ds-test/=lib/forge-std/lib/ds-test/src/", "forge-std/=lib/forge-std/src/", "@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/", "@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/", "erc4626-tests/=lib/openzeppelin-contracts-upgradeable/lib/erc4626-tests/", "eth-gas-reporter/=node_modules/eth-gas-reporter/", "hardhat/=node_modules/hardhat/", "openzeppelin-contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/", "openzeppelin-contracts/=lib/openzeppelin-contracts/", "openzeppelin/=lib/openzeppelin-contracts-upgradeable/contracts/", "solidity-code-metrics/=node_modules/solidity-code-metrics/" ], "optimizer": { "enabled": true, "runs": 10000 }, "metadata": { "useLiteralContent": false, "bytecodeHash": "ipfs", "appendCBOR": true }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "evmVersion": "shanghai", "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"getAssetPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"}]
Contract Creation Code
608060405234801561000f575f80fd5b5060c28061001c5f395ff3fe6080604052348015600e575f80fd5b50600436106026575f3560e01c8063b3596f0714602a575b5f80fd5b604260353660046054565b50670de0b6b3a764000090565b60405190815260200160405180910390f35b5f602082840312156063575f80fd5b813573ffffffffffffffffffffffffffffffffffffffff811681146085575f80fd5b939250505056fea2646970667358221220d1a8b611849eb97dfa6a02d70289f3a956bcf2331039aeb130fff6aa5dac6d0764736f6c63430008150033
Deployed Bytecode
0x6080604052348015600e575f80fd5b50600436106026575f3560e01c8063b3596f0714602a575b5f80fd5b604260353660046054565b50670de0b6b3a764000090565b60405190815260200160405180910390f35b5f602082840312156063575f80fd5b813573ffffffffffffffffffffffffffffffffffffffff811681146085575f80fd5b939250505056fea2646970667358221220d1a8b611849eb97dfa6a02d70289f3a956bcf2331039aeb130fff6aa5dac6d0764736f6c63430008150033
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.