Barretenberg
The ZK-SNARK library at the core of Aztec
Loading...
Searching...
No Matches
gas_tracker.hpp
Go to the documentation of this file.
1
#pragma once
2
3
#include "
barretenberg/vm2/common/aztec_types.hpp
"
4
5
namespace
bb::avm2::simulation
{
6
7
class
GasTrackerInterface
{
8
public
:
9
virtual
~GasTrackerInterface
() =
default
;
10
// @throws OutOfGasException.
11
virtual
void
consume_gas
(
const
Gas
& dynamic_gas_factor = { 0, 0 }) = 0;
12
13
virtual
Gas
compute_gas_limit_for_call
(
const
Gas
& allocated_gas) = 0;
14
};
15
16
}
// namespace bb::avm2::simulation
aztec_types.hpp
bb::avm2::simulation::GasTrackerInterface
Definition
gas_tracker.hpp:7
bb::avm2::simulation::GasTrackerInterface::~GasTrackerInterface
virtual ~GasTrackerInterface()=default
bb::avm2::simulation::GasTrackerInterface::consume_gas
virtual void consume_gas(const Gas &dynamic_gas_factor={ 0, 0 })=0
bb::avm2::simulation::GasTrackerInterface::compute_gas_limit_for_call
virtual Gas compute_gas_limit_for_call(const Gas &allocated_gas)=0
bb::avm2::simulation
Definition
address_derivation_event.hpp:6
bb::avm2::Gas
Definition
aztec_types.hpp:175
src
barretenberg
vm2
simulation
interfaces
gas_tracker.hpp
Generated by
1.9.8