ALE (Action Language for EMF) is an interpreted language to define behaviors on the top of Ecore models and make them executable. Concretely, ALE allows to “re-open” EClasses with the aim of implementing existing EOperations and weaving new attributes or new operations.
- Executable metamodeling: re-open existing EClasses to insert new methods along with their implementations
- Metamodel extension: the very same mechanism can be used to extend existing Ecore metamodels and insert new features (e.g. attributes) in a non-intrusive way
- Quick iterations: no need to deploy Eclipse plugins, just execute a model directly in your modeling environment
- Extensibility: if ALE doesn’t fit your needs, register Java classes as services and invoke them inside your implementations of EOperations.
ALE allows to easily define the behavior of an Ecore model and to test it on the spot, right in your modeling environment. It is not production-ready yet but allows for quick iterations and fast feedbacks. As such it is ideal for prototyping a solution.
See the tutorials for concrete examples.
ALE is an interpreted, strongly typed an object-oriented language. It is based on AQL which means that any valid AQL expression is a valid ALE expression.
The following snippet is part of the Hello World example project and prints Hello World!
when executed:
behavior helloworld;
open class HelloWorld {
@main
override void greeting () {
'Hello World!'.log();
}
}
Please see the online documentation for an in-depth presentation of the language.
Show detailed instructions
- Open Eclipse IDE
- Go to Help > Install New Software...
- Copy the update site’s URL in the Work with textbox:
- Hit Enter and wait for the list to load
- Check Action Language for EMF
- Click Next then Finish
ALE can be installed from its update site: http://www.kermeta.org/ale-lang/updates/latest/
ℹ️ nightly resulting from the last successful build in the CI
ALE's website provides:
- a language overview (Hello World)
- a tutorial where you learn how to make a state machine executable
- a comprehensive guide of ALE's syntax
Requirements
- Maven 3.x
- Java 8 JDK
- Eclipse IDE for DSL Developers (latest release)
Import the projects in the IDE
- File > Import... > Team > Team Project Set
- Fill URL with "https://raw.githubusercontent.com/gemoc/ale-lang/master/eclipse-projectSet.psf"
- Click on Finish
Tip: use Working Sets for a better workspace organization:
- Open Project Explorer's menu > Top Level Elements > Working Sets
- Open Project Explorer's menu > Select Working Sets > Check "examples", "features", "plugins", "tests" and "releng"
Setup your dev environment
- Open the
org.eclipse.emf.ecoretools.ale.target-platform/org.eclipse.emf.ecoretools.ale.target-platform.target
file - Click on Set as Target Platform
- Wait for dependencies to be loaded (may take a while)
Technical documentation
ALE's architecture is presented in plugins/README.md; further documentation will be provided as soon as possible.
See the contributing guide for further details.
ALE is the result of research conducted at Inria's DiverSE team. It is used to define Domain-Specific Languages (DSLs): the Ecore model and the ALE source files being respectively the abstract syntax and the semantics of those DSLs.
See below for a list of related publications:
- Manuel Leduc, Thomas Degueule, Benoit Combemale, Tijs van der Storm, Olivier Barais
Revisiting Visitors for Modular Extension of Executable DSMLs
In 2017 ACM/IEEE 20th International Conference on Model Driven Engineering Languages and Systems (MODELS)
[Publication at IEEE Xplore Digital Library]