![]() |
Ethereum
PoC-8
The C++ Implementation of Ethereum
|
Externality interface for the Virtual Machine providing access to world state. More...
#include <ExtVM.h>
Public Member Functions | |
| ExtVM (State &_s, EnvInfo const &_envInfo, SealEngineFace const &_sealEngine, Address _myAddress, Address _caller, Address _origin, u256 _value, u256 _gasPrice, bytesConstRef _data, bytesConstRef _code, h256 const &_codeHash, unsigned _depth, bool _isCreate, bool _staticCall) | |
| Full constructor. More... | |
| u256 | store (u256 _n) final |
| Read storage location. More... | |
| void | setStore (u256 _n, u256 _v) final |
| Write a value in storage. More... | |
| u256 | originalStorageValue (u256 const &_key) final |
| Read original storage value (before modifications in the current transaction). More... | |
| bytes const & | codeAt (Address _a) final |
| Read address's code. More... | |
| size_t | codeSizeAt (Address _a) final |
| h256 | codeHashAt (Address _a) final |
| CreateResult | create (u256 _endowment, u256 &io_gas, bytesConstRef _code, Instruction _op, u256 _salt, OnOpFunc const &_onOp={}) final |
| Create a new contract. More... | |
| CallResult | call (CallParameters &_params) final |
| Create a new message call. More... | |
| u256 | balance (Address _a) final |
| Read address's balance. More... | |
| bool | exists (Address _a) final |
| Does the account exist? More... | |
| void | suicide (Address _a) final |
| Suicide the associated contract to the given address. More... | |
| EVMSchedule const & | evmSchedule () const final |
| Return the EVM gas-price schedule for this execution context. More... | |
| State const & | state () const |
| h256 | blockHash (u256 _number) final |
| Hash of a block if within the last 256 blocks, or h256() otherwise. More... | |
Public Member Functions inherited from dev::eth::ExtVMFace | |
| ExtVMFace (EnvInfo const &_envInfo, Address _myAddress, Address _caller, Address _origin, u256 _value, u256 _gasPrice, bytesConstRef _data, bytes _code, h256 const &_codeHash, unsigned _depth, bool _isCreate, bool _staticCall) | |
| Full constructor. More... | |
| virtual | ~ExtVMFace ()=default |
| ExtVMFace (ExtVMFace const &)=delete | |
| ExtVMFace & | operator= (ExtVMFace const &)=delete |
| virtual void | log (h256s &&_topics, bytesConstRef _data) |
| Revert any changes made (by any of the other calls). More... | |
| EnvInfo const & | envInfo () const |
| Get the execution environment information. More... | |
Additional Inherited Members | |
Public Attributes inherited from dev::eth::ExtVMFace | |
| Address | myAddress |
| Address associated with executing code (a contract, or contract-to-be). More... | |
| Address | caller |
| Address which sent the message (either equal to origin or a contract). More... | |
| Address | origin |
| Original transactor. More... | |
| u256 | value |
| Value (in Wei) that was passed to this address. More... | |
| u256 | gasPrice |
| Price of gas (that we already paid). More... | |
| bytesConstRef | data |
| Current input data. More... | |
| bytes | code |
| Current code that is executing. More... | |
| h256 | codeHash |
| SHA3 hash of the executing code. More... | |
| u256 | salt |
| Values used in new address construction by CREATE2. More... | |
| SubState | sub |
| Sub-band VM state (suicides, refund counter, logs). More... | |
| unsigned | depth = 0 |
| Depth of the present call. More... | |
| bool | isCreate = false |
| Is this a CREATE call? More... | |
| bool | staticCall = false |
| Throw on state changing. More... | |
Externality interface for the Virtual Machine providing access to world state.
|
inline |
Read address's balance.
Reimplemented from dev::eth::ExtVMFace.
Hash of a block if within the last 256 blocks, or h256() otherwise.
Implements dev::eth::ExtVMFace.
|
finalvirtual |
Create a new message call.
Implements dev::eth::ExtVMFace.
Reimplemented from dev::eth::ExtVMFace.
|
finalvirtual |
Reimplemented from dev::eth::ExtVMFace.
|
finalvirtual |
|
inlinefinalvirtual |
Return the EVM gas-price schedule for this execution context.
Reimplemented from dev::eth::ExtVMFace.
|
inlinefinalvirtual |
Does the account exist?
Reimplemented from dev::eth::ExtVMFace.
Read original storage value (before modifications in the current transaction).
Reimplemented from dev::eth::ExtVMFace.
Write a value in storage.
Reimplemented from dev::eth::ExtVMFace.
Read storage location.
Reimplemented from dev::eth::ExtVMFace.
|
finalvirtual |
Suicide the associated contract to the given address.
Reimplemented from dev::eth::ExtVMFace.