Browsable ATLAS Transformation Language Grammar

CC-BY

Grammar extracted by Vadim Zaytsev, see the Grammar Zoo entry for details: atl/atl/extracted
Source used for this grammar: Frédéric Jouault, ATL.ecore, 2007/07/26

Summary

Syntax

LocatedElement ::=
	Unit
LocatedElement ::=
	ModuleElement
LocatedElement ::=
	InPattern
LocatedElement ::=
	OutPattern
LocatedElement ::=
	Binding
LocatedElement ::=
	LibraryRef
LocatedElement ::=
	ActionBlock
LocatedElement ::=
	Statement
LocatedElement ::=
	OclExpression
LocatedElement ::=
	MapElement
LocatedElement ::=
	VariableDeclaration
LocatedElement ::=
	TupleTypeAttribute
LocatedElement ::=
	OclFeatureDefinition
LocatedElement ::=
	OclContextDefinition
LocatedElement ::=
	OclFeature
LocatedElement ::=
	OclModel
Unit ::=
	Library
Unit ::=
	Query
Unit ::=
	Module
Unit ::=
	[libraries]::LibraryRef+ [name]::String
Library ::=
	[helpers]::Helper+
Query ::=
	[body]::OclExpression [helpers]::Helper+
Module ::=
	[isRefining]::Boolean [inModels]::OclModel+ [outModels]::OclModel+ [elements]::ModuleElement+
ModuleElement ::=
	Helper
ModuleElement ::=
	Rule
Helper ::=
	[query]::Query [library]::Library [definition]::OclFeatureDefinition
Rule ::=
	MatchedRule
Rule ::=
	CalledRule
MatchedRule ::=
	LazyMatchedRule
MatchedRule ::=
	[inPattern]::InPattern [children]::MatchedRule+ [superRule]::MatchedRule [isAbstract]::Boolean [isRefining]::Boolean [isNoDefault]::Boolean
LazyMatchedRule ::=
	[isUnique]::Boolean
CalledRule ::=
	[parameters]::Parameter+ [isEntrypoint]::Boolean [isEndpoint]::Boolean
InPattern ::=
	[elements]::InPatternElement+ [rule]::MatchedRule [filter]::OclExpression
OutPattern ::=
	[rule]::Rule [elements]::OutPatternElement+
PatternElement ::=
	InPatternElement
PatternElement ::=
	OutPatternElement
InPatternElement ::=
	SimpleInPatternElement
SimpleInPatternElement ::=
	[mapsTo]::OutPatternElement [inPattern]::InPattern [models]::OclModel+
OutPatternElement ::=
	SimpleOutPatternElement
OutPatternElement ::=
	ForEachOutPatternElement
SimpleOutPatternElement ::=
	[reverseBindings]::OclExpression+
ForEachOutPatternElement ::=
	[collection]::OclExpression [iterator]::Iterator
Binding ::=
	[value]::OclExpression [outPatternElement]::OutPatternElement [propertyName]::String [isAssignment]::Boolean
RuleVariableDeclaration ::=
	[rule]::Rule
LibraryRef ::=
	[unit]::Unit [name]::String
ActionBlock ::=
	[rule]::Rule [statements]::Statement+
Statement ::=
	ExpressionStat
Statement ::=
	BindingStat
Statement ::=
	IfStat
Statement ::=
	ForStat
ExpressionStat ::=
	[expression]::OclExpression
BindingStat ::=
	[source]::OclExpression [propertyName]::String [isAssignment]::Boolean [value]::OclExpression
IfStat ::=
	[condition]::OclExpression [thenStatements]::Statement+ [elseStatements]::Statement+
ForStat ::=
	[iterator]::Iterator [collection]::OclExpression [statements]::Statement+
OclExpression ::=
	VariableExp
OclExpression ::=
	SuperExp
OclExpression ::=
	PrimitiveExp
OclExpression ::=
	CollectionExp
OclExpression ::=
	TupleExp
OclExpression ::=
	MapExp
OclExpression ::=
	EnumLiteralExp
OclExpression ::=
	OclUndefinedExp
OclExpression ::=
	PropertyCallExp
OclExpression ::=
	LetExp
OclExpression ::=
	IfExp
OclExpression ::=
	OclType
VariableExp ::=
	[referredVariable]::VariableDeclaration
SuperExp ::=
	[type]::OclType [ifExp3]::IfExp [appliedProperty]::PropertyCallExp [collection]::CollectionExp [letExp]::LetExp [loopExp]::LoopExp [parentOperation]::OperationCallExp [initializedVariable]::VariableDeclaration [ifExp2]::IfExp [owningOperation]::Operation [ifExp1]::IfExp [owningAttribute]::Attribute
PrimitiveExp ::=
	StringExp
PrimitiveExp ::=
	BooleanExp
PrimitiveExp ::=
	NumericExp
StringExp ::=
	[stringSymbol]::String
BooleanExp ::=
	[booleanSymbol]::Boolean
NumericExp ::=
	RealExp
NumericExp ::=
	IntegerExp
RealExp ::=
	[realSymbol]::Double
IntegerExp ::=
	[integerSymbol]::Integer
CollectionExp ::=
	BagExp
CollectionExp ::=
	OrderedSetExp
CollectionExp ::=
	SequenceExp
CollectionExp ::=
	SetExp
BagExp ::=
	[elements]::OclExpression+
OrderedSetExp ::=
	[elements]::OclExpression+
SequenceExp ::=
	[elements]::OclExpression+
SetExp ::=
	[elements]::OclExpression+
TupleExp ::=
	[tuplePart]::TuplePart+
TuplePart ::=
	[tuple]::TupleExp
MapExp ::=
	[elements]::MapElement+
MapElement ::=
	[map]::MapExp [key]::OclExpression [value]::OclExpression
EnumLiteralExp ::=
	[name]::String
OclUndefinedExp ::=
	[type]::OclType [ifExp3]::IfExp [appliedProperty]::PropertyCallExp [collection]::CollectionExp [letExp]::LetExp [loopExp]::LoopExp [parentOperation]::OperationCallExp [initializedVariable]::VariableDeclaration [ifExp2]::IfExp [owningOperation]::Operation [ifExp1]::IfExp [owningAttribute]::Attribute
PropertyCallExp ::=
	NavigationOrAttributeCallExp
PropertyCallExp ::=
	OperationCallExp
PropertyCallExp ::=
	LoopExp
NavigationOrAttributeCallExp ::=
	[name]::String
OperationCallExp ::=
	OperatorCallExp
OperationCallExp ::=
	CollectionOperationCallExp
OperationCallExp ::=
	[arguments]::OclExpression+ [operationName]::String
OperatorCallExp ::=
	[arguments]::OclExpression+ [operationName]::String
CollectionOperationCallExp ::=
	[arguments]::OclExpression+ [operationName]::String
LoopExp ::=
	IterateExp
LoopExp ::=
	IteratorExp
IterateExp ::=
	[result]::VariableDeclaration
IteratorExp ::=
	[name]::String
LetExp ::=
	[variable]::VariableDeclaration [in_]::OclExpression
IfExp ::=
	[thenExpression]::OclExpression [condition]::OclExpression [elseExpression]::OclExpression
VariableDeclaration ::=
	PatternElement
VariableDeclaration ::=
	RuleVariableDeclaration
VariableDeclaration ::=
	TuplePart
VariableDeclaration ::=
	Iterator
VariableDeclaration ::=
	Parameter
VariableDeclaration ::=
	[id]::String [varName]::String [type]::OclType [initExpression]::OclExpression [letExp]::LetExp [baseExp]::IterateExp [variableExp]::VariableExp+
Iterator ::=
	[loopExpr]::LoopExp
Parameter ::=
	[operation]::Operation
CollectionType ::=
	BagType
CollectionType ::=
	OrderedSetType
CollectionType ::=
	SequenceType
CollectionType ::=
	SetType
CollectionType ::=
	[elementType]::OclType
OclType ::=
	CollectionType
OclType ::=
	Primitive
OclType ::=
	OclAnyType
OclType ::=
	TupleType
OclType ::=
	OclModelElement
OclType ::=
	MapType
OclType ::=
	[name]::String [definitions]::OclContextDefinition [oclExpression]::OclExpression [operation]::Operation [mapType2]::MapType [attribute]::Attribute [mapType]::MapType [collectionTypes]::CollectionType [tupleTypeAttribute]::TupleTypeAttribute [variableDeclaration]::VariableDeclaration
Primitive ::=
	StringType
Primitive ::=
	BooleanType
Primitive ::=
	NumericType
StringType ::=
	ε
BooleanType ::=
	ε
NumericType ::=
	IntegerType
NumericType ::=
	RealType
IntegerType ::=
	ε
RealType ::=
	ε
BagType ::=
	[elementType]::OclType
OrderedSetType ::=
	[elementType]::OclType
SequenceType ::=
	[elementType]::OclType
SetType ::=
	[elementType]::OclType
OclAnyType ::=
	[name]::String [definitions]::OclContextDefinition [oclExpression]::OclExpression [operation]::Operation [mapType2]::MapType [attribute]::Attribute [mapType]::MapType [collectionTypes]::CollectionType [tupleTypeAttribute]::TupleTypeAttribute [variableDeclaration]::VariableDeclaration
TupleType ::=
	[attributes]::TupleTypeAttribute+
TupleTypeAttribute ::=
	[type]::OclType [tupleType]::TupleType [name]::String
OclModelElement ::=
	[model]::OclModel
MapType ::=
	[valueType]::OclType [keyType]::OclType
OclFeatureDefinition ::=
	[feature]::OclFeature [context_]::OclContextDefinition
OclContextDefinition ::=
	[definition]::OclFeatureDefinition [context_]::OclType
OclFeature ::=
	Attribute
OclFeature ::=
	Operation
Attribute ::=
	[name]::String [initExpression]::OclExpression [type]::OclType
Operation ::=
	[name]::String [parameters]::Parameter+ [returnType]::OclType [body]::OclExpression
OclModel ::=
	[name]::String [metamodel]::OclModel [elements]::OclModelElement+ [model]::OclModel+
Boolean ::=
	"true"
	"false"
Integer ::=
	integer
String ::=
	string

GrammarLabMaintained by Dr. Vadim Zaytsev a.k.a. @grammarware. Last updated in September 2015. []