Class WasmLoadStoreInstruction
java.lang.Object
de.inetsoftware.jwebassembly.module.WasmInstruction
de.inetsoftware.jwebassembly.module.WasmLocalInstruction
de.inetsoftware.jwebassembly.module.WasmLoadStoreInstruction
WasmInstruction for load and store local variables.
-
Nested Class Summary
Nested classes/interfaces inherited from class WasmInstruction
WasmInstruction.Type -
Field Summary
Fields inherited from class WasmLocalInstruction
localVariables -
Constructor Summary
ConstructorsConstructorDescriptionWasmLoadStoreInstruction(VariableOperator op, int slot, LocaleVariableManager localVariables, int javaCodePos, int lineNumber) Create an instance of a load/store instruction -
Method Summary
Methods inherited from class WasmLocalInstruction
getOperator, getPopCount, getPopValueTypes, getPushValueType, getType, setOperator, writeToMethods inherited from class WasmInstruction
getCodePosition, getLineNumber, setCodePosition
-
Constructor Details
-
WasmLoadStoreInstruction
WasmLoadStoreInstruction(@Nonnull VariableOperator op, @Nonnegative int slot, LocaleVariableManager localVariables, int javaCodePos, int lineNumber) Create an instance of a load/store instruction- Parameters:
op- the operationslot- the memory/slot idx of the variablelocalVariables- the manager for local variablesjavaCodePos- the code position/offset in the Java methodlineNumber- the line number in the Java source code
-
-
Method Details
-
getIndex
int getIndex()Get the number of the locals- Overrides:
getIndexin classWasmLocalInstruction- Returns:
- the index, mostly the Wasm Index
-
getSlot
int getSlot()Get the slot of this variable from Java- Overrides:
getSlotin classWasmLocalInstruction- Returns:
- the slot
-