Package org.eclipse.m2m.atl.engine.vm
Class ASMOperation
- java.lang.Object
-
- org.eclipse.m2m.atl.engine.vm.nativelib.ASMNativeObject
-
- org.eclipse.m2m.atl.engine.vm.nativelib.ASMOclAny
-
- org.eclipse.m2m.atl.engine.vm.Operation
-
- org.eclipse.m2m.atl.engine.vm.ASMOperation
-
public class ASMOperation extends Operation
The line number table contains a list of IDs (startLine:startColumn-endLine:endColumn) of source elements associated to a range of asm instructions. This list is depth first (first the condition is found, then the if). However, it is entered root first... so it is a LIFO. To find the source element (and its location, IDs being positions) associated to an asm instruction, we just have to find the first range matching the instruction.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected classASMOperation.LabelclassASMOperation.LineNumberEntryclassASMOperation.LocalVariableEntry
-
Field Summary
Fields Modifier and Type Field Description static ASMOclTypemyType-
Fields inherited from class org.eclipse.m2m.atl.engine.vm.nativelib.ASMNativeObject
nativeImpl
-
-
Constructor Summary
Constructors Constructor Description ASMOperation(ASM asm, java.lang.String name)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddInstruction(ASMInstruction instruction)voidaddLabel(java.lang.String labelName)voidaddLabeledInstruction(ASMInstructionWithOperand instruction, java.lang.String labelName)voidaddLineNumberEntry(java.lang.String id, int begin, int end)voidaddLocalVariableEntry(int slot, java.lang.String name, int begin, int end)voidaddParameter(ASMParameter parameter)voidaddVariableInstruction(ASMInstructionWithOperand instruction, java.lang.String varId)voidbeginLineNumberEntry(java.lang.String id)intbeginLocalVariableEntry(java.lang.String id, java.lang.String name)voidendLineNumberEntry(java.lang.String id)intendLocalVariableEntry(java.lang.String id)ASMOclAnyexec(StackFrame frame)ASMgetASM()java.lang.StringgetContextSignature()ASMOclTypegetContextType()java.util.ListgetInstructions()java.util.ListgetLineNumberTable()java.util.ListgetLocalVariableTable()java.lang.StringgetName()java.util.ListgetParameters()ASMOclTypegetReturnType()java.lang.StringgetSignature()java.lang.StringresolveLineNumber(int l)java.lang.StringresolveVariableName(int slot, int l)voidsetContext(java.lang.String context)voidsetContextType(ASMOclType contextType)java.lang.StringtoString()-
Methods inherited from class org.eclipse.m2m.atl.engine.vm.nativelib.ASMOclAny
asBag, asSequence, asSet, check, debug, findOperation, findOperation, getHelper, getNamedTargetFromSource, getOclAnyType, getType, invoke, invoke, invokeSuper, isHelper, oclIsKindOf, oclIsTypeOf, oclIsUndefined, oclType, operatorEQ, operatorNE, output, refGetValue, refImmediateComposite, refImmediateComposite, refInvokeOperation, refSetValue, refUnsetValue, set, setType, toString, unset
-
Methods inherited from class org.eclipse.m2m.atl.engine.vm.nativelib.ASMNativeObject
getNativeImpl
-
-
-
-
Field Detail
-
myType
public static ASMOclType myType
-
-
Constructor Detail
-
ASMOperation
public ASMOperation(ASM asm, java.lang.String name)
-
-
Method Detail
-
setContext
public void setContext(java.lang.String context)
-
getContextSignature
public java.lang.String getContextSignature()
- Specified by:
getContextSignaturein classOperation
-
addParameter
public void addParameter(ASMParameter parameter)
-
getParameters
public java.util.List getParameters()
- Specified by:
getParametersin classOperation
-
addInstruction
public void addInstruction(ASMInstruction instruction)
-
addLabeledInstruction
public void addLabeledInstruction(ASMInstructionWithOperand instruction, java.lang.String labelName)
-
getInstructions
public java.util.List getInstructions()
-
addLabel
public void addLabel(java.lang.String labelName)
-
addVariableInstruction
public void addVariableInstruction(ASMInstructionWithOperand instruction, java.lang.String varId)
-
getSignature
public java.lang.String getSignature()
- Specified by:
getSignaturein classOperation
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
exec
public ASMOclAny exec(StackFrame frame)
-
beginLineNumberEntry
public void beginLineNumberEntry(java.lang.String id)
-
endLineNumberEntry
public void endLineNumberEntry(java.lang.String id)
-
addLineNumberEntry
public void addLineNumberEntry(java.lang.String id, int begin, int end)
-
getLineNumberTable
public java.util.List getLineNumberTable()
-
resolveLineNumber
public java.lang.String resolveLineNumber(int l)
-
beginLocalVariableEntry
public int beginLocalVariableEntry(java.lang.String id, java.lang.String name)
-
endLocalVariableEntry
public int endLocalVariableEntry(java.lang.String id)
-
addLocalVariableEntry
public void addLocalVariableEntry(int slot, java.lang.String name, int begin, int end)
-
getLocalVariableTable
public java.util.List getLocalVariableTable()
-
resolveVariableName
public java.lang.String resolveVariableName(int slot, int l)
-
getASM
public ASM getASM()
-
setContextType
public void setContextType(ASMOclType contextType)
-
getReturnType
public ASMOclType getReturnType()
- Specified by:
getReturnTypein classOperation
-
getContextType
public ASMOclType getContextType()
- Specified by:
getContextTypein classOperation
-
-