-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjava5.tg
More file actions
493 lines (395 loc) · 30.9 KB
/
java5.tg
File metadata and controls
493 lines (395 loc) · 30.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
TGraph 2;
Schema de.uni_koblenz.jgralab.grabaja.java5schema.Java5Schema;
/// The graph class /////////////////////////////////////////////////////////////////////////////////////
GraphClass Java5 { name : String, version : String } ;
/// The enums /////////////////////////////////////////////////////////////////////////////////////
// The infix operators of java for expressions like a + b: =, ==, +, -, *, /, &, &&, |, ||, %, ....
EnumDomain InfixOperators( ASSIGNMENT,
EQUALS,
PLUS,
MINUS,
MULTIPLICATION,
DIVISION,
AND,
SHORTCIRCUITAND,
OR,
SHORTCIRCUITOR,
MODULO,
LEFTSHIFT,
RIGHTSHIFT,
UNSIGNEDRIGHTSHIFT,
UNEQUALS,
XOR,
PLUSASSIGNMENT,
MINUSASSIGNMENT,
MULTIPLICATIONASSIGNMENT,
DIVISIONASSIGNMENT,
GREATER,
GREATEREQUALS,
LESS,
LESSEQUALS,
MODULOASSIGNMENT,
LEFTSHIFTASSIGNMENT,
RIGHTSHIFTASSIGNMENT,
UNSIGNEDRIGHTSHIFTASSIGNMENT,
ANDASSIGNMENT,
ORASSIGNMENT,
XORASSIGNMENT,
INSTANCEOF ) ;
// The prefix operators of java for expressions like ++a: +, - , !, ~, ++, --
EnumDomain PrefixOperators( PLUS,
MINUS,
NOT,
BITWISECOMPLEMENT,
INCREMENT,
DECREMENT ) ;
// The postfix operators of java for expressions like a++: --, ++
EnumDomain PostfixOperators( DECREMENT,
INCREMENT ) ;
// The primitive types which come with java
EnumDomain BuiltInTypes( VOID,
BOOLEAN,
BYTE,
CHAR,
SHORT,
INT,
LONG,
FLOAT,
DOUBLE ) ;
// All modifiers of java
EnumDomain Modifiers( PUBLIC,
PROTECTED,
PRIVATE,
STATIC,
FINAL,
ABSTRACT,
VOLATILE,
SYNCHRONIZED,
NATIVE,
STRICTFP,
TRANSIENT ) ;
// All posibilities of a method invocation/call in java
EnumDomain MethodInvocationTypes( METHOD,
CONSTRUCTOR,
SUPERMETHOD,
SUPERCONSTRUCTOR,
EXPLICITCONSTRUCTOR ) ;
// some abstract top-level vertex type.
abstract VertexClass JavaVertex;
abstract EdgeClass AttributedEdge from JavaVertex( 0, * ) to JavaVertex( 0, * ) { offset : Integer, length : Integer , line : Integer , column : Integer } ;
abstract VertexClass Type : ExternalDeclaration, Member { name : String, fullyQualifiedName : String, external : Boolean } ;
abstract VertexClass Member : JavaVertex;
abstract VertexClass TypeSpecification : JavaVertex;
abstract VertexClass Statement : JavaVertex;
abstract VertexClass Expression : Statement ;
abstract VertexClass ForHead : JavaVertex;
abstract VertexClass FieldDeclaration : JavaVertex;
VertexClass Annotation : JavaVertex;
VertexClass Block : Statement;
VertexClass Identifier : JavaVertex { name : String };
VertexClass Modifier : JavaVertex { type : Modifiers };
VertexClass TypeParameterDeclaration : Type ;
VertexClass ParameterDeclaration : FieldDeclaration ;
VertexClass TypeArgument : TypeSpecification ;
VertexClass MethodDeclaration : Member ;
abstract EdgeClass IsExpressionOf : IsStatementOf from Expression (0,*) role expressions aggregation composite to Expression (0,1);
abstract EdgeClass IsAnnotationOf : AttributedEdge from Annotation( 0, * ) to JavaVertex( 1, 1 ) ;
abstract EdgeClass IsArgumentOf : AttributedEdge from JavaVertex( 0, * ) role args aggregation composite to JavaVertex( 0, 1 ) ;
abstract EdgeClass IsConditionOf : AttributedEdge from Expression( 0, 1 ) aggregation composite to JavaVertex( 1, 1 ) ;
abstract EdgeClass IsExceptionThrownBy : AttributedEdge from TypeSpecification( 0, * ) aggregation composite to Member( 1, 1 ) ;
abstract EdgeClass IsInterfaceOf : AttributedEdge from TypeSpecification( 0, * ) role interfaces to Type( 1, 1 ) ;
abstract EdgeClass IsSuperClassOf : AttributedEdge from TypeSpecification( 0, 1 ) role superClass to Type( 1, 1 ) ;
abstract EdgeClass IsLeftHandSideOf : IsExpressionOf from Expression( 1, 1 ) role lhs aggregation composite to Expression( 1, 1 ) ;
abstract EdgeClass IsRightHandSideOf : IsExpressionOf from Expression( 1, 1 ) role rhs aggregation composite to Expression( 1, 1 ) ;
abstract EdgeClass IsLoopBodyOf : IsStatementOf from Statement( 1, 1 ) role loopBody aggregation composite to Statement( 1, 1 ) ;
abstract EdgeClass IsModifierOf : AttributedEdge from Modifier( 0, * ) role modifiers to JavaVertex( 1, 1 ) ;
abstract EdgeClass IsParameterOf : AttributedEdge from ParameterDeclaration (0,*) role params aggregation composite to JavaVertex( 1, 1 ) ;
abstract EdgeClass IsStatementOf : AttributedEdge from Statement( 0, * ) role statements aggregation composite to JavaVertex( 1, 1 ) ;
abstract EdgeClass IsTypeOf : AttributedEdge from JavaVertex(1,1) to JavaVertex( 1, 1 ) ;
abstract EdgeClass IsTypeParameterOf : AttributedEdge from JavaVertex( 0, * ) to JavaVertex( 1, 1 ) ;
abstract EdgeClass IsBlockOf : IsStatementOf from Block( 1, 1 ) role block aggregation composite to JavaVertex( 1, 1 );
EdgeClass IsTypeArgumentOfTypeSpecification : AttributedEdge from TypeArgument( 0, * ) to TypeSpecification( 1, 1 ) ;
VertexClass Program : JavaVertex { name : String } ;
VertexClass TranslationUnit : JavaVertex;
EdgeClass IsTranslationUnitIn from TranslationUnit( 0, * ) to Program( 1, 1 ) ;
abstract VertexClass FoldGraphReference : JavaVertex { lengthOfFile : Integer } ;
VertexClass SourceUsage : FoldGraphReference ;
EdgeClass IsSourceUsageIn from SourceUsage( 1, 1 ) to TranslationUnit( 1, 1 );
VertexClass SourceFile : JavaVertex { name: String } ;
EdgeClass IsPrimarySourceFor from SourceFile( 1, 1 ) to TranslationUnit( 1, 1 ) ;
EdgeClass IsSourceFor from SourceFile( 1, 1 ) to SourceUsage( 1, 1 ) ;
abstract VertexClass ExternalDeclaration : JavaVertex;
EdgeClass IsExternalDeclarationIn : AttributedEdge from ExternalDeclaration( 0, * ) to SourceUsage( 1, 1 ) ;
abstract VertexClass ImportDefinition : ExternalDeclaration ;
VertexClass ClassImportDefinition : ImportDefinition ;
VertexClass PackageImportDefinition : ImportDefinition ;
VertexClass JavaPackage : JavaVertex { fullyQualifiedName : String } ;
VertexClass PackageDefinition : ExternalDeclaration;
EdgeClass IsPackageNameOf : AttributedEdge from QualifiedName( 1, 1 ) to PackageDefinition( 1,* );
EdgeClass IsPartOf from TranslationUnit( 0, * ) aggregation composite to JavaPackage( 1, 1 ) ;
EdgeClass IsPackageOf from JavaPackage( 1, * ) aggregation composite to Program( 1, 1 ) ;
EdgeClass IsSubPackageOf from JavaPackage( 0, * ) role subPackages aggregation composite to JavaPackage( 1, 1 ) ;
VertexClass Comment : JavaVertex;
VertexClass SingleLineComment : Comment ;
VertexClass MultiLineComment : Comment ;
VertexClass JavaDocComment : Comment ;
EdgeClass IsCommentIn : AttributedEdge from Comment( 0, * ) to TranslationUnit( 1, 1 ) ;
EdgeClass IsAnnotationNameOf : AttributedEdge from QualifiedName( 1, 1 ) to Annotation( 1, 1 ) ;
EdgeClass IsAnnotationArgumentOf : AttributedEdge from Expression( 0, * ) to Annotation( 1, 1 ) ;
EdgeClass IsAnnotationOfPackage : IsAnnotationOf from Annotation( 0, * ) to PackageDefinition( 1, 1 ) ;
EdgeClass IsStatementOfBody : IsStatementOf from Statement( 0, * ) aggregation composite to Block( 1, 1 ) ;
EdgeClass IsTypeIn : AttributedEdge from Type( 0, * ) to Statement( 1, 1 ) ;
VertexClass SimpleArgument : JavaVertex;
VertexClass WildcardArgument : JavaVertex;
EdgeClass IsSimpleArgumentOf : IsArgumentOf from SimpleArgument( 0, * ) aggregation composite to TypeArgument( 1, 1 ) ;
EdgeClass IsWildcardArgumentOf : IsArgumentOf from WildcardArgument( 0, * ) aggregation composite to TypeArgument( 1, 1 ) ;
EdgeClass IsTypeOfSimpleArgument : IsTypeOf from TypeSpecification( 1, 1 ) to SimpleArgument( 1, 1 ) ;
EdgeClass IsLowerBoundOfWildcardArgument : AttributedEdge from TypeSpecification( 0, 1 ) to WildcardArgument( 1, 1 ) ;
EdgeClass IsUpperBoundOfWildcardArgument : AttributedEdge from TypeSpecification( 0, 1 ) to WildcardArgument( 1, 1 ) ;
VertexClass TypeParameterUsage : TypeSpecification ;
EdgeClass IsTypeParameterUsageNameOf : AttributedEdge from Identifier( 1, 1 ) to TypeParameterUsage( 1, 1 ) ;
VertexClass ArrayType : TypeSpecification { dimensions : Integer } ;
EdgeClass IsElementTypeOf : IsTypeOf from TypeSpecification( 1, 1 ) to ArrayType( 1, 1 ) ;
VertexClass QualifiedName : TypeSpecification { fullyQualifiedName : String } ;
VertexClass QualifiedType : QualifiedName, Expression ;
EdgeClass IsQualifiedNameOf : AttributedEdge from QualifiedName( 0, * ) to JavaVertex( 0, * ) ;
EdgeClass IsNameOf : AttributedEdge from Identifier( 0, * ) to QualifiedName( 0, * ) ;
EdgeClass IsImportedTypeOf : AttributedEdge from QualifiedName( 1, 1 ) to ImportDefinition( 1, 1 ) ;
EdgeClass IsTypeDefinitionOf from Type( 0, * ) to TypeSpecification( 1, 1 );
VertexClass BuiltInType : TypeSpecification { type : BuiltInTypes } ;
EdgeClass IsTypeParameterDeclarationNameOf : AttributedEdge from Identifier( 1, 1 ) to TypeParameterDeclaration( 1, 1 ) ;
EdgeClass IsUpperBoundOfTypeParameter : AttributedEdge from TypeSpecification( 0, * ) to TypeParameterDeclaration( 1, 1 ) ;
EdgeClass IsAnnotationOfType : IsAnnotationOf from Annotation( 0, * ) to Type( 1, 1 ) ;
VertexClass ClassDefinition : Type ;
EdgeClass IsModifierOfClass : IsModifierOf from Modifier( 0, * ) to ClassDefinition( 1, 1 ) ;
EdgeClass IsClassNameOf : AttributedEdge from Identifier( 1, 1 ) role className to ClassDefinition( 1, 1 ) ;
EdgeClass IsTypeParameterOfClass : IsTypeParameterOf from TypeParameterDeclaration( 0, * ) to ClassDefinition( 1, 1 ) ;
EdgeClass IsSuperClassOfClass : IsSuperClassOf from TypeSpecification( 0, 1 ) to ClassDefinition( 1, 1 ) ;
EdgeClass IsInterfaceOfClass : IsInterfaceOf from TypeSpecification( 0, * ) to ClassDefinition( 1, 1 ) ;
EdgeClass IsClassBlockOf : IsBlockOf from Block( 1, 1 ) aggregation composite to ClassDefinition( 1, 1 ) ;
VertexClass InterfaceDefinition : Type ;
EdgeClass IsModifierOfInterface : IsModifierOf from Modifier( 0, * ) to InterfaceDefinition( 1, 1 ) ;
EdgeClass IsInterfaceNameOf : AttributedEdge from Identifier( 1, 1 ) role interfaceName to InterfaceDefinition( 1, 1 ) ;
EdgeClass IsTypeParameterOfInterface : IsTypeParameterOf from TypeParameterDeclaration( 0, * ) to InterfaceDefinition( 1, 1 ) ;
EdgeClass IsSuperClassOfInterface : IsSuperClassOf from TypeSpecification( 0, 1 ) to InterfaceDefinition( 1, 1 ) ;
EdgeClass IsInterfaceBlockOf : IsBlockOf from Block( 1, 1 ) aggregation composite to InterfaceDefinition( 1, 1 ) ;
VertexClass VariableDeclaration : FieldDeclaration, Statement ;
VertexClass EnumConstant : Member, FieldDeclaration ;
EdgeClass IsAnnotationOfEnumConstant : IsAnnotationOf from Annotation( 1, 1 ) to EnumConstant( 1, 1 ) ;
EdgeClass IsEnumConstantNameOf : AttributedEdge from Identifier( 1, 1 ) role enumConstantName to EnumConstant( 1, 1 ) ;
EdgeClass IsArgumentOfEnumConstant : IsArgumentOf from Expression( 0, * ) aggregation composite to EnumConstant( 1, 1 ) ;
EdgeClass IsEnumConstantBlockOf : IsBlockOf from Block( 1, 1 ) aggregation composite to EnumConstant( 1, 1 );
VertexClass EnumDefinition : Type ;
EdgeClass IsModifierOfEnum : IsModifierOf from Modifier( 0, * ) to EnumDefinition( 1, 1 ) ;
EdgeClass IsEnumNameOf : AttributedEdge from Identifier( 1, 1 ) role enumName to EnumDefinition( 1, 1 ) ;
EdgeClass IsInterfaceOfEnum : IsInterfaceOf from TypeSpecification( 0, * ) to EnumDefinition( 1, 1 ) ;
EdgeClass IsEnumBlockOf : IsBlockOf from Block( 1, 1 ) aggregation composite to EnumDefinition( 1, 1 ) ;
VertexClass AnnotationDefinition : Type ;
EdgeClass IsModifierOfAnnotation : IsModifierOf from Modifier( 0, * ) to AnnotationDefinition( 1, 1 ) ;
EdgeClass IsAnnotationDefinitionNameOf : AttributedEdge from Identifier( 1, 1 ) role annotationName to AnnotationDefinition( 1, 1 ) ;
EdgeClass IsMetaAnnotationOf : IsAnnotationOf from Annotation( 0, * ) to AnnotationDefinition( 1, 1 ) ;
EdgeClass IsAnnotationBlockOf : IsBlockOf from Block( 1, 1 ) to AnnotationDefinition( 1, 1 ) ;
abstract EdgeClass IsDeclarationOf from JavaVertex (0,*) to JavaVertex (0,*);
VertexClass FieldAccess : Expression ;
EdgeClass IsFieldContainerOf : AttributedEdge from Expression( 0, 1 ) to FieldAccess( 1, 1 ) ;
EdgeClass IsFieldNameOf : AttributedEdge from Identifier( 1, 1 ) role fieldName to FieldAccess( 1, 1 ) ;
EdgeClass IsArrayElementIndexOf : AttributedEdge from Expression( 0, * ) to FieldAccess( 1, 1 ) ;
EdgeClass IsDeclarationOfAccessedField: IsDeclarationOf from JavaVertex( 0, * ) to FieldAccess( 1, 1 ) ;
VertexClass MethodInvocation : Expression { type : MethodInvocationTypes } ;
EdgeClass IsMethodContainerOf : AttributedEdge from Expression( 0, 1 ) to MethodInvocation( 1, 1 ) ;
EdgeClass IsNameOfInvokedMethod : AttributedEdge from Identifier( 1, 1 ) role invokedMethodName to MethodInvocation( 1, 1 ) ;
EdgeClass IsArgumentOfMethodInvocation : IsArgumentOf from Expression( 0, * ) aggregation composite to MethodInvocation( 1, 1 ) ;
EdgeClass IsDeclarationOfInvokedMethod: IsDeclarationOf from Member( 0, * ) to MethodInvocation( 1, 1 ) ;
VertexClass ConditionalExpression : Expression ;
EdgeClass IsConditionOfExpression : IsConditionOf from Expression( 1, 1 ) aggregation composite to ConditionalExpression( 1, 1 ) ;
EdgeClass IsMatchOf : AttributedEdge from Expression( 1, 1 ) role match aggregation composite to ConditionalExpression( 1, 1 ) ;
EdgeClass IsMismatchOf : AttributedEdge from Expression( 1, 1 ) role mismatch aggregation composite to ConditionalExpression( 1, 1 ) ;
VertexClass BuiltInCast : Expression ;
EdgeClass IsCastedBuiltInTypeOf : IsTypeOf from BuiltInType( 1, 1 ) to BuiltInCast( 1, 1 ) ;
EdgeClass IsCastedValueOf : AttributedEdge from Expression( 1, 1 ) aggregation composite to BuiltInCast( 1, 1 ) ;
VertexClass ClassCast : Expression ;
EdgeClass IsCastedTypeOf : IsTypeOf from TypeSpecification( 1, 1 ) to ClassCast( 1, 1 );
EdgeClass IsCastedObjectOf : AttributedEdge from Expression( 1, 1 ) aggregation composite to ClassCast( 1, 1 );
VertexClass InfixExpression : Expression { operator : InfixOperators } ;
EdgeClass IsLeftHandSideOfInfixExpression : IsLeftHandSideOf from Expression( 1, 1 ) aggregation composite to InfixExpression( 1, 1 ) ;
EdgeClass IsRightHandSideOfInfixExpression : IsRightHandSideOf from Expression( 1, 1 ) aggregation composite to InfixExpression( 1, 1 ) ;
VertexClass PrefixExpression : Expression { operator : PrefixOperators } ;
EdgeClass IsRightHandSideOfPrefixExpression : IsRightHandSideOf from Expression( 1, 1 ) aggregation composite to PrefixExpression( 1, 1 ) ;
VertexClass PostfixExpression: Expression { operator : PostfixOperators } ;
EdgeClass IsLeftHandSideOfPostfixExpression : IsLeftHandSideOf from Expression( 1, 1 ) aggregation composite to PostfixExpression( 1, 1 ) ;
VertexClass Null : Expression ;
VertexClass BooleanConstant : Expression { value : Boolean } ;
VertexClass FloatConstant : Expression { value : Double, literal : String } ;
VertexClass DoubleConstant : Expression { value : Double, literal : String } ;
VertexClass IntegerConstant : Expression { value : Long, literal : String } ;
VertexClass LongConstant : Expression { value : Long, literal : String } ;
VertexClass CharConstant : Expression { value : Integer, literal : String } ;
VertexClass StringConstant : Expression { value : String } ;
VertexClass ArrayInitializer : Expression ;
EdgeClass IsSizeOf : AttributedEdge from Expression( 0, 1 ) aggregation composite to ArrayInitializer( 1, 1 );
EdgeClass IsContentOf : AttributedEdge from Expression( 0, * ) aggregation composite to ArrayInitializer( 1, 1 );
VertexClass ArrayCreation : Expression ;
EdgeClass IsElementTypeOfCreatedArray : IsTypeOf from TypeSpecification( 0, 1 ) to ArrayCreation( 1, 1 ) ;
EdgeClass IsDimensionInitializerOf : AttributedEdge from ArrayInitializer( 1, * ) aggregation composite to ArrayCreation( 1, 1 ) ;
VertexClass ObjectCreation : Expression ;
EdgeClass IsTypeOfObject : AttributedEdge from TypeSpecification( 1, 1 ) aggregation composite to ObjectCreation( 1, 1 );
EdgeClass IsConstructorInvocationOf : AttributedEdge from MethodInvocation( 1, 1 ) aggregation composite to ObjectCreation( 1, 1 ) ;
VertexClass VariableInitializer : Expression ;
EdgeClass IsInitializerOf : IsExpressionOf from Expression( 1, 1 ) aggregation composite to VariableInitializer( 1, 1 ) ;
EdgeClass IsAnnotationOfMember : IsAnnotationOf from Annotation( 0, * ) to Member( 1, 1 ) ;
EdgeClass IsMemberOf : AttributedEdge from Member( 0, * ) role members aggregation composite to Block( 1, 1 ) ;
VertexClass Field : Member ;
EdgeClass IsFieldCreationOf : AttributedEdge from Statement( 1, 1 ) to Field( 1, 1 ) ;
VertexClass AnnotationField : Member ;
EdgeClass IsModifierOfAnnotationField : IsModifierOf from Modifier( 0, * ) to AnnotationField( 1, 1 ) ;
EdgeClass IsTypeOfAnnotationField : AttributedEdge from TypeSpecification( 1, 1 ) to AnnotationField( 1, 1 );
EdgeClass IsAnnotationFieldNameOf : AttributedEdge from Identifier( 1, 1 ) to AnnotationField( 1, 1 );
EdgeClass IsDefaultValueOf : AttributedEdge from Expression( 1, 1 ) to AnnotationField( 1, 1 );
VertexClass ConstructorDefinition : Member ;
EdgeClass IsModifierOfConstructor : IsModifierOf from Modifier( 0, * ) to ConstructorDefinition( 1, 1 ) ;
EdgeClass IsTypeParameterOfConstructor : IsTypeParameterOf from TypeParameterDeclaration( 0, * ) to ConstructorDefinition( 1, 1 ) ;
EdgeClass IsNameOfConstructor : AttributedEdge from Identifier( 1, 1 ) role constructorName to ConstructorDefinition( 1, 1 ) ;
EdgeClass IsParameterOfConstructor : IsParameterOf from ParameterDeclaration( 0, * ) aggregation composite to ConstructorDefinition( 1, 1 ) ;
EdgeClass IsExceptionThrownByConstructor : IsExceptionThrownBy from TypeSpecification( 0, * ) aggregation composite to ConstructorDefinition( 1, 1 ) ;
EdgeClass IsBodyOfConstructor : IsStatementOf from Block( 1, 1 ) aggregation composite to ConstructorDefinition( 1, 1 ) ;
VertexClass StaticInitializerDefinition : Member ;
EdgeClass IsBodyOfStaticInitializer : IsStatementOf from Block( 1, 1 ) aggregation composite to StaticInitializerDefinition( 1, 1 ) ;
VertexClass StaticConstructorDefinition : Member ;
EdgeClass IsBodyOfStaticConstructor : IsStatementOf from Block( 1, 1 ) aggregation composite to StaticConstructorDefinition( 1, 1 ) ;
EdgeClass IsModifierOfMethod : IsModifierOf from Modifier( 0, * ) to MethodDeclaration( 1, 1 ) ;
EdgeClass IsReturnTypeOf : IsTypeOf from TypeSpecification( 1, 1 ) role returnType to MethodDeclaration( 1, 1 ) ;
EdgeClass IsTypeParameterOfMethod : IsTypeParameterOf from TypeParameterDeclaration( 0, * ) to MethodDeclaration( 1, 1 ) ;
EdgeClass IsNameOfMethod : AttributedEdge from Identifier( 1, 1 ) role methodName to MethodDeclaration( 1, 1 ) ;
EdgeClass IsParameterOfMethod : IsParameterOf from ParameterDeclaration( 0, * ) role parameters to MethodDeclaration( 1, 1 ) ;
EdgeClass IsExceptionThrownByMethod : IsExceptionThrownBy from TypeSpecification( 0, * ) aggregation composite to MethodDeclaration( 1, 1 ) ;
VertexClass MethodDefinition : MethodDeclaration ;
EdgeClass IsBodyOfMethod : AttributedEdge from Block( 1, 1 ) role body aggregation composite to MethodDefinition( 1, 1 ) ;
EdgeClass IsCalledByMethod from MethodDeclaration (0,*) to MethodDeclaration(0, *);
EdgeClass IsModifierOfParameter : IsModifierOf from Modifier( 0, 1 ) to ParameterDeclaration( 1, 1 ) ;
EdgeClass IsTypeOfParameter : IsTypeOf from TypeSpecification( 1, 1 ) role paramType to ParameterDeclaration( 1, 1 ) ;
EdgeClass IsParameterNameOf : AttributedEdge from Identifier( 1, 1 ) role parameterName to ParameterDeclaration( 1, 1 ) ;
VertexClass VariableLengthDeclaration : ParameterDeclaration ;
VertexClass Label : Statement ;
EdgeClass IsLabelNameOf : AttributedEdge from Identifier( 1, 1 ) role labelName to Label( 1, 1 ) ;
EdgeClass IsAttachedTo : IsStatementOf from Statement( 1, 1 ) to Label( 1, 1 ) ;
VertexClass If : Statement ;
EdgeClass IsConditionOfIf : IsConditionOf from Expression( 1, 1 ) aggregation composite to If( 1, 1 ) ;
EdgeClass IsThenOf : IsStatementOf from Statement( 1, 1 ) aggregation composite to If( 1, 1 ) ;
EdgeClass IsElseOf : IsStatementOf from Statement( 0, 1 ) aggregation composite to If( 1, 1 ) ;
VertexClass For : Statement ;
EdgeClass IsHeadOfFor : AttributedEdge from ForHead( 1, 1 ) aggregation composite to For( 1, 1 ) ;
EdgeClass IsLoopBodyOfFor : IsLoopBodyOf from Statement( 1, 1 ) aggregation composite to For( 1, 1 ) ;
VertexClass TraditionalForClause : ForHead ;
EdgeClass IsRunVariableInitializationOf : AttributedEdge from Statement( 0, * ) aggregation composite to TraditionalForClause( 1, 1 ) ;
EdgeClass IsForConditionOf : IsConditionOf from Expression( 0, 1 ) aggregation composite to TraditionalForClause( 1, 1 ) ;
EdgeClass IsIteratorOf : IsStatementOf from Expression( 0, * ) aggregation composite to TraditionalForClause( 1, 1 ) ;
VertexClass ForEachClause : ForHead;
EdgeClass IsParameterOfForEachClause : IsParameterOf from ParameterDeclaration( 1, 1 ) aggregation composite to ForEachClause( 1, 1 ) ;
EdgeClass IsEnumerableOf : AttributedEdge from Expression( 1, 1 ) aggregation composite to ForEachClause( 1, 1 ) ;
VertexClass EmptyStatement : Statement ;
VertexClass While : Statement ;
EdgeClass IsLoopBodyOfWhile : IsLoopBodyOf from Statement( 1, 1 ) aggregation composite to While( 1, 1 ) ;
EdgeClass IsConditionOfWhile : IsConditionOf from Expression( 1, 1 ) aggregation composite to While( 1, 1 ) ;
VertexClass DoWhile : Statement ;
EdgeClass IsLoopBodyOfDoWhile : IsLoopBodyOf from Statement( 1, 1 ) aggregation composite to DoWhile( 1, 1 ) ;
EdgeClass IsConditionOfDoWhile : IsConditionOf from Expression( 1, 1 ) aggregation composite to DoWhile( 1, 1 ) ;
VertexClass Break : Statement ;
EdgeClass IsBreakTargetOf : AttributedEdge from Label( 0, 1 ) role breakTarget to Break( 1, 1 ) ;
VertexClass Continue : Statement ;
EdgeClass IsContinueTargetOf : AttributedEdge from Label( 0, 1 ) role continueTarget to Continue( 1, 1 ) ;
VertexClass Return : Statement ;
EdgeClass IsReturnedBy : IsStatementOf from Expression( 0, 1 ) aggregation composite to Return( 1, 1 ) ;
VertexClass Switch : Statement ;
VertexClass Case : Statement ;
VertexClass Default : Statement ;
EdgeClass IsSwitchArgumentOf : IsArgumentOf from Expression( 1, 1 ) aggregation composite to Switch( 1, 1 ) ;
EdgeClass IsCaseOf : IsStatementOf from Case( 0, * ) aggregation composite to Switch( 1, 1 ) ;
EdgeClass IsDefaultCaseOf : IsStatementOf from Default( 0, 1 ) aggregation composite to Switch( 1, 1 ) ;
EdgeClass IsCaseConditionOf : IsConditionOf from Expression( 1, 1 ) aggregation composite to Case( 1, 1 ) ;
EdgeClass IsStatementOfCase : IsStatementOf from Statement( 0, * ) aggregation composite to Case( 1, 1 ) ;
EdgeClass IsStatementOfDefaultCase : IsStatementOf from Statement( 0, * ) aggregation composite to Default( 1, 1 ) ;
VertexClass Try : Statement ;
VertexClass Catch : Statement ;
EdgeClass IsBodyOfTry : IsStatementOf from Block( 1, 1 ) aggregation composite to Try( 1, 1 ) ;
EdgeClass IsHandlerOf : IsStatementOf from Catch( 0, * ) aggregation composite to Try( 1, 1 ) ;
EdgeClass IsCaughtExceptionOf : AttributedEdge from ParameterDeclaration( 1, 1 ) aggregation composite to Catch( 1, 1 ) ;
EdgeClass IsBodyOfCatch : IsStatementOf from Block( 1, 1 ) aggregation composite to Catch( 1, 1 ) ;
EdgeClass IsBodyOfFinally : IsStatementOf from Block( 0, 1 ) aggregation composite to Try( 1, 1 ) ;
VertexClass Throw : Statement ;
EdgeClass IsThrownExceptionOf : AttributedEdge from Expression( 1, 1 ) aggregation composite to Throw( 1, 1 ) ;
VertexClass Synchronized : Statement ;
EdgeClass IsMonitorOf : AttributedEdge from Expression( 1, 1 ) aggregation composite to Synchronized( 1, 1 ) ;
EdgeClass IsSynchronizedBodyOf : AttributedEdge from Block( 1, 1 ) aggregation composite to Synchronized( 1, 1 ) ;
VertexClass Assert : Statement ;
EdgeClass IsConditionOfAssert : IsConditionOf from Expression( 1, 1 ) aggregation composite to Assert( 1, 1 ) ;
EdgeClass IsMessageOf : AttributedEdge from Expression( 0, 1 ) aggregation composite to Assert( 1, 1 ) ;
EdgeClass IsAnnotationOfVariable : IsAnnotationOf from Annotation( 0, * ) to VariableDeclaration( 1, 1 ) ;
EdgeClass IsModifierOfVariable : IsModifierOf from Modifier( 0, * ) to VariableDeclaration( 1, 1 ) ;
EdgeClass IsTypeOfVariable : IsTypeOf from TypeSpecification( 1, 1 ) role variableType to VariableDeclaration( 1, 1 ) ;
EdgeClass IsVariableNameOf : AttributedEdge from Identifier( 1, * ) to VariableDeclaration( 1, 1 ) ;
EdgeClass IsInitializerOfVariable : IsStatementOf from Expression ( 0, 1 ) to VariableDeclaration( 1, 1 ) ;
VertexClass ClassLiteral : Expression;
EdgeClass IsSpecifiedTypeOf : AttributedEdge from TypeSpecification( 0, 1 ) to ClassLiteral( 0, 1 ) ;
////////////// Activity-Part //////////////////////////////////////////////////////////////////////////////
Package processes;
Package processes.activity;
RecordDomain processes.activity.Bounds (height: Integer, width: Integer, x: Integer, y: Integer);
EnumDomain processes.activity.Direction (IN, OUT, INOUT, RETURN);
VertexClass AcceptEventAction: Action;
abstract VertexClass Action: Node;
VertexClass Activity: WorkflowElement, NamedElement;
VertexClass Actor: NamedElement;
VertexClass CallAction: Action;
VertexClass Comment {text: String} ["All Comment elements must have a text" "import processes.activity.*; forall c : V{Comment} @ c.text <> null and c.text <> \"\"" "import processes.activity.*; from c : V{Comment} with c.text = null or c.text = \"\" reportSet c end"];
VertexClass Component: NamedElement;
abstract VertexClass ControlNode: Node;
VertexClass DataStore: ObjectNode;
VertexClass DecisionNode: ControlNode;
VertexClass FinalNode: ControlNode;
VertexClass Flow: NamedElement {guardCondition: String} ["Flows starting at DecisionNodes must have a guardCondition" "import processes.activity.*; forall f : V{Flow}, count(f -->{From} & {DecisionNode}) > 0 @ f.guardCondition <> null and f.guardCondition <> \"\"" "import processes.activity.*; from f : V{Flow} with count(f -->{From} & {DecisionNode}) > 0 and (f.guardCondition = null or f.guardCondition = \"\") reportSet f end"];
VertexClass ForkNode: ControlNode;
VertexClass InitialNode: ControlNode;
VertexClass InputPin: Pin;
VertexClass JoinNode: ControlNode;
VertexClass MergeNode: ControlNode;
abstract VertexClass NamedElement {name: String};
abstract VertexClass Node: NamedElement {bounds: Bounds, xmiId: String};
abstract VertexClass ObjectNode: Node {state: String, type: String} ["All ObjectNode elements must have a type" "import processes.activity.*; forall o : V{ObjectNode} @ o.type <> null and o.type <> \"\"" "import processes.activity.*; from o : V{ObjectNode} with o.type = null or o.type = \"\" reportSet o end"];
VertexClass OpaqueAction: Action;
VertexClass OutputPin: Pin;
VertexClass Package: NamedElement ["There must be at least one Package element" "import processes.activity.*; count(V{Package}) > 0"];
VertexClass Parameter: ObjectNode {direction: Direction};
VertexClass Partition: NamedElement ["All Partition elements must have either exactly an associated Actor or a Component" "import processes.activity.*; forall p : V{Partition} @ count(p -->{HasActor, HasComponent}) = 1" "import processes.activity.*; from p : V{Partition} with count(p -->{HasActor, HasComponent}) <> 1 reportSet p end"];
abstract VertexClass Pin: ObjectNode;
Comment processes.activity.Process "A Process is a special Activity, which can be seen as the head Activity,<br /> from which everything starts. This is modeled via an stereotype <<process>><br /> in the business process models, but is represented in the metamodel as a subtype.";
VertexClass Process: Activity;
VertexClass SendSignalAction: Action;
VertexClass Subsystem: Component;
abstract VertexClass WorkflowElement;
EdgeClass Calls from CallAction (0,*) to Activity (1,1) role behavior;
EdgeClass From from Flow (0,*) role incoming to Node (1,1) role target;
EdgeClass HasActivity from Package (1,1) to Activity (0,*) role activity aggregation composite;
EdgeClass HasActor from Partition (0,*) role partition to Actor (0,1) role actor;
EdgeClass HasComment from NamedElement (0,*) to Comment (0,*) role comment;
EdgeClass HasComponent from Partition (0,*) role partition to Component (0,1) role component;
EdgeClass HasInputPin from Action (1,1) to InputPin (0,*) role inputPin aggregation composite;
EdgeClass HasNode from Activity (1,1) to Node (0,*) role node aggregation composite;
EdgeClass HasOutputPin from Action (1,1) to OutputPin (0,*) role outputPin aggregation composite;
EdgeClass HasParameter from Activity (1,1) to Parameter (0,*) role parameter aggregation composite;
EdgeClass HasPartition from Activity (1,1) to Partition (0,*) role partition aggregation composite;
EdgeClass HasSubPackage from Package (0,1) to Package (0,*) role subPackage aggregation composite;
EdgeClass LocatedInPartition from Node (0,*) role activityNode to Partition (0,1) role partition;
EdgeClass To from Flow (0,*) role outgoing to Node (1,1) role source;
// Uncommented, cause in grabaja there's no frontend.java.DataObject.
//
//Comment processes.activity.RelatesTo "This relation is not implemented by the converter.<br /> It is rather meant to be used for traceability links.";
//EdgeClass RelatesTo from NamedElement (0,*) role namedElement to frontend.java.DataObject (0,*) role dataObject;
VertexClass Workflow: WorkflowElement {name: String, traceId: Integer};
abstract EdgeClass WorkflowEdge from WorkflowElement (0,*) to WorkflowElement (0,*) {traceId: Integer};
EdgeClass WorkflowHasNext: WorkflowEdge from Activity (0,*) to Activity (0,*);
EdgeClass WorkflowStartsAt: WorkflowEdge from Workflow (0,*) to Activity (1,1);
////////////// Trace-Part //////////////////////////////////////////////////////////////////////////////
Package traceability;
EdgeClass TLActivityCallsMethod: TLActivityTracesToLanguageObject from processes.activity.Activity (0,*) to .MethodDefinition (0,*) role traceCallsMethodTarget;
EdgeClass TLActivityInstantiatesClass: TLActivityTracesToLanguageObject from processes.activity.Activity (0,*) to .Type (0,*) role traceInstatiatesClassTarget;
abstract EdgeClass TLActivityTracesToLanguageObject from processes.activity.Activity (0,*) role traceSource to .Member (0,*) role traceTarget {count: Long, traceId: Integer};