Package org.eclipse.m2m.atl.engine.vm

# Class ASMInterpreter

java.lang.Object
org.eclipse.m2m.atl.engine.vm.ASMInterpreter

public class ASMInterpreter extends Object
This Java class interprets ATL Stack Machine. Command-line Parameters are in the form `name=value`. In the following descriptions, parameters are typed.

- Boolean If the string value is "true" then the argument will be true, false otherwise.
- Listinvalid input: '&ltT'invalid input: '&gt' A List of T is a coma-separated list of T.
- ModelLocation The specification of the location of a model. The path to its serialized form. A ModelLocation can also specify an injector to be used.
- ModelSpec The specification of a model in the form `model-name : metamodel-name`. For each model and metamodel specified in a ModelSpec there must be a specification of how to load it (except for MOF). This specification is performed by specifying an additional command-line argument. The name of this argument is the name of the model or metamodel and its value is a ModelLocation.
- ModelPath `model-name=path-name`

Command-line parameters:

- ASM : File('.asm')
- copy : Boolean
- source-models : List(ModelSpec)
- target-models : List(ModelSpec)
- step : Boolean
- NetworkDebugger : Boolean
- testReserialization : Boolean when true, the ASM file is serialized in XML, text and binary
- reserialize : List(ModelPath) Specifies a list of models to serialize at the end of the execution of the program. This is especially usefull to reserialize source models that have been modified during the execution of the program (in-place transformations).
- plugins : List(File('.jar'))
- ModelLoader : Enumeration('EMF', 'MDR')

Operation signature encoding
Type | Encoding | Sample Type | Sample Type encoded
--- | --- | --- | ---
Object | J
Void | V
Integer | I
Boolean | B
String | S
Double | D
EnumLiteral | Z
ATL context Module | A
ModelElement | Minvalid input: '&ltmeta'-model-nameinvalid input: '&gt'!invalid input: '&ltelement'-name> | XML!Node | MXML!Node;
Model | L
Sequence(invalid input: '&lttype'invalid input: '&gt') | Qinvalid input: '&lttype'invalid input: '&gt' | Sequence(String) | QS
Bag(invalid input: '&lttype'invalid input: '&gt') | Ginvalid input: '&lttype'invalid input: '&gt'
Collection(invalid input: '&lttype'invalid input: '&gt') | Cinvalid input: '&lttype'invalid input: '&gt'
Set(invalid input: '&lttype'invalid input: '&gt') | Einvalid input: '&lttype'invalid input: '&gt'
OrderedSet(invalid input: '&lttype'invalid input: '&gt') | Oinvalid input: '&lttype'invalid input: '&gt'
Native type | Ninvalid input: '&ltname'invalid input: '&gt' | TransientLink | NTransientLink;
Tuple(name1:invalid input: '&lttype1'invalid input: '&gt',name2:invalid input: '&lttype2'invalid input: '&gt') | Tinvalid input: '&lttype1'>name1;invalid input: '&lttype2'invalid input: '&gt'>name2;; | Tuple(n:String,v:Integer) | TSn;Iv;;
|  | Tuple(m:XML!Node,b:Boolean) | TMXML!Node;m;Bb;;

Note: in Tuples, attribute order is not relevant: TIa;Ib;; and TIb;Ia;; denote the same TupleType

Sample method signature encodings
Signature | Encoding
--- | ---
context XML!Element def: getAttrVal(name : String) : String | MXML!Element;.getAttrVal(S):S
context String def: toBoolean() : Boolean | S.toBoolean():B
context String def: toIntegerFromRoman() : Integer | S.toIntegerFromRoman():I

## Constructor Summary

Constructors
Constructor
Description
`ASMInterpreter(ASM asm, ASMModule asmModule, ASMExecEnv env, Map params)`

## Method Summary

Modifier and Type
Method
Description
`ASMOclAny`
`getReturnValue()`
`static void`
`realMain(String[] args, PluginClassLoader pcl)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### ASMInterpreter

public ASMInterpreter(ASM asm, ASMModule asmModule, ASMExecEnv env, Map params)

## Method Details

### realMain

public static void realMain(String[] args, PluginClassLoader pcl) throws Exception

Throws:
  `Exception`

### getReturnValue

public ASMOclAny getReturnValue()