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
|
package org.eclipse.papyrus.common.editor.xtext.parser.antlr.internal;
import org.eclipse.xtext.*;
import org.eclipse.xtext.parser.*;
import org.eclipse.xtext.parser.impl.*;
import org.eclipse.emf.ecore.util.EcoreUtil;
import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.common.util.Enumerator;
import org.eclipse.xtext.parser.antlr.AbstractInternalAntlrParser;
import org.eclipse.xtext.parser.antlr.XtextTokenStream;
import org.eclipse.xtext.parser.antlr.XtextTokenStream.HiddenTokens;
import org.eclipse.xtext.parser.antlr.AntlrDatatypeRuleToken;
import org.eclipse.papyrus.common.editor.xtext.services.UmlCommonGrammarAccess;
import org.antlr.runtime.*;
import java.util.Stack;
import java.util.List;
import java.util.ArrayList;
@SuppressWarnings("all")
public class InternalUmlCommonParser extends AbstractInternalAntlrParser {
public static final String[] tokenNames = new String[] {
"<invalid>", "<EOR>", "<DOWN>", "<UP>", "RULE_ID", "RULE_UNLIMITEDLITERAL", "RULE_INT", "RULE_STRING", "RULE_ML_COMMENT", "RULE_SL_COMMENT", "RULE_WS", "RULE_ANY_OTHER", "'::'"
};
public static final int RULE_ID=4;
public static final int RULE_STRING=7;
public static final int RULE_UNLIMITEDLITERAL=5;
public static final int T__12=12;
public static final int RULE_ANY_OTHER=11;
public static final int RULE_INT=6;
public static final int RULE_WS=10;
public static final int RULE_SL_COMMENT=9;
public static final int EOF=-1;
public static final int RULE_ML_COMMENT=8;
// delegates
// delegators
public InternalUmlCommonParser(TokenStream input) {
this(input, new RecognizerSharedState());
}
public InternalUmlCommonParser(TokenStream input, RecognizerSharedState state) {
super(input, state);
}
public String[] getTokenNames() { return InternalUmlCommonParser.tokenNames; }
public String getGrammarFileName() { return "../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g"; }
private UmlCommonGrammarAccess grammarAccess;
public InternalUmlCommonParser(TokenStream input, UmlCommonGrammarAccess grammarAccess) {
this(input);
this.grammarAccess = grammarAccess;
registerRules(grammarAccess.getGrammar());
}
@Override
protected String getFirstRuleName() {
return "QualifiedName";
}
@Override
protected UmlCommonGrammarAccess getGrammarAccess() {
return grammarAccess;
}
// $ANTLR start "entryRuleQualifiedName"
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:68:1: entryRuleQualifiedName returns [EObject current=null] : iv_ruleQualifiedName= ruleQualifiedName EOF ;
public final EObject entryRuleQualifiedName() throws RecognitionException {
EObject current = null;
EObject iv_ruleQualifiedName = null;
try {
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:69:2: (iv_ruleQualifiedName= ruleQualifiedName EOF )
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:70:2: iv_ruleQualifiedName= ruleQualifiedName EOF
{
newCompositeNode(grammarAccess.getQualifiedNameRule());
pushFollow(FOLLOW_ruleQualifiedName_in_entryRuleQualifiedName75);
iv_ruleQualifiedName=ruleQualifiedName();
state._fsp--;
current =iv_ruleQualifiedName;
match(input,EOF,FOLLOW_EOF_in_entryRuleQualifiedName85);
}
}
catch (RecognitionException re) {
recover(input,re);
appendSkippedTokens();
}
finally {
}
return current;
}
// $ANTLR end "entryRuleQualifiedName"
// $ANTLR start "ruleQualifiedName"
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:77:1: ruleQualifiedName returns [EObject current=null] : ( ( (otherlv_0= RULE_ID ) ) otherlv_1= '::' ( (lv_remaining_2_0= ruleQualifiedName ) )? ) ;
public final EObject ruleQualifiedName() throws RecognitionException {
EObject current = null;
Token otherlv_0=null;
Token otherlv_1=null;
EObject lv_remaining_2_0 = null;
enterRule();
try {
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:80:28: ( ( ( (otherlv_0= RULE_ID ) ) otherlv_1= '::' ( (lv_remaining_2_0= ruleQualifiedName ) )? ) )
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:81:1: ( ( (otherlv_0= RULE_ID ) ) otherlv_1= '::' ( (lv_remaining_2_0= ruleQualifiedName ) )? )
{
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:81:1: ( ( (otherlv_0= RULE_ID ) ) otherlv_1= '::' ( (lv_remaining_2_0= ruleQualifiedName ) )? )
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:81:2: ( (otherlv_0= RULE_ID ) ) otherlv_1= '::' ( (lv_remaining_2_0= ruleQualifiedName ) )?
{
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:81:2: ( (otherlv_0= RULE_ID ) )
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:82:1: (otherlv_0= RULE_ID )
{
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:82:1: (otherlv_0= RULE_ID )
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:83:3: otherlv_0= RULE_ID
{
if (current==null) {
current = createModelElement(grammarAccess.getQualifiedNameRule());
}
otherlv_0=(Token)match(input,RULE_ID,FOLLOW_RULE_ID_in_ruleQualifiedName130);
newLeafNode(otherlv_0, grammarAccess.getQualifiedNameAccess().getPathNamespaceCrossReference_0_0());
}
}
otherlv_1=(Token)match(input,12,FOLLOW_12_in_ruleQualifiedName142);
newLeafNode(otherlv_1, grammarAccess.getQualifiedNameAccess().getColonColonKeyword_1());
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:98:1: ( (lv_remaining_2_0= ruleQualifiedName ) )?
int alt1=2;
int LA1_0 = input.LA(1);
if ( (LA1_0==RULE_ID) ) {
alt1=1;
}
switch (alt1) {
case 1 :
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:99:1: (lv_remaining_2_0= ruleQualifiedName )
{
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:99:1: (lv_remaining_2_0= ruleQualifiedName )
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:100:3: lv_remaining_2_0= ruleQualifiedName
{
newCompositeNode(grammarAccess.getQualifiedNameAccess().getRemainingQualifiedNameParserRuleCall_2_0());
pushFollow(FOLLOW_ruleQualifiedName_in_ruleQualifiedName163);
lv_remaining_2_0=ruleQualifiedName();
state._fsp--;
if (current==null) {
current = createModelElementForParent(grammarAccess.getQualifiedNameRule());
}
set(
current,
"remaining",
lv_remaining_2_0,
"QualifiedName");
afterParserOrEnumRuleCall();
}
}
break;
}
}
}
leaveRule();
}
catch (RecognitionException re) {
recover(input,re);
appendSkippedTokens();
}
finally {
}
return current;
}
// $ANTLR end "ruleQualifiedName"
// $ANTLR start "entryRuleBoundSpecification"
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:128:1: entryRuleBoundSpecification returns [EObject current=null] : iv_ruleBoundSpecification= ruleBoundSpecification EOF ;
public final EObject entryRuleBoundSpecification() throws RecognitionException {
EObject current = null;
EObject iv_ruleBoundSpecification = null;
try {
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:129:2: (iv_ruleBoundSpecification= ruleBoundSpecification EOF )
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:130:2: iv_ruleBoundSpecification= ruleBoundSpecification EOF
{
newCompositeNode(grammarAccess.getBoundSpecificationRule());
pushFollow(FOLLOW_ruleBoundSpecification_in_entryRuleBoundSpecification204);
iv_ruleBoundSpecification=ruleBoundSpecification();
state._fsp--;
current =iv_ruleBoundSpecification;
match(input,EOF,FOLLOW_EOF_in_entryRuleBoundSpecification214);
}
}
catch (RecognitionException re) {
recover(input,re);
appendSkippedTokens();
}
finally {
}
return current;
}
// $ANTLR end "entryRuleBoundSpecification"
// $ANTLR start "ruleBoundSpecification"
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:137:1: ruleBoundSpecification returns [EObject current=null] : ( (lv_value_0_0= RULE_UNLIMITEDLITERAL ) ) ;
public final EObject ruleBoundSpecification() throws RecognitionException {
EObject current = null;
Token lv_value_0_0=null;
enterRule();
try {
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:140:28: ( ( (lv_value_0_0= RULE_UNLIMITEDLITERAL ) ) )
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:141:1: ( (lv_value_0_0= RULE_UNLIMITEDLITERAL ) )
{
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:141:1: ( (lv_value_0_0= RULE_UNLIMITEDLITERAL ) )
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:142:1: (lv_value_0_0= RULE_UNLIMITEDLITERAL )
{
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:142:1: (lv_value_0_0= RULE_UNLIMITEDLITERAL )
// ../org.eclipse.papyrus.common.editor.xtext/src-gen/org/eclipse/papyrus/common/editor/xtext/parser/antlr/internal/InternalUmlCommon.g:143:3: lv_value_0_0= RULE_UNLIMITEDLITERAL
{
lv_value_0_0=(Token)match(input,RULE_UNLIMITEDLITERAL,FOLLOW_RULE_UNLIMITEDLITERAL_in_ruleBoundSpecification255);
newLeafNode(lv_value_0_0, grammarAccess.getBoundSpecificationAccess().getValueUnlimitedLiteralTerminalRuleCall_0());
if (current==null) {
current = createModelElement(grammarAccess.getBoundSpecificationRule());
}
setWithLastConsumed(
current,
"value",
lv_value_0_0,
"UnlimitedLiteral");
}
}
}
leaveRule();
}
catch (RecognitionException re) {
recover(input,re);
appendSkippedTokens();
}
finally {
}
return current;
}
// $ANTLR end "ruleBoundSpecification"
// Delegated rules
public static final BitSet FOLLOW_ruleQualifiedName_in_entryRuleQualifiedName75 = new BitSet(new long[]{0x0000000000000000L});
public static final BitSet FOLLOW_EOF_in_entryRuleQualifiedName85 = new BitSet(new long[]{0x0000000000000002L});
public static final BitSet FOLLOW_RULE_ID_in_ruleQualifiedName130 = new BitSet(new long[]{0x0000000000001000L});
public static final BitSet FOLLOW_12_in_ruleQualifiedName142 = new BitSet(new long[]{0x0000000000000012L});
public static final BitSet FOLLOW_ruleQualifiedName_in_ruleQualifiedName163 = new BitSet(new long[]{0x0000000000000002L});
public static final BitSet FOLLOW_ruleBoundSpecification_in_entryRuleBoundSpecification204 = new BitSet(new long[]{0x0000000000000000L});
public static final BitSet FOLLOW_EOF_in_entryRuleBoundSpecification214 = new BitSet(new long[]{0x0000000000000002L});
public static final BitSet FOLLOW_RULE_UNLIMITEDLITERAL_in_ruleBoundSpecification255 = new BitSet(new long[]{0x0000000000000002L});
}
|