⚠️ ⚠️ ⚠️ This explorer will be deprecated soon, please use PolygonScan.com

Contract Address Details

0x6C7256cf7C003dD85683339F75DdE9971f98f2FD

InstaMemory Last Balance Update: Block #15676292
Created by 0xf68390–47c21e at 0xcb100a–65ec17

Balance

0 MATIC

(@ /MATIC)

Fetching tokens...

Contract name:
InstaMemory




Optimization enabled
false
Compiler version
v0.7.0+commit.9e61f92b




EVM Version
default

Contract source code

/**
* Submitted for verification at blockscout.com on 2021-04-03 00:29:35.564967Z
*/
// Sources flattened with hardhat v2.0.8 https://hardhat.org
// File contracts/v1/memory.sol
pragma solidity ^0.7.0;
/**
* @title InstaMemory.
* @dev Store Data For Cast Function.
*/
contract InstaMemory {
// Memory Bytes (Smart Account Address => Storage ID => Bytes).
mapping (address => mapping (uint => bytes32)) internal mbytes; // Use it to store execute data and delete in the same transaction
// Memory Uint (Smart Account Address => Storage ID => Uint).
mapping (address => mapping (uint => uint)) internal muint; // Use it to store execute data and delete in the same transaction
// Memory Address (Smart Account Address => Storage ID => Address).
mapping (address => mapping (uint => address)) internal maddr; // Use it to store execute data and delete in the same transaction
/**
* @dev Store Bytes.
* @param _id Storage ID.
* @param _byte bytes data to store.
*/
function setBytes(uint _id, bytes32 _byte) public {
mbytes[msg.sender][_id] = _byte;
}
/**
* @dev Get Stored Bytes.
* @param _id Storage ID.
*/
function getBytes(uint _id) public returns (bytes32 _byte) {
_byte = mbytes[msg.sender][_id];
delete mbytes[msg.sender][_id];
}
/**
* @dev Store Uint.
* @param _id Storage ID.
* @param _num uint data to store.
*/
function setUint(uint _id, uint _num) public {
muint[msg.sender][_id] = _num;
}
/**
* @dev Get Stored Uint.
* @param _id Storage ID.
*/
function getUint(uint _id) public returns (uint _num) {
_num = muint[msg.sender][_id];
delete muint[msg.sender][_id];
}
/**
* @dev Store Address.
* @param _id Storage ID.
* @param _addr Address data to store.
*/
function setAddr(uint _id, address _addr) public {
maddr[msg.sender][_id] = _addr;
}
/**
* @dev Get Stored Address.
* @param _id Storage ID.
*/
function getAddr(uint _id) public returns (address _addr) {
_addr = maddr[msg.sender][_id];
delete maddr[msg.sender][_id];
}
}

Contract ABI

[{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"address","name":"_addr","internalType":"address"}],"name":"getAddr","inputs":[{"type":"uint256","name":"_id","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bytes32","name":"_byte","internalType":"bytes32"}],"name":"getBytes","inputs":[{"type":"uint256","name":"_id","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"uint256","name":"_num","internalType":"uint256"}],"name":"getUint","inputs":[{"type":"uint256","name":"_id","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setAddr","inputs":[{"type":"uint256","name":"_id","internalType":"uint256"},{"type":"address","name":"_addr","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setBytes","inputs":[{"type":"uint256","name":"_id","internalType":"uint256"},{"type":"bytes32","name":"_byte","internalType":"bytes32"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setUint","inputs":[{"type":"uint256","name":"_id","internalType":"uint256"},{"type":"uint256","name":"_num","internalType":"uint256"}]}]
            

Contract Byte Code

0x608060405234801561001057600080fd5b50600436106100625760003560e01c8063455ded9e1461006757806357bc2ef31461009f57806361e3c944146100e1578063a9c70eaa14610119578063d81f84b71461015b578063eba36dbd146101b3575b600080fd5b61009d6004803603604081101561007d57600080fd5b810190808035906020019092919080359060200190929190505050610201565b005b6100cb600480360360208110156100b557600080fd5b8101908080359060200190929190505050610259565b6040518082815260200191505060405180910390f35b610117600480360360408110156100f757600080fd5b810190808035906020019092919080359060200190929190505050610305565b005b6101456004803603602081101561012f57600080fd5b810190808035906020019092919050505061035e565b6040518082815260200191505060405180910390f35b6101876004803603602081101561017157600080fd5b810190808035906020019092919050505061040c565b604051808273ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6101ff600480360360408110156101c957600080fd5b8101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506104f9565b005b806000803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000848152602001908152602001600020819055505050565b60008060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008381526020019081526020016000205490506000803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002060009055919050565b80600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000848152602001908152602001600020819055505050565b6000600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000838152602001908152602001600020549050600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002060009055919050565b6000600260003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050600260003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002060006101000a81549073ffffffffffffffffffffffffffffffffffffffff0219169055919050565b80600260003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550505056fea26469706673582212204dd54f6b35f8771f63c5a0d2af1d85acdab729006864315a75938a3cb446061364736f6c63430007000033