Commit 6f3e761b authored by Philip Makedonski's avatar Philip Makedonski
Browse files

+some refinements to data label provider grammer (parameter binding)



Change-Id: I1cbf34288660cd601b66826836644151b38c0513
Signed-off-by: default avatarmakedonski <makedonski@informatik.uni-goettingen.de>
parent 9cec8f16
Loading
Loading
Loading
Loading
+23 −9
Original line number Diff line number Diff line
@@ -2,7 +2,7 @@
grammar org.etsi.mts.tdl.graphical.labels.Data with org.eclipse.xtext.common.Terminals

//import "http://www.eclipse.org/uml2/4.0.0/Types" 
import "http://www.etsi.org/spec/TDL/1.4.0"
import "http://www.etsi.org/spec/TDL/1.4.1"
//import "http://www.eclipse.org/uml2/5.0.0/Types" as types 
import "http://www.eclipse.org/emf/2002/Ecore" as ecore
//import "http://www.etsi.org/spec/TDL/STABLE" as tdl
@@ -103,6 +103,7 @@ AnyValue returns AnyValue:
	;
	
AnyNoneValue returns AnyValueOrOmit:
    {AnyValueOrOmit}
	'*'
	;

@@ -180,7 +181,7 @@ Function returns Function:
Member returns Member:
	(isOptional=Optional)?
	name=EString
	'of type'
	'of' 'type'
	dataType=[DataType|EString]
    (
    'with'
@@ -261,7 +262,7 @@ Parameter returns Parameter:

FormalParameter returns FormalParameter:
    name=EString
    'of type'
    'of' 'type'
    dataType=[DataType|EString]
    (
    'with'
@@ -369,7 +370,7 @@ TimeLabel returns TimeLabel:
Variable returns Variable:
	'variable'
	name=EString
	'of type'
	'of' 'type'
	dataType=[DataType|EString]
	('with' 
	'{'
@@ -530,7 +531,7 @@ Interaction returns Message:
	'{'
		(comment+=Comment (comment+=Comment)*)?
		(annotation+=Annotation (annotation+=Annotation)*)?
		('test objectives' ':' testObjective+=[TestObjective|EString] ( "," testObjective+=[TestObjective|EString])* ';')?
		('test' 'objectives' ':' testObjective+=[TestObjective|EString] ( "," testObjective+=[TestObjective|EString])* ';')?
		('name' name=EString)? //USE FOR STEPS?
		('time' 'label' timeLabel=TimeLabel)?
		('time' 'constraints' ':' timeConstraint+=TimeConstraint ( "," timeConstraint+=TimeConstraint)* ';' )?
@@ -544,7 +545,7 @@ Trigger returns ecore::EBoolean :

Target returns Target:
	targetGate=[GateReference|EStringDot]
	('where it is' 'assigned' 'to' variable=[Variable|EString])?
	(valueAssignment+=ValueAssignmentMessage)?
   	(
    'with'
    '{'
@@ -554,8 +555,21 @@ Target returns Target:
    '}')?
    ;

ValueAssignmentMessage returns ValueAssignment:
    //TODO: check what the correct syntax shall be
    'where' 'it' 'is' 'assigned' 'to' variable=[Variable|EString]
    (
    'with'
    '{'
        (comment+=Comment (comment+=Comment)*)?
        (annotation+=Annotation (annotation+=Annotation)*)?
        ('name' name=EString)?
    '}')?
    ;


VerdictAssignment returns VerdictAssignment:
	'set verdict' 'to'
	'set' 'verdict' 'to'
	verdict=DataUse
	;
	
@@ -572,7 +586,7 @@ Quiescence returns Quiescence:
;

TestDescription returns TestDescription:
	'Test Description'
	'Test' 'Description'
		name=EString
		('(' formalParameter+=FormalParameter ( "," formalParameter+=FormalParameter)* ')')?
		('uses' 'configuration' testConfiguration=[TestConfiguration|EString])
@@ -582,7 +596,7 @@ TestDescription returns TestDescription:

TestDescriptionReference returns TestDescriptionReference:
	testDescription=[TestDescription|EString]
	('(' actualParameter+=DataUse ( "," actualParameter+=DataUse)* ')' )?
    ('(' actualParameter+=ParameterBinding ( "," actualParameter+=ParameterBinding)* ')' )?
	(componentInstanceBinding+=ComponentInstanceBinding ( "," componentInstanceBinding+=ComponentInstanceBinding)*)?
;