@@ -27,8 +27,8 @@ This class is an AsyncEventEmitter, please consult the README to learn how to us
27
27
28
28
### Methods
29
29
30
- * [ _ updateOpcodes] ( _index_.vm.md#_updateopcodes )
31
30
* [ copy] ( _index_.vm.md#copy )
31
+ * [ getActiveOpcodes] ( _index_.vm.md#getactiveopcodes )
32
32
* [ init] ( _index_.vm.md#init )
33
33
* [ runBlock] ( _index_.vm.md#runblock )
34
34
* [ runBlockchain] ( _index_.vm.md#runblockchain )
@@ -43,7 +43,7 @@ This class is an AsyncEventEmitter, please consult the README to learn how to us
43
43
44
44
\+ ** new VM** (` opts ` : [ VMOpts] ( ../interfaces/_index_.vmopts.md ) ): * [ VM] ( _index_.vm.md ) *
45
45
46
- * Defined in [ index.ts:139 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L139 ) *
46
+ * Defined in [ index.ts:147 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L147 ) *
47
47
48
48
Instantiates a new [ VM] ( _index_.vm.md ) Object.
49
49
@@ -61,15 +61,15 @@ Name | Type | Default | Description |
61
61
62
62
• ** _ common** : * Common*
63
63
64
- * Defined in [ index.ts:110 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L110 ) *
64
+ * Defined in [ index.ts:117 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L117 ) *
65
65
66
66
___
67
67
68
68
### blockchain
69
69
70
70
• ** blockchain** : * Blockchain*
71
71
72
- * Defined in [ index.ts:108 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L108 ) *
72
+ * Defined in [ index.ts:115 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L115 ) *
73
73
74
74
The blockchain the VM operates on
75
75
79
79
80
80
• ** stateManager** : * [ StateManager] ( ../interfaces/_state_index_.statemanager.md ) *
81
81
82
- * Defined in [ index.ts:104 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L104 ) *
82
+ * Defined in [ index.ts:111 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L111 ) *
83
83
84
84
The StateManager used by the VM
85
85
86
86
## Methods
87
87
88
- ### _ updateOpcodes
88
+ ### copy
89
89
90
- ▸ ** _ updateOpcodes ** (): * void *
90
+ ▸ ** copy ** (): * [ VM ] ( _index_.vm.md ) *
91
91
92
- * Defined in [ index.ts:219 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L219 ) *
92
+ * Defined in [ index.ts:343 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L343 ) *
93
93
94
- ** Returns:** * void*
94
+ Returns a copy of the [ VM] ( _index_.vm.md ) instance.
95
+
96
+ ** Returns:** * [ VM] ( _index_.vm.md ) *
95
97
96
98
___
97
99
98
- ### copy
100
+ ### getActiveOpcodes
99
101
100
- ▸ ** copy ** (): * [ VM ] ( _index_.vm.md ) *
102
+ ▸ ** getActiveOpcodes ** (): * OpcodeList *
101
103
102
- * Defined in [ index.ts:326 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L326 ) *
104
+ * Defined in [ index.ts:336 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L336 ) *
103
105
104
- Returns a copy of the [ VM] ( _index_.vm.md ) instance.
106
+ Returns a list with the currently activated opcodes
107
+ available for VM execution
105
108
106
- ** Returns:** * [ VM ] ( _index_.vm.md ) *
109
+ ** Returns:** * OpcodeList *
107
110
108
111
___
109
112
110
113
### init
111
114
112
115
▸ ** init** (): * Promise‹void›*
113
116
114
- * Defined in [ index.ts:223 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L223 ) *
117
+ * Defined in [ index.ts:232 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L232 ) *
115
118
116
119
** Returns:** * Promise‹void›*
117
120
121
124
122
125
▸ ** runBlock** (` opts ` : [ RunBlockOpts] ( ../interfaces/_runblock_.runblockopts.md ) ): * Promise‹[ RunBlockResult] ( ../interfaces/_runblock_.runblockresult.md ) ›*
123
126
124
- * Defined in [ index.ts:280 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L280 ) *
127
+ * Defined in [ index.ts:289 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L289 ) *
125
128
126
129
Processes the ` block ` running all of the transactions it contains and updating the miner's account
127
130
141
144
142
145
### runBlockchain
143
146
144
- ▸ ** runBlockchain** (` blockchain? ` : Blockchain): * Promise‹void›*
147
+ ▸ ** runBlockchain** (` blockchain? ` : Blockchain, ` maxBlocks? ` : undefined | number ): * Promise‹void | number ›*
145
148
146
- * Defined in [ index.ts:265 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L265 ) *
149
+ * Defined in [ index.ts:274 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L274 ) *
147
150
148
151
Processes blocks and adds them to the blockchain.
149
152
@@ -154,16 +157,17 @@ This method modifies the state.
154
157
Name | Type | Description |
155
158
------ | ------ | ------ |
156
159
` blockchain? ` | Blockchain | An [ @ethereumjs/blockchain ] ( https://github.com/ethereumjs/ethereumjs-vm/tree/master/packages/blockchain ) object to process |
160
+ ` maxBlocks? ` | undefined | ; number | - |
157
161
158
- ** Returns:** * Promise‹void›*
162
+ ** Returns:** * Promise‹void | number ›*
159
163
160
164
___
161
165
162
166
### runCall
163
167
164
- ▸ ** runCall** (` opts ` : [ RunCallOpts] ( ../interfaces/_runcall_.runcallopts.md ) ): * Promise‹[ EVMResult] ( ../interfaces/_evm_evm_.evmresult.md ) ›*
168
+ ▸ ** runCall** (` opts ` : [ RunCallOpts] ( ../interfaces/_runcall_.runcallopts.md ) ): * Promise‹EVMResult›*
165
169
166
- * Defined in [ index.ts:306 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L306 ) *
170
+ * Defined in [ index.ts:315 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L315 ) *
167
171
168
172
runs a call (or create) operation.
169
173
@@ -175,15 +179,15 @@ Name | Type | Description |
175
179
------ | ------ | ------ |
176
180
` opts ` | [ RunCallOpts] ( ../interfaces/_runcall_.runcallopts.md ) | |
177
181
178
- ** Returns:** * Promise‹[ EVMResult] ( ../interfaces/_evm_evm_.evmresult.md ) ›*
182
+ ** Returns:** * Promise‹EVMResult›*
179
183
180
184
___
181
185
182
186
### runCode
183
187
184
- ▸ ** runCode** (` opts ` : [ RunCodeOpts] ( ../interfaces/_runcode_.runcodeopts.md ) ): * Promise‹[ ExecResult] ( ../interfaces/_evm_evm_.execresult.md ) ›*
188
+ ▸ ** runCode** (` opts ` : [ RunCodeOpts] ( ../interfaces/_runcode_.runcodeopts.md ) ): * Promise‹ExecResult›*
185
189
186
- * Defined in [ index.ts:318 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L318 ) *
190
+ * Defined in [ index.ts:327 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L327 ) *
187
191
188
192
Runs EVM code.
189
193
@@ -195,15 +199,15 @@ Name | Type | Description |
195
199
------ | ------ | ------ |
196
200
` opts ` | [ RunCodeOpts] ( ../interfaces/_runcode_.runcodeopts.md ) | |
197
201
198
- ** Returns:** * Promise‹[ ExecResult] ( ../interfaces/_evm_evm_.execresult.md ) ›*
202
+ ** Returns:** * Promise‹ExecResult›*
199
203
200
204
___
201
205
202
206
### runTx
203
207
204
208
▸ ** runTx** (` opts ` : [ RunTxOpts] ( ../interfaces/_runtx_.runtxopts.md ) ): * Promise‹[ RunTxResult] ( ../interfaces/_runtx_.runtxresult.md ) ›*
205
209
206
- * Defined in [ index.ts:294 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L294 ) *
210
+ * Defined in [ index.ts:303 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L303 ) *
207
211
208
212
Process a transaction. Run the vm. Transfers eth. Checks balances.
209
213
225
229
226
230
▸ ** create** (` opts ` : [ VMOpts] ( ../interfaces/_index_.vmopts.md ) ): * Promise‹[ VM] ( _index_.vm.md ) ›*
227
231
228
- * Defined in [ index.ts:135 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L135 ) *
232
+ * Defined in [ index.ts:143 ] ( https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/vm/lib/index.ts#L143 ) *
229
233
230
234
VM async constructor. Creates engine instance and initializes it.
231
235
0 commit comments