| /******************************************************************************* |
| * Copyright (c) 2011, 2022 Willink Transformations and others. |
| * All rights reserved. This program and the accompanying materials |
| * are made available under the terms of the Eclipse Public License v2.0 |
| * which accompanies this distribution, and is available at |
| * http://www.eclipse.org/legal/epl-v20.html |
| * |
| * Contributors: |
| * E.D.Willink - initial API and implementation |
| *******************************************************************************/ |
| grammar InternalOCLinEcore; |
| |
| options { |
| superClass=AbstractInternalAntlrParser; |
| backtrack=true; |
| |
| } |
| |
| @lexer::header { |
| package org.eclipse.ocl.xtext.oclinecore.parser.antlr.internal; |
| |
| // Hack: Use our own Lexer superclass by means of import. |
| // Currently there is no other way to specify the superclass for the lexer. |
| import org.eclipse.xtext.parser.antlr.Lexer; |
| } |
| |
| @parser::header { |
| package org.eclipse.ocl.xtext.oclinecore.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.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.ocl.xtext.oclinecore.services.OCLinEcoreGrammarAccess; |
| |
| } |
| |
| @parser::members { |
| |
| /* |
| This grammar contains a lot of empty actions to work around a bug in ANTLR. |
| Otherwise the ANTLR tool will create synpreds that cannot be compiled in some rare cases. |
| */ |
| |
| private OCLinEcoreGrammarAccess grammarAccess; |
| |
| public InternalOCLinEcoreParser(TokenStream input, OCLinEcoreGrammarAccess grammarAccess) { |
| this(input); |
| this.grammarAccess = grammarAccess; |
| registerRules(grammarAccess.getGrammar()); |
| } |
| |
| @Override |
| protected String getFirstRuleName() { |
| return "TopLevelCS"; |
| } |
| |
| @Override |
| protected OCLinEcoreGrammarAccess getGrammarAccess() { |
| return grammarAccess; |
| } |
| } |
| |
| @rulecatch { |
| catch (RecognitionException re) { |
| recover(input,re); |
| appendSkippedTokens(); |
| } |
| } |
| |
| |
| |
| |
| // Entry rule entryRuleTopLevelCS |
| entryRuleTopLevelCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getTopLevelCSRule()); } |
| iv_ruleTopLevelCS=ruleTopLevelCS |
| { $current=$iv_ruleTopLevelCS.current; } |
| EOF |
| ; |
| |
| // Rule TopLevelCS |
| ruleTopLevelCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| (( |
| { |
| /* */ |
| } |
| { |
| $current = forceCreateModelElement( |
| grammarAccess.getTopLevelCSAccess().getTopLevelCSAction_0(), |
| $current); |
| } |
| )( otherlv_1='module' |
| { |
| newLeafNode(otherlv_1, grammarAccess.getTopLevelCSAccess().getModuleKeyword_1_0()); |
| } |
| |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getTopLevelCSAccess().getUnrestrictedNameParserRuleCall_1_1()); |
| } |
| ruleUnrestrictedName |
| { |
| afterParserOrEnumRuleCall(); |
| } |
| )?( |
| ( |
| { |
| newCompositeNode(grammarAccess.getTopLevelCSAccess().getOwnedImportsImportCSParserRuleCall_2_0()); |
| } |
| lv_ownedImports_3_0=ruleImportCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getTopLevelCSRule()); |
| } |
| add( |
| $current, |
| "ownedImports", |
| lv_ownedImports_3_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.ImportCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )*( |
| ( |
| { |
| newCompositeNode(grammarAccess.getTopLevelCSAccess().getOwnedPackagesPackageCSParserRuleCall_3_0()); |
| } |
| lv_ownedPackages_4_0=rulePackageCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getTopLevelCSRule()); |
| } |
| add( |
| $current, |
| "ownedPackages", |
| lv_ownedPackages_4_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.PackageCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )*) |
| ; |
| |
| |
| |
| |
| |
| |
| |
| // Entry rule entryRuleSIGNED |
| entryRuleSIGNED returns [String current=null] |
| : |
| { newCompositeNode(grammarAccess.getSIGNEDRule()); } |
| iv_ruleSIGNED=ruleSIGNED |
| { $current=$iv_ruleSIGNED.current.getText(); } |
| EOF |
| ; |
| |
| // Rule SIGNED |
| ruleSIGNED returns [AntlrDatatypeRuleToken current=new AntlrDatatypeRuleToken()] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| (( |
| kw='-' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getSIGNEDAccess().getHyphenMinusKeyword_0()); |
| } |
| )? this_INT_1=RULE_INT { |
| $current.merge(this_INT_1); |
| } |
| |
| { |
| newLeafNode(this_INT_1, grammarAccess.getSIGNEDAccess().getINTTerminalRuleCall_1()); |
| } |
| ) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleEnumerationLiteralName |
| entryRuleEnumerationLiteralName returns [String current=null] |
| : |
| { newCompositeNode(grammarAccess.getEnumerationLiteralNameRule()); } |
| iv_ruleEnumerationLiteralName=ruleEnumerationLiteralName |
| { $current=$iv_ruleEnumerationLiteralName.current.getText(); } |
| EOF |
| ; |
| |
| // Rule EnumerationLiteralName |
| ruleEnumerationLiteralName returns [AntlrDatatypeRuleToken current=new AntlrDatatypeRuleToken()] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| ( |
| { |
| newCompositeNode(grammarAccess.getEnumerationLiteralNameAccess().getEssentialOCLUnrestrictedNameParserRuleCall_0()); |
| } |
| this_EssentialOCLUnrestrictedName_0=ruleEssentialOCLUnrestrictedName { |
| $current.merge(this_EssentialOCLUnrestrictedName_0); |
| } |
| |
| { |
| afterParserOrEnumRuleCall(); |
| } |
| |
| | |
| kw='abstract' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getAbstractKeyword_1()); |
| } |
| |
| | |
| kw='attribute' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getAttributeKeyword_2()); |
| } |
| |
| | |
| kw='body' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getBodyKeyword_3()); |
| } |
| |
| | |
| kw='callable' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getCallableKeyword_4()); |
| } |
| |
| | |
| kw='class' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getClassKeyword_5()); |
| } |
| |
| | |
| kw='composes' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getComposesKeyword_6()); |
| } |
| |
| | |
| kw='datatype' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getDatatypeKeyword_7()); |
| } |
| |
| | |
| kw='definition' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getDefinitionKeyword_8()); |
| } |
| |
| | |
| kw='derivation' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getDerivationKeyword_9()); |
| } |
| |
| | |
| kw='derived' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getDerivedKeyword_10()); |
| } |
| |
| | |
| kw='enum' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getEnumKeyword_11()); |
| } |
| |
| | |
| kw='extends' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getExtendsKeyword_12()); |
| } |
| |
| | |
| kw='id' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getIdKeyword_13()); |
| } |
| |
| | |
| kw='import' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getImportKeyword_14()); |
| } |
| |
| | |
| kw='initial' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getInitialKeyword_15()); |
| } |
| |
| | |
| kw='interface' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getInterfaceKeyword_16()); |
| } |
| |
| | |
| kw='key' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getKeyKeyword_17()); |
| } |
| |
| | |
| kw='library' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getLibraryKeyword_18()); |
| } |
| |
| | |
| kw='module' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getModuleKeyword_19()); |
| } |
| |
| | |
| kw='operation' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getOperationKeyword_20()); |
| } |
| |
| | |
| kw='ordered' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getOrderedKeyword_21()); |
| } |
| |
| | |
| kw='package' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getPackageKeyword_22()); |
| } |
| |
| | |
| kw='postcondition' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getPostconditionKeyword_23()); |
| } |
| |
| | |
| kw='precondition' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getPreconditionKeyword_24()); |
| } |
| |
| | |
| kw='primitive' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getPrimitiveKeyword_25()); |
| } |
| |
| | |
| kw='property' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getPropertyKeyword_26()); |
| } |
| |
| | |
| kw='readonly' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getReadonlyKeyword_27()); |
| } |
| |
| | |
| kw='reference' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getReferenceKeyword_28()); |
| } |
| |
| | |
| kw='resolve' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getResolveKeyword_29()); |
| } |
| |
| | |
| kw='static' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getStaticKeyword_30()); |
| } |
| |
| | |
| kw='throws' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getThrowsKeyword_31()); |
| } |
| |
| | |
| kw='transient' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getTransientKeyword_32()); |
| } |
| |
| | |
| kw='unique' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getUniqueKeyword_33()); |
| } |
| |
| | |
| kw='unsettable' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getUnsettableKeyword_34()); |
| } |
| |
| | |
| kw='volatile' |
| { |
| $current.merge(kw); |
| newLeafNode(kw, grammarAccess.getEnumerationLiteralNameAccess().getVolatileKeyword_35()); |
| } |
| ) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleInvariantConstraintCS |
| entryRuleInvariantConstraintCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getInvariantConstraintCSRule()); } |
| iv_ruleInvariantConstraintCS=ruleInvariantConstraintCS |
| { $current=$iv_ruleInvariantConstraintCS.current; } |
| EOF |
| ; |
| |
| // Rule InvariantConstraintCS |
| ruleInvariantConstraintCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| (( |
| ( |
| lv_isCallable_0_0= 'callable' |
| { |
| newLeafNode(lv_isCallable_0_0, grammarAccess.getInvariantConstraintCSAccess().getIsCallableCallableKeyword_0_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getInvariantConstraintCSRule()); |
| } |
| setWithLastConsumed($current, "isCallable", true, "callable"); |
| } |
| |
| ) |
| )?( |
| ( |
| lv_stereotype_1_0= 'invariant' |
| { |
| newLeafNode(lv_stereotype_1_0, grammarAccess.getInvariantConstraintCSAccess().getStereotypeInvariantKeyword_1_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getInvariantConstraintCSRule()); |
| } |
| setWithLastConsumed($current, "stereotype", lv_stereotype_1_0, "invariant"); |
| } |
| |
| ) |
| )(( |
| ( |
| { |
| newCompositeNode(grammarAccess.getInvariantConstraintCSAccess().getNameUnrestrictedNameParserRuleCall_2_0_0()); |
| } |
| lv_name_2_0=ruleUnrestrictedName { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getInvariantConstraintCSRule()); |
| } |
| set( |
| $current, |
| "name", |
| lv_name_2_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.UnrestrictedName"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )( otherlv_3='(' |
| { |
| newLeafNode(otherlv_3, grammarAccess.getInvariantConstraintCSAccess().getLeftParenthesisKeyword_2_1_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getInvariantConstraintCSAccess().getOwnedMessageSpecificationSpecificationCSParserRuleCall_2_1_1_0()); |
| } |
| lv_ownedMessageSpecification_4_0=ruleSpecificationCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getInvariantConstraintCSRule()); |
| } |
| set( |
| $current, |
| "ownedMessageSpecification", |
| lv_ownedMessageSpecification_4_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.SpecificationCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) otherlv_5=')' |
| { |
| newLeafNode(otherlv_5, grammarAccess.getInvariantConstraintCSAccess().getRightParenthesisKeyword_2_1_2()); |
| } |
| )?)?(( otherlv_6=':' |
| { |
| newLeafNode(otherlv_6, grammarAccess.getInvariantConstraintCSAccess().getColonKeyword_3_0_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getInvariantConstraintCSAccess().getOwnedSpecificationSpecificationCSParserRuleCall_3_0_1_0()); |
| } |
| lv_ownedSpecification_7_0=ruleSpecificationCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getInvariantConstraintCSRule()); |
| } |
| set( |
| $current, |
| "ownedSpecification", |
| lv_ownedSpecification_7_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.SpecificationCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )? otherlv_8=';' |
| { |
| newLeafNode(otherlv_8, grammarAccess.getInvariantConstraintCSAccess().getSemicolonKeyword_3_0_2()); |
| } |
| ) |
| | otherlv_9=';' |
| { |
| newLeafNode(otherlv_9, grammarAccess.getInvariantConstraintCSAccess().getSemicolonKeyword_3_1()); |
| } |
| )) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRulePostconditionConstraintCS |
| entryRulePostconditionConstraintCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getPostconditionConstraintCSRule()); } |
| iv_rulePostconditionConstraintCS=rulePostconditionConstraintCS |
| { $current=$iv_rulePostconditionConstraintCS.current; } |
| EOF |
| ; |
| |
| // Rule PostconditionConstraintCS |
| rulePostconditionConstraintCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| (( |
| ( |
| lv_stereotype_0_0= 'postcondition' |
| { |
| newLeafNode(lv_stereotype_0_0, grammarAccess.getPostconditionConstraintCSAccess().getStereotypePostconditionKeyword_0_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getPostconditionConstraintCSRule()); |
| } |
| setWithLastConsumed($current, "stereotype", lv_stereotype_0_0, "postcondition"); |
| } |
| |
| ) |
| )(( |
| ( |
| { |
| newCompositeNode(grammarAccess.getPostconditionConstraintCSAccess().getNameUnrestrictedNameParserRuleCall_1_0_0()); |
| } |
| lv_name_1_0=ruleUnrestrictedName { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getPostconditionConstraintCSRule()); |
| } |
| set( |
| $current, |
| "name", |
| lv_name_1_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.UnrestrictedName"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )( otherlv_2='(' |
| { |
| newLeafNode(otherlv_2, grammarAccess.getPostconditionConstraintCSAccess().getLeftParenthesisKeyword_1_1_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getPostconditionConstraintCSAccess().getOwnedMessageSpecificationSpecificationCSParserRuleCall_1_1_1_0()); |
| } |
| lv_ownedMessageSpecification_3_0=ruleSpecificationCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getPostconditionConstraintCSRule()); |
| } |
| set( |
| $current, |
| "ownedMessageSpecification", |
| lv_ownedMessageSpecification_3_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.SpecificationCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) otherlv_4=')' |
| { |
| newLeafNode(otherlv_4, grammarAccess.getPostconditionConstraintCSAccess().getRightParenthesisKeyword_1_1_2()); |
| } |
| )?)? otherlv_5=':' |
| { |
| newLeafNode(otherlv_5, grammarAccess.getPostconditionConstraintCSAccess().getColonKeyword_2()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getPostconditionConstraintCSAccess().getOwnedSpecificationSpecificationCSParserRuleCall_3_0()); |
| } |
| lv_ownedSpecification_6_0=ruleSpecificationCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getPostconditionConstraintCSRule()); |
| } |
| set( |
| $current, |
| "ownedSpecification", |
| lv_ownedSpecification_6_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.SpecificationCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )? otherlv_7=';' |
| { |
| newLeafNode(otherlv_7, grammarAccess.getPostconditionConstraintCSAccess().getSemicolonKeyword_4()); |
| } |
| ) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRulePreconditionConstraintCS |
| entryRulePreconditionConstraintCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getPreconditionConstraintCSRule()); } |
| iv_rulePreconditionConstraintCS=rulePreconditionConstraintCS |
| { $current=$iv_rulePreconditionConstraintCS.current; } |
| EOF |
| ; |
| |
| // Rule PreconditionConstraintCS |
| rulePreconditionConstraintCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| (( |
| ( |
| lv_stereotype_0_0= 'precondition' |
| { |
| newLeafNode(lv_stereotype_0_0, grammarAccess.getPreconditionConstraintCSAccess().getStereotypePreconditionKeyword_0_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getPreconditionConstraintCSRule()); |
| } |
| setWithLastConsumed($current, "stereotype", lv_stereotype_0_0, "precondition"); |
| } |
| |
| ) |
| )(( |
| ( |
| { |
| newCompositeNode(grammarAccess.getPreconditionConstraintCSAccess().getNameUnrestrictedNameParserRuleCall_1_0_0()); |
| } |
| lv_name_1_0=ruleUnrestrictedName { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getPreconditionConstraintCSRule()); |
| } |
| set( |
| $current, |
| "name", |
| lv_name_1_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.UnrestrictedName"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )( otherlv_2='(' |
| { |
| newLeafNode(otherlv_2, grammarAccess.getPreconditionConstraintCSAccess().getLeftParenthesisKeyword_1_1_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getPreconditionConstraintCSAccess().getOwnedMessageSpecificationSpecificationCSParserRuleCall_1_1_1_0()); |
| } |
| lv_ownedMessageSpecification_3_0=ruleSpecificationCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getPreconditionConstraintCSRule()); |
| } |
| set( |
| $current, |
| "ownedMessageSpecification", |
| lv_ownedMessageSpecification_3_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.SpecificationCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) otherlv_4=')' |
| { |
| newLeafNode(otherlv_4, grammarAccess.getPreconditionConstraintCSAccess().getRightParenthesisKeyword_1_1_2()); |
| } |
| )?)? otherlv_5=':' |
| { |
| newLeafNode(otherlv_5, grammarAccess.getPreconditionConstraintCSAccess().getColonKeyword_2()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getPreconditionConstraintCSAccess().getOwnedSpecificationSpecificationCSParserRuleCall_3_0()); |
| } |
| lv_ownedSpecification_6_0=ruleSpecificationCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getPreconditionConstraintCSRule()); |
| } |
| set( |
| $current, |
| "ownedSpecification", |
| lv_ownedSpecification_6_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.SpecificationCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )? otherlv_7=';' |
| { |
| newLeafNode(otherlv_7, grammarAccess.getPreconditionConstraintCSAccess().getSemicolonKeyword_4()); |
| } |
| ) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleAnnotationCS |
| entryRuleAnnotationCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getAnnotationCSRule()); } |
| iv_ruleAnnotationCS=ruleAnnotationCS |
| { $current=$iv_ruleAnnotationCS.current; } |
| EOF |
| ; |
| |
| // Rule AnnotationCS |
| ruleAnnotationCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| (( |
| { |
| /* */ |
| } |
| { |
| $current = forceCreateModelElement( |
| grammarAccess.getAnnotationCSAccess().getAnnotationCSAction_0(), |
| $current); |
| } |
| ) otherlv_1='annotation' |
| { |
| newLeafNode(otherlv_1, grammarAccess.getAnnotationCSAccess().getAnnotationKeyword_1()); |
| } |
| ( |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getAnnotationCSAccess().getNameUnrestrictedNameParserRuleCall_2_0_0()); |
| } |
| lv_name_2_1=ruleUnrestrictedName { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getAnnotationCSRule()); |
| } |
| set( |
| $current, |
| "name", |
| lv_name_2_1, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.UnrestrictedName"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| | lv_name_2_2=RULE_SINGLE_QUOTED_STRING |
| { |
| newLeafNode(lv_name_2_2, grammarAccess.getAnnotationCSAccess().getNameSINGLE_QUOTED_STRINGTerminalRuleCall_2_0_1()); |
| } |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAnnotationCSRule()); |
| } |
| setWithLastConsumed( |
| $current, |
| "name", |
| lv_name_2_2, |
| "org.eclipse.ocl.xtext.base.Base.SINGLE_QUOTED_STRING"); |
| } |
| |
| ) |
| |
| ) |
| )?( otherlv_3='(' |
| { |
| newLeafNode(otherlv_3, grammarAccess.getAnnotationCSAccess().getLeftParenthesisKeyword_3_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getAnnotationCSAccess().getOwnedDetailsDetailCSParserRuleCall_3_1_0()); |
| } |
| lv_ownedDetails_4_0=ruleDetailCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getAnnotationCSRule()); |
| } |
| add( |
| $current, |
| "ownedDetails", |
| lv_ownedDetails_4_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.DetailCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )( otherlv_5=',' |
| { |
| newLeafNode(otherlv_5, grammarAccess.getAnnotationCSAccess().getCommaKeyword_3_2_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getAnnotationCSAccess().getOwnedDetailsDetailCSParserRuleCall_3_2_1_0()); |
| } |
| lv_ownedDetails_6_0=ruleDetailCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getAnnotationCSRule()); |
| } |
| add( |
| $current, |
| "ownedDetails", |
| lv_ownedDetails_6_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.DetailCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ))* otherlv_7=')' |
| { |
| newLeafNode(otherlv_7, grammarAccess.getAnnotationCSAccess().getRightParenthesisKeyword_3_3()); |
| } |
| )?(( otherlv_8='{' |
| { |
| newLeafNode(otherlv_8, grammarAccess.getAnnotationCSAccess().getLeftCurlyBracketKeyword_4_0_0()); |
| } |
| (( |
| ( |
| { |
| newCompositeNode(grammarAccess.getAnnotationCSAccess().getOwnedAnnotationsAnnotationElementCSParserRuleCall_4_0_1_0_0()); |
| } |
| lv_ownedAnnotations_9_0=ruleAnnotationElementCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getAnnotationCSRule()); |
| } |
| add( |
| $current, |
| "ownedAnnotations", |
| lv_ownedAnnotations_9_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.AnnotationElementCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| { |
| newCompositeNode(grammarAccess.getAnnotationCSAccess().getOwnedContentsModelElementCSParserRuleCall_4_0_1_1_0()); |
| } |
| lv_ownedContents_10_0=ruleModelElementCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getAnnotationCSRule()); |
| } |
| add( |
| $current, |
| "ownedContents", |
| lv_ownedContents_10_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.ModelElementCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| { |
| newCompositeNode(grammarAccess.getAnnotationCSAccess().getOwnedReferencesModelElementRefCSParserRuleCall_4_0_1_2_0()); |
| } |
| lv_ownedReferences_11_0=ruleModelElementRefCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getAnnotationCSRule()); |
| } |
| add( |
| $current, |
| "ownedReferences", |
| lv_ownedReferences_11_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.ModelElementRefCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ))+ otherlv_12='}' |
| { |
| newLeafNode(otherlv_12, grammarAccess.getAnnotationCSAccess().getRightCurlyBracketKeyword_4_0_2()); |
| } |
| ) |
| | otherlv_13=';' |
| { |
| newLeafNode(otherlv_13, grammarAccess.getAnnotationCSAccess().getSemicolonKeyword_4_1()); |
| } |
| )) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleAnnotationElementCS |
| entryRuleAnnotationElementCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getAnnotationElementCSRule()); } |
| iv_ruleAnnotationElementCS=ruleAnnotationElementCS |
| { $current=$iv_ruleAnnotationElementCS.current; } |
| EOF |
| ; |
| |
| // Rule AnnotationElementCS |
| ruleAnnotationElementCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| ( |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getAnnotationElementCSAccess().getAnnotationCSParserRuleCall_0()); |
| } |
| this_AnnotationCS_0=ruleAnnotationCS |
| { |
| $current = $this_AnnotationCS_0.current; |
| afterParserOrEnumRuleCall(); |
| } |
| |
| | |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getAnnotationElementCSAccess().getDocumentationCSParserRuleCall_1()); |
| } |
| this_DocumentationCS_1=ruleDocumentationCS |
| { |
| $current = $this_DocumentationCS_1.current; |
| afterParserOrEnumRuleCall(); |
| } |
| |
| | |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getAnnotationElementCSAccess().getSysMLCSParserRuleCall_2()); |
| } |
| this_SysMLCS_2=ruleSysMLCS |
| { |
| $current = $this_SysMLCS_2.current; |
| afterParserOrEnumRuleCall(); |
| } |
| ) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleAttributeCS |
| entryRuleAttributeCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getAttributeCSRule()); } |
| iv_ruleAttributeCS=ruleAttributeCS |
| { $current=$iv_ruleAttributeCS.current; } |
| EOF |
| ; |
| |
| // Rule AttributeCS |
| ruleAttributeCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| (((( |
| ( |
| lv_qualifiers_0_0= 'static' |
| { |
| newLeafNode(lv_qualifiers_0_0, grammarAccess.getAttributeCSAccess().getQualifiersStaticKeyword_0_0_0_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_0_0, "static"); |
| } |
| |
| ) |
| )( |
| ( |
| lv_qualifiers_1_0= 'definition' |
| { |
| newLeafNode(lv_qualifiers_1_0, grammarAccess.getAttributeCSAccess().getQualifiersDefinitionKeyword_0_0_1_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_1_0, "definition"); |
| } |
| |
| ) |
| )?) |
| |(( |
| ( |
| lv_qualifiers_2_0= 'definition' |
| { |
| newLeafNode(lv_qualifiers_2_0, grammarAccess.getAttributeCSAccess().getQualifiersDefinitionKeyword_0_1_0_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_2_0, "definition"); |
| } |
| |
| ) |
| )( |
| ( |
| lv_qualifiers_3_0= 'static' |
| { |
| newLeafNode(lv_qualifiers_3_0, grammarAccess.getAttributeCSAccess().getQualifiersStaticKeyword_0_1_1_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_3_0, "static"); |
| } |
| |
| ) |
| )?))? otherlv_4='attribute' |
| { |
| newLeafNode(otherlv_4, grammarAccess.getAttributeCSAccess().getAttributeKeyword_1()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getAttributeCSAccess().getNameUnrestrictedNameParserRuleCall_2_0()); |
| } |
| lv_name_5_0=ruleUnrestrictedName { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getAttributeCSRule()); |
| } |
| set( |
| $current, |
| "name", |
| lv_name_5_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.UnrestrictedName"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )( otherlv_6=':' |
| { |
| newLeafNode(otherlv_6, grammarAccess.getAttributeCSAccess().getColonKeyword_3_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getAttributeCSAccess().getOwnedTypeTypedMultiplicityRefCSParserRuleCall_3_1_0()); |
| } |
| lv_ownedType_7_0=ruleTypedMultiplicityRefCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getAttributeCSRule()); |
| } |
| set( |
| $current, |
| "ownedType", |
| lv_ownedType_7_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.TypedMultiplicityRefCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ))?( otherlv_8='=' |
| { |
| newLeafNode(otherlv_8, grammarAccess.getAttributeCSAccess().getEqualsSignKeyword_4_0()); |
| } |
| ( |
| ( |
| lv_default_9_0=RULE_SINGLE_QUOTED_STRING |
| { |
| newLeafNode(lv_default_9_0, grammarAccess.getAttributeCSAccess().getDefaultSINGLE_QUOTED_STRINGTerminalRuleCall_4_1_0()); |
| } |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| setWithLastConsumed( |
| $current, |
| "default", |
| lv_default_9_0, |
| "org.eclipse.ocl.xtext.base.Base.SINGLE_QUOTED_STRING"); |
| } |
| |
| ) |
| ))?( otherlv_10='{' |
| { |
| newLeafNode(otherlv_10, grammarAccess.getAttributeCSAccess().getLeftCurlyBracketKeyword_5_0()); |
| } |
| ((( |
| ( |
| lv_qualifiers_11_0= 'derived' |
| { |
| newLeafNode(lv_qualifiers_11_0, grammarAccess.getAttributeCSAccess().getQualifiersDerivedKeyword_5_1_0_0_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_11_0, "derived"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_12_0= '!derived' |
| { |
| newLeafNode(lv_qualifiers_12_0, grammarAccess.getAttributeCSAccess().getQualifiersDerivedKeyword_5_1_0_1_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_12_0, "!derived"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_13_0= 'id' |
| { |
| newLeafNode(lv_qualifiers_13_0, grammarAccess.getAttributeCSAccess().getQualifiersIdKeyword_5_1_0_2_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_13_0, "id"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_14_0= '!id' |
| { |
| newLeafNode(lv_qualifiers_14_0, grammarAccess.getAttributeCSAccess().getQualifiersIdKeyword_5_1_0_3_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_14_0, "!id"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_15_0= 'ordered' |
| { |
| newLeafNode(lv_qualifiers_15_0, grammarAccess.getAttributeCSAccess().getQualifiersOrderedKeyword_5_1_0_4_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_15_0, "ordered"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_16_0= '!ordered' |
| { |
| newLeafNode(lv_qualifiers_16_0, grammarAccess.getAttributeCSAccess().getQualifiersOrderedKeyword_5_1_0_5_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_16_0, "!ordered"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_17_0= 'readonly' |
| { |
| newLeafNode(lv_qualifiers_17_0, grammarAccess.getAttributeCSAccess().getQualifiersReadonlyKeyword_5_1_0_6_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_17_0, "readonly"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_18_0= '!readonly' |
| { |
| newLeafNode(lv_qualifiers_18_0, grammarAccess.getAttributeCSAccess().getQualifiersReadonlyKeyword_5_1_0_7_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_18_0, "!readonly"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_19_0= 'transient' |
| { |
| newLeafNode(lv_qualifiers_19_0, grammarAccess.getAttributeCSAccess().getQualifiersTransientKeyword_5_1_0_8_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_19_0, "transient"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_20_0= '!transient' |
| { |
| newLeafNode(lv_qualifiers_20_0, grammarAccess.getAttributeCSAccess().getQualifiersTransientKeyword_5_1_0_9_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_20_0, "!transient"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_21_0= 'unique' |
| { |
| newLeafNode(lv_qualifiers_21_0, grammarAccess.getAttributeCSAccess().getQualifiersUniqueKeyword_5_1_0_10_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_21_0, "unique"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_22_0= '!unique' |
| { |
| newLeafNode(lv_qualifiers_22_0, grammarAccess.getAttributeCSAccess().getQualifiersUniqueKeyword_5_1_0_11_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_22_0, "!unique"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_23_0= 'unsettable' |
| { |
| newLeafNode(lv_qualifiers_23_0, grammarAccess.getAttributeCSAccess().getQualifiersUnsettableKeyword_5_1_0_12_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_23_0, "unsettable"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_24_0= '!unsettable' |
| { |
| newLeafNode(lv_qualifiers_24_0, grammarAccess.getAttributeCSAccess().getQualifiersUnsettableKeyword_5_1_0_13_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_24_0, "!unsettable"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_25_0= 'volatile' |
| { |
| newLeafNode(lv_qualifiers_25_0, grammarAccess.getAttributeCSAccess().getQualifiersVolatileKeyword_5_1_0_14_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_25_0, "volatile"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_26_0= '!volatile' |
| { |
| newLeafNode(lv_qualifiers_26_0, grammarAccess.getAttributeCSAccess().getQualifiersVolatileKeyword_5_1_0_15_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getAttributeCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_26_0, "!volatile"); |
| } |
| |
| ) |
| ))( otherlv_27=',' |
| { |
| newLeafNode(otherlv_27, grammarAccess.getAttributeCSAccess().getCommaKeyword_5_1_1()); |
| } |
| )?)+ otherlv_28='}' |
| { |
| newLeafNode(otherlv_28, grammarAccess.getAttributeCSAccess().getRightCurlyBracketKeyword_5_2()); |
| } |
| )?(( otherlv_29='{' |
| { |
| newLeafNode(otherlv_29, grammarAccess.getAttributeCSAccess().getLeftCurlyBracketKeyword_6_0_0()); |
| } |
| (( |
| ( |
| { |
| newCompositeNode(grammarAccess.getAttributeCSAccess().getOwnedAnnotationsAnnotationElementCSParserRuleCall_6_0_1_0_0()); |
| } |
| lv_ownedAnnotations_30_0=ruleAnnotationElementCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getAttributeCSRule()); |
| } |
| add( |
| $current, |
| "ownedAnnotations", |
| lv_ownedAnnotations_30_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.AnnotationElementCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) |
| |( otherlv_31='initial' |
| { |
| newLeafNode(otherlv_31, grammarAccess.getAttributeCSAccess().getInitialKeyword_6_0_1_1_0()); |
| } |
| ( |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getAttributeCSAccess().getUnrestrictedNameParserRuleCall_6_0_1_1_1()); |
| } |
| ruleUnrestrictedName |
| { |
| afterParserOrEnumRuleCall(); |
| } |
| )? otherlv_33=':' |
| { |
| newLeafNode(otherlv_33, grammarAccess.getAttributeCSAccess().getColonKeyword_6_0_1_1_2()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getAttributeCSAccess().getOwnedDefaultExpressionsSpecificationCSParserRuleCall_6_0_1_1_3_0()); |
| } |
| lv_ownedDefaultExpressions_34_0=ruleSpecificationCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getAttributeCSRule()); |
| } |
| add( |
| $current, |
| "ownedDefaultExpressions", |
| lv_ownedDefaultExpressions_34_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.SpecificationCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )? otherlv_35=';' |
| { |
| newLeafNode(otherlv_35, grammarAccess.getAttributeCSAccess().getSemicolonKeyword_6_0_1_1_4()); |
| } |
| ) |
| |( otherlv_36='derivation' |
| { |
| newLeafNode(otherlv_36, grammarAccess.getAttributeCSAccess().getDerivationKeyword_6_0_1_2_0()); |
| } |
| ( |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getAttributeCSAccess().getUnrestrictedNameParserRuleCall_6_0_1_2_1()); |
| } |
| ruleUnrestrictedName |
| { |
| afterParserOrEnumRuleCall(); |
| } |
| )? otherlv_38=':' |
| { |
| newLeafNode(otherlv_38, grammarAccess.getAttributeCSAccess().getColonKeyword_6_0_1_2_2()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getAttributeCSAccess().getOwnedDefaultExpressionsSpecificationCSParserRuleCall_6_0_1_2_3_0()); |
| } |
| lv_ownedDefaultExpressions_39_0=ruleSpecificationCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getAttributeCSRule()); |
| } |
| add( |
| $current, |
| "ownedDefaultExpressions", |
| lv_ownedDefaultExpressions_39_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.SpecificationCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )? otherlv_40=';' |
| { |
| newLeafNode(otherlv_40, grammarAccess.getAttributeCSAccess().getSemicolonKeyword_6_0_1_2_4()); |
| } |
| ))* otherlv_41='}' |
| { |
| newLeafNode(otherlv_41, grammarAccess.getAttributeCSAccess().getRightCurlyBracketKeyword_6_0_2()); |
| } |
| ) |
| | otherlv_42=';' |
| { |
| newLeafNode(otherlv_42, grammarAccess.getAttributeCSAccess().getSemicolonKeyword_6_1()); |
| } |
| )) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleClassCS |
| entryRuleClassCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getClassCSRule()); } |
| iv_ruleClassCS=ruleClassCS |
| { $current=$iv_ruleClassCS.current; } |
| EOF |
| ; |
| |
| // Rule ClassCS |
| ruleClassCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| ( |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getClassCSAccess().getStructuredClassCSParserRuleCall_0()); |
| } |
| this_StructuredClassCS_0=ruleStructuredClassCS |
| { |
| $current = $this_StructuredClassCS_0.current; |
| afterParserOrEnumRuleCall(); |
| } |
| |
| | |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getClassCSAccess().getDataTypeCSParserRuleCall_1()); |
| } |
| this_DataTypeCS_1=ruleDataTypeCS |
| { |
| $current = $this_DataTypeCS_1.current; |
| afterParserOrEnumRuleCall(); |
| } |
| |
| | |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getClassCSAccess().getEnumerationCSParserRuleCall_2()); |
| } |
| this_EnumerationCS_2=ruleEnumerationCS |
| { |
| $current = $this_EnumerationCS_2.current; |
| afterParserOrEnumRuleCall(); |
| } |
| ) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleDataTypeCS |
| entryRuleDataTypeCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getDataTypeCSRule()); } |
| iv_ruleDataTypeCS=ruleDataTypeCS |
| { $current=$iv_ruleDataTypeCS.current; } |
| EOF |
| ; |
| |
| // Rule DataTypeCS |
| ruleDataTypeCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| (( |
| ( |
| lv_isPrimitive_0_0= 'primitive' |
| { |
| newLeafNode(lv_isPrimitive_0_0, grammarAccess.getDataTypeCSAccess().getIsPrimitivePrimitiveKeyword_0_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getDataTypeCSRule()); |
| } |
| setWithLastConsumed($current, "isPrimitive", true, "primitive"); |
| } |
| |
| ) |
| )? otherlv_1='datatype' |
| { |
| newLeafNode(otherlv_1, grammarAccess.getDataTypeCSAccess().getDatatypeKeyword_1()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getDataTypeCSAccess().getNameUnrestrictedNameParserRuleCall_2_0()); |
| } |
| lv_name_2_0=ruleUnrestrictedName { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getDataTypeCSRule()); |
| } |
| set( |
| $current, |
| "name", |
| lv_name_2_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.UnrestrictedName"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )( |
| ( |
| { |
| newCompositeNode(grammarAccess.getDataTypeCSAccess().getOwnedSignatureTemplateSignatureCSParserRuleCall_3_0()); |
| } |
| lv_ownedSignature_3_0=ruleTemplateSignatureCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getDataTypeCSRule()); |
| } |
| set( |
| $current, |
| "ownedSignature", |
| lv_ownedSignature_3_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.TemplateSignatureCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )?( otherlv_4=':' |
| { |
| newLeafNode(otherlv_4, grammarAccess.getDataTypeCSAccess().getColonKeyword_4_0()); |
| } |
| ( |
| ( |
| lv_instanceClassName_5_0=RULE_SINGLE_QUOTED_STRING |
| { |
| newLeafNode(lv_instanceClassName_5_0, grammarAccess.getDataTypeCSAccess().getInstanceClassNameSINGLE_QUOTED_STRINGTerminalRuleCall_4_1_0()); |
| } |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getDataTypeCSRule()); |
| } |
| setWithLastConsumed( |
| $current, |
| "instanceClassName", |
| lv_instanceClassName_5_0, |
| "org.eclipse.ocl.xtext.base.Base.SINGLE_QUOTED_STRING"); |
| } |
| |
| ) |
| ))?( otherlv_6='{' |
| { |
| newLeafNode(otherlv_6, grammarAccess.getDataTypeCSAccess().getLeftCurlyBracketKeyword_5_0()); |
| } |
| (( |
| ( |
| lv_isSerializable_7_0= 'serializable' |
| { |
| newLeafNode(lv_isSerializable_7_0, grammarAccess.getDataTypeCSAccess().getIsSerializableSerializableKeyword_5_1_0_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getDataTypeCSRule()); |
| } |
| setWithLastConsumed($current, "isSerializable", true, "serializable"); |
| } |
| |
| ) |
| ) |
| | otherlv_8='!serializable' |
| { |
| newLeafNode(otherlv_8, grammarAccess.getDataTypeCSAccess().getSerializableKeyword_5_1_1()); |
| } |
| )? otherlv_9='}' |
| { |
| newLeafNode(otherlv_9, grammarAccess.getDataTypeCSAccess().getRightCurlyBracketKeyword_5_2()); |
| } |
| )?(( otherlv_10='{' |
| { |
| newLeafNode(otherlv_10, grammarAccess.getDataTypeCSAccess().getLeftCurlyBracketKeyword_6_0_0()); |
| } |
| (( |
| ( |
| { |
| newCompositeNode(grammarAccess.getDataTypeCSAccess().getOwnedAnnotationsAnnotationElementCSParserRuleCall_6_0_1_0_0()); |
| } |
| lv_ownedAnnotations_11_0=ruleAnnotationElementCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getDataTypeCSRule()); |
| } |
| add( |
| $current, |
| "ownedAnnotations", |
| lv_ownedAnnotations_11_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.AnnotationElementCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| { |
| newCompositeNode(grammarAccess.getDataTypeCSAccess().getOwnedConstraintsInvariantConstraintCSParserRuleCall_6_0_1_1_0()); |
| } |
| lv_ownedConstraints_12_0=ruleInvariantConstraintCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getDataTypeCSRule()); |
| } |
| add( |
| $current, |
| "ownedConstraints", |
| lv_ownedConstraints_12_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.InvariantConstraintCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ))* otherlv_13='}' |
| { |
| newLeafNode(otherlv_13, grammarAccess.getDataTypeCSAccess().getRightCurlyBracketKeyword_6_0_2()); |
| } |
| ) |
| | otherlv_14=';' |
| { |
| newLeafNode(otherlv_14, grammarAccess.getDataTypeCSAccess().getSemicolonKeyword_6_1()); |
| } |
| )) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleDetailCS |
| entryRuleDetailCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getDetailCSRule()); } |
| iv_ruleDetailCS=ruleDetailCS |
| { $current=$iv_ruleDetailCS.current; } |
| EOF |
| ; |
| |
| // Rule DetailCS |
| ruleDetailCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| (( |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getDetailCSAccess().getNameUnrestrictedNameParserRuleCall_0_0_0()); |
| } |
| lv_name_0_1=ruleUnrestrictedName { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getDetailCSRule()); |
| } |
| set( |
| $current, |
| "name", |
| lv_name_0_1, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.UnrestrictedName"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| | lv_name_0_2=RULE_SINGLE_QUOTED_STRING |
| { |
| newLeafNode(lv_name_0_2, grammarAccess.getDetailCSAccess().getNameSINGLE_QUOTED_STRINGTerminalRuleCall_0_0_1()); |
| } |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getDetailCSRule()); |
| } |
| setWithLastConsumed( |
| $current, |
| "name", |
| lv_name_0_2, |
| "org.eclipse.ocl.xtext.base.Base.SINGLE_QUOTED_STRING"); |
| } |
| |
| ) |
| |
| ) |
| ) otherlv_1='=' |
| { |
| newLeafNode(otherlv_1, grammarAccess.getDetailCSAccess().getEqualsSignKeyword_1()); |
| } |
| ( |
| ( |
| ( |
| lv_values_2_1=RULE_SINGLE_QUOTED_STRING |
| { |
| newLeafNode(lv_values_2_1, grammarAccess.getDetailCSAccess().getValuesSINGLE_QUOTED_STRINGTerminalRuleCall_2_0_0()); |
| } |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getDetailCSRule()); |
| } |
| addWithLastConsumed( |
| $current, |
| "values", |
| lv_values_2_1, |
| "org.eclipse.ocl.xtext.base.Base.SINGLE_QUOTED_STRING"); |
| } |
| |
| | lv_values_2_2=RULE_ML_SINGLE_QUOTED_STRING |
| { |
| newLeafNode(lv_values_2_2, grammarAccess.getDetailCSAccess().getValuesML_SINGLE_QUOTED_STRINGTerminalRuleCall_2_0_1()); |
| } |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getDetailCSRule()); |
| } |
| addWithLastConsumed( |
| $current, |
| "values", |
| lv_values_2_2, |
| "org.eclipse.ocl.xtext.base.Base.ML_SINGLE_QUOTED_STRING"); |
| } |
| |
| ) |
| |
| ) |
| )*) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleDocumentationCS |
| entryRuleDocumentationCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getDocumentationCSRule()); } |
| iv_ruleDocumentationCS=ruleDocumentationCS |
| { $current=$iv_ruleDocumentationCS.current; } |
| EOF |
| ; |
| |
| // Rule DocumentationCS |
| ruleDocumentationCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| (( |
| { |
| /* */ |
| } |
| { |
| $current = forceCreateModelElement( |
| grammarAccess.getDocumentationCSAccess().getDocumentationCSAction_0(), |
| $current); |
| } |
| ) otherlv_1='documentation' |
| { |
| newLeafNode(otherlv_1, grammarAccess.getDocumentationCSAccess().getDocumentationKeyword_1()); |
| } |
| ( |
| ( |
| lv_value_2_0=RULE_SINGLE_QUOTED_STRING |
| { |
| newLeafNode(lv_value_2_0, grammarAccess.getDocumentationCSAccess().getValueSINGLE_QUOTED_STRINGTerminalRuleCall_2_0()); |
| } |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getDocumentationCSRule()); |
| } |
| setWithLastConsumed( |
| $current, |
| "value", |
| lv_value_2_0, |
| "org.eclipse.ocl.xtext.base.Base.SINGLE_QUOTED_STRING"); |
| } |
| |
| ) |
| )?( otherlv_3='(' |
| { |
| newLeafNode(otherlv_3, grammarAccess.getDocumentationCSAccess().getLeftParenthesisKeyword_3_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getDocumentationCSAccess().getOwnedDetailsDetailCSParserRuleCall_3_1_0()); |
| } |
| lv_ownedDetails_4_0=ruleDetailCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getDocumentationCSRule()); |
| } |
| add( |
| $current, |
| "ownedDetails", |
| lv_ownedDetails_4_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.DetailCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )( otherlv_5=',' |
| { |
| newLeafNode(otherlv_5, grammarAccess.getDocumentationCSAccess().getCommaKeyword_3_2_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getDocumentationCSAccess().getOwnedDetailsDetailCSParserRuleCall_3_2_1_0()); |
| } |
| lv_ownedDetails_6_0=ruleDetailCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getDocumentationCSRule()); |
| } |
| add( |
| $current, |
| "ownedDetails", |
| lv_ownedDetails_6_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.DetailCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ))* otherlv_7=')' |
| { |
| newLeafNode(otherlv_7, grammarAccess.getDocumentationCSAccess().getRightParenthesisKeyword_3_3()); |
| } |
| )? otherlv_8=';' |
| { |
| newLeafNode(otherlv_8, grammarAccess.getDocumentationCSAccess().getSemicolonKeyword_4()); |
| } |
| ) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleEnumerationCS |
| entryRuleEnumerationCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getEnumerationCSRule()); } |
| iv_ruleEnumerationCS=ruleEnumerationCS |
| { $current=$iv_ruleEnumerationCS.current; } |
| EOF |
| ; |
| |
| // Rule EnumerationCS |
| ruleEnumerationCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| ( otherlv_0='enum' |
| { |
| newLeafNode(otherlv_0, grammarAccess.getEnumerationCSAccess().getEnumKeyword_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getEnumerationCSAccess().getNameUnrestrictedNameParserRuleCall_1_0()); |
| } |
| lv_name_1_0=ruleUnrestrictedName { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getEnumerationCSRule()); |
| } |
| set( |
| $current, |
| "name", |
| lv_name_1_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.UnrestrictedName"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )( |
| ( |
| { |
| newCompositeNode(grammarAccess.getEnumerationCSAccess().getOwnedSignatureTemplateSignatureCSParserRuleCall_2_0()); |
| } |
| lv_ownedSignature_2_0=ruleTemplateSignatureCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getEnumerationCSRule()); |
| } |
| set( |
| $current, |
| "ownedSignature", |
| lv_ownedSignature_2_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.TemplateSignatureCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )?( otherlv_3=':' |
| { |
| newLeafNode(otherlv_3, grammarAccess.getEnumerationCSAccess().getColonKeyword_3_0()); |
| } |
| ( |
| ( |
| lv_instanceClassName_4_0=RULE_SINGLE_QUOTED_STRING |
| { |
| newLeafNode(lv_instanceClassName_4_0, grammarAccess.getEnumerationCSAccess().getInstanceClassNameSINGLE_QUOTED_STRINGTerminalRuleCall_3_1_0()); |
| } |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getEnumerationCSRule()); |
| } |
| setWithLastConsumed( |
| $current, |
| "instanceClassName", |
| lv_instanceClassName_4_0, |
| "org.eclipse.ocl.xtext.base.Base.SINGLE_QUOTED_STRING"); |
| } |
| |
| ) |
| ))?( otherlv_5='{' |
| { |
| newLeafNode(otherlv_5, grammarAccess.getEnumerationCSAccess().getLeftCurlyBracketKeyword_4_0()); |
| } |
| (( |
| ( |
| lv_isSerializable_6_0= 'serializable' |
| { |
| newLeafNode(lv_isSerializable_6_0, grammarAccess.getEnumerationCSAccess().getIsSerializableSerializableKeyword_4_1_0_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getEnumerationCSRule()); |
| } |
| setWithLastConsumed($current, "isSerializable", true, "serializable"); |
| } |
| |
| ) |
| ) |
| | otherlv_7='!serializable' |
| { |
| newLeafNode(otherlv_7, grammarAccess.getEnumerationCSAccess().getSerializableKeyword_4_1_1()); |
| } |
| )? otherlv_8='}' |
| { |
| newLeafNode(otherlv_8, grammarAccess.getEnumerationCSAccess().getRightCurlyBracketKeyword_4_2()); |
| } |
| )?(( otherlv_9='{' |
| { |
| newLeafNode(otherlv_9, grammarAccess.getEnumerationCSAccess().getLeftCurlyBracketKeyword_5_0_0()); |
| } |
| (( |
| ( |
| { |
| newCompositeNode(grammarAccess.getEnumerationCSAccess().getOwnedAnnotationsAnnotationElementCSParserRuleCall_5_0_1_0_0()); |
| } |
| lv_ownedAnnotations_10_0=ruleAnnotationElementCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getEnumerationCSRule()); |
| } |
| add( |
| $current, |
| "ownedAnnotations", |
| lv_ownedAnnotations_10_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.AnnotationElementCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| { |
| newCompositeNode(grammarAccess.getEnumerationCSAccess().getOwnedLiteralsEnumerationLiteralCSParserRuleCall_5_0_1_1_0()); |
| } |
| lv_ownedLiterals_11_0=ruleEnumerationLiteralCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getEnumerationCSRule()); |
| } |
| add( |
| $current, |
| "ownedLiterals", |
| lv_ownedLiterals_11_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.EnumerationLiteralCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| { |
| newCompositeNode(grammarAccess.getEnumerationCSAccess().getOwnedConstraintsInvariantConstraintCSParserRuleCall_5_0_1_2_0()); |
| } |
| lv_ownedConstraints_12_0=ruleInvariantConstraintCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getEnumerationCSRule()); |
| } |
| add( |
| $current, |
| "ownedConstraints", |
| lv_ownedConstraints_12_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.InvariantConstraintCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ))* otherlv_13='}' |
| { |
| newLeafNode(otherlv_13, grammarAccess.getEnumerationCSAccess().getRightCurlyBracketKeyword_5_0_2()); |
| } |
| ) |
| | otherlv_14=';' |
| { |
| newLeafNode(otherlv_14, grammarAccess.getEnumerationCSAccess().getSemicolonKeyword_5_1()); |
| } |
| )) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleEnumerationLiteralCS |
| entryRuleEnumerationLiteralCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getEnumerationLiteralCSRule()); } |
| iv_ruleEnumerationLiteralCS=ruleEnumerationLiteralCS |
| { $current=$iv_ruleEnumerationLiteralCS.current; } |
| EOF |
| ; |
| |
| // Rule EnumerationLiteralCS |
| ruleEnumerationLiteralCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| ((( otherlv_0='literal' |
| { |
| newLeafNode(otherlv_0, grammarAccess.getEnumerationLiteralCSAccess().getLiteralKeyword_0_0_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getEnumerationLiteralCSAccess().getNameUnrestrictedNameParserRuleCall_0_0_1_0()); |
| } |
| lv_name_1_0=ruleUnrestrictedName { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getEnumerationLiteralCSRule()); |
| } |
| set( |
| $current, |
| "name", |
| lv_name_1_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.UnrestrictedName"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )) |
| |( |
| ( |
| { |
| newCompositeNode(grammarAccess.getEnumerationLiteralCSAccess().getNameEnumerationLiteralNameParserRuleCall_0_1_0()); |
| } |
| lv_name_2_0=ruleEnumerationLiteralName { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getEnumerationLiteralCSRule()); |
| } |
| set( |
| $current, |
| "name", |
| lv_name_2_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.EnumerationLiteralName"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ))( otherlv_3=':' |
| { |
| newLeafNode(otherlv_3, grammarAccess.getEnumerationLiteralCSAccess().getColonKeyword_1_0()); |
| } |
| ( |
| ( |
| lv_literal_4_0=RULE_SINGLE_QUOTED_STRING |
| { |
| newLeafNode(lv_literal_4_0, grammarAccess.getEnumerationLiteralCSAccess().getLiteralSINGLE_QUOTED_STRINGTerminalRuleCall_1_1_0()); |
| } |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getEnumerationLiteralCSRule()); |
| } |
| setWithLastConsumed( |
| $current, |
| "literal", |
| lv_literal_4_0, |
| "org.eclipse.ocl.xtext.base.Base.SINGLE_QUOTED_STRING"); |
| } |
| |
| ) |
| ))?( otherlv_5='=' |
| { |
| newLeafNode(otherlv_5, grammarAccess.getEnumerationLiteralCSAccess().getEqualsSignKeyword_2_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getEnumerationLiteralCSAccess().getValueSIGNEDParserRuleCall_2_1_0()); |
| } |
| lv_value_6_0=ruleSIGNED { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getEnumerationLiteralCSRule()); |
| } |
| set( |
| $current, |
| "value", |
| lv_value_6_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.SIGNED"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ))?(( otherlv_7='{' |
| { |
| newLeafNode(otherlv_7, grammarAccess.getEnumerationLiteralCSAccess().getLeftCurlyBracketKeyword_3_0_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getEnumerationLiteralCSAccess().getOwnedAnnotationsAnnotationElementCSParserRuleCall_3_0_1_0()); |
| } |
| lv_ownedAnnotations_8_0=ruleAnnotationElementCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getEnumerationLiteralCSRule()); |
| } |
| add( |
| $current, |
| "ownedAnnotations", |
| lv_ownedAnnotations_8_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.AnnotationElementCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )* otherlv_9='}' |
| { |
| newLeafNode(otherlv_9, grammarAccess.getEnumerationLiteralCSAccess().getRightCurlyBracketKeyword_3_0_2()); |
| } |
| ) |
| | otherlv_10=';' |
| { |
| newLeafNode(otherlv_10, grammarAccess.getEnumerationLiteralCSAccess().getSemicolonKeyword_3_1()); |
| } |
| )) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleImportCS |
| entryRuleImportCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getImportCSRule()); } |
| iv_ruleImportCS=ruleImportCS |
| { $current=$iv_ruleImportCS.current; } |
| EOF |
| ; |
| |
| // Rule ImportCS |
| ruleImportCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| (( otherlv_0='import' |
| { |
| newLeafNode(otherlv_0, grammarAccess.getImportCSAccess().getImportKeyword_0_0()); |
| } |
| |
| | otherlv_1='library' |
| { |
| newLeafNode(otherlv_1, grammarAccess.getImportCSAccess().getLibraryKeyword_0_1()); |
| } |
| )(( |
| ( |
| { |
| newCompositeNode(grammarAccess.getImportCSAccess().getNameUnrestrictedNameParserRuleCall_1_0_0()); |
| } |
| lv_name_2_0=ruleUnrestrictedName { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getImportCSRule()); |
| } |
| set( |
| $current, |
| "name", |
| lv_name_2_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.UnrestrictedName"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) otherlv_3=':' |
| { |
| newLeafNode(otherlv_3, grammarAccess.getImportCSAccess().getColonKeyword_1_1()); |
| } |
| )?( |
| ( |
| { |
| newCompositeNode(grammarAccess.getImportCSAccess().getOwnedPathNameURIPathNameCSParserRuleCall_2_0()); |
| } |
| lv_ownedPathName_4_0=ruleURIPathNameCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getImportCSRule()); |
| } |
| set( |
| $current, |
| "ownedPathName", |
| lv_ownedPathName_4_0, |
| "org.eclipse.ocl.xtext.essentialocl.EssentialOCL.URIPathNameCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )( |
| ( |
| lv_isAll_5_0= '::*' |
| { |
| newLeafNode(lv_isAll_5_0, grammarAccess.getImportCSAccess().getIsAllColonColonAsteriskKeyword_3_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getImportCSRule()); |
| } |
| setWithLastConsumed($current, "isAll", true, "::*"); |
| } |
| |
| ) |
| )? otherlv_6=';' |
| { |
| newLeafNode(otherlv_6, grammarAccess.getImportCSAccess().getSemicolonKeyword_4()); |
| } |
| ) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleModelElementCS |
| entryRuleModelElementCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getModelElementCSRule()); } |
| iv_ruleModelElementCS=ruleModelElementCS |
| { $current=$iv_ruleModelElementCS.current; } |
| EOF |
| ; |
| |
| // Rule ModelElementCS |
| ruleModelElementCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| ( |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getModelElementCSAccess().getClassCSParserRuleCall_0()); |
| } |
| this_ClassCS_0=ruleClassCS |
| { |
| $current = $this_ClassCS_0.current; |
| afterParserOrEnumRuleCall(); |
| } |
| |
| | |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getModelElementCSAccess().getEnumerationLiteralCSParserRuleCall_1()); |
| } |
| this_EnumerationLiteralCS_1=ruleEnumerationLiteralCS |
| { |
| $current = $this_EnumerationLiteralCS_1.current; |
| afterParserOrEnumRuleCall(); |
| } |
| |
| | |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getModelElementCSAccess().getOperationCSParserRuleCall_2()); |
| } |
| this_OperationCS_2=ruleOperationCS |
| { |
| $current = $this_OperationCS_2.current; |
| afterParserOrEnumRuleCall(); |
| } |
| |
| | |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getModelElementCSAccess().getPackageCSParserRuleCall_3()); |
| } |
| this_PackageCS_3=rulePackageCS |
| { |
| $current = $this_PackageCS_3.current; |
| afterParserOrEnumRuleCall(); |
| } |
| |
| | |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getModelElementCSAccess().getStructuralFeatureCSParserRuleCall_4()); |
| } |
| this_StructuralFeatureCS_4=ruleStructuralFeatureCS |
| { |
| $current = $this_StructuralFeatureCS_4.current; |
| afterParserOrEnumRuleCall(); |
| } |
| ) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleModelElementRefCS |
| entryRuleModelElementRefCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getModelElementRefCSRule()); } |
| iv_ruleModelElementRefCS=ruleModelElementRefCS |
| { $current=$iv_ruleModelElementRefCS.current; } |
| EOF |
| ; |
| |
| // Rule ModelElementRefCS |
| ruleModelElementRefCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| ( otherlv_0='reference' |
| { |
| newLeafNode(otherlv_0, grammarAccess.getModelElementRefCSAccess().getReferenceKeyword_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getModelElementRefCSAccess().getOwnedPathNamePathNameCSParserRuleCall_1_0()); |
| } |
| lv_ownedPathName_1_0=rulePathNameCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getModelElementRefCSRule()); |
| } |
| set( |
| $current, |
| "ownedPathName", |
| lv_ownedPathName_1_0, |
| "org.eclipse.ocl.xtext.base.Base.PathNameCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) otherlv_2=';' |
| { |
| newLeafNode(otherlv_2, grammarAccess.getModelElementRefCSAccess().getSemicolonKeyword_2()); |
| } |
| ) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRuleOperationCS |
| entryRuleOperationCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getOperationCSRule()); } |
| iv_ruleOperationCS=ruleOperationCS |
| { $current=$iv_ruleOperationCS.current; } |
| EOF |
| ; |
| |
| // Rule OperationCS |
| ruleOperationCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| (((( |
| ( |
| lv_qualifiers_0_0= 'static' |
| { |
| newLeafNode(lv_qualifiers_0_0, grammarAccess.getOperationCSAccess().getQualifiersStaticKeyword_0_0_0_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getOperationCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_0_0, "static"); |
| } |
| |
| ) |
| )( |
| ( |
| lv_qualifiers_1_0= 'definition' |
| { |
| newLeafNode(lv_qualifiers_1_0, grammarAccess.getOperationCSAccess().getQualifiersDefinitionKeyword_0_0_1_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getOperationCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_1_0, "definition"); |
| } |
| |
| ) |
| )?) |
| |(( |
| ( |
| lv_qualifiers_2_0= 'definition' |
| { |
| newLeafNode(lv_qualifiers_2_0, grammarAccess.getOperationCSAccess().getQualifiersDefinitionKeyword_0_1_0_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getOperationCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_2_0, "definition"); |
| } |
| |
| ) |
| )( |
| ( |
| lv_qualifiers_3_0= 'static' |
| { |
| newLeafNode(lv_qualifiers_3_0, grammarAccess.getOperationCSAccess().getQualifiersStaticKeyword_0_1_1_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getOperationCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_3_0, "static"); |
| } |
| |
| ) |
| )?))? otherlv_4='operation' |
| { |
| newLeafNode(otherlv_4, grammarAccess.getOperationCSAccess().getOperationKeyword_1()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getOperationCSAccess().getOwnedSignatureTemplateSignatureCSParserRuleCall_2_0()); |
| } |
| lv_ownedSignature_5_0=ruleTemplateSignatureCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getOperationCSRule()); |
| } |
| set( |
| $current, |
| "ownedSignature", |
| lv_ownedSignature_5_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.TemplateSignatureCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )?( |
| ( |
| { |
| newCompositeNode(grammarAccess.getOperationCSAccess().getNameUnrestrictedNameParserRuleCall_3_0()); |
| } |
| lv_name_6_0=ruleUnrestrictedName { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getOperationCSRule()); |
| } |
| set( |
| $current, |
| "name", |
| lv_name_6_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.UnrestrictedName"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) otherlv_7='(' |
| { |
| newLeafNode(otherlv_7, grammarAccess.getOperationCSAccess().getLeftParenthesisKeyword_4()); |
| } |
| (( |
| ( |
| { |
| newCompositeNode(grammarAccess.getOperationCSAccess().getOwnedParametersParameterCSParserRuleCall_5_0_0()); |
| } |
| lv_ownedParameters_8_0=ruleParameterCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getOperationCSRule()); |
| } |
| add( |
| $current, |
| "ownedParameters", |
| lv_ownedParameters_8_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.ParameterCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )( otherlv_9=',' |
| { |
| newLeafNode(otherlv_9, grammarAccess.getOperationCSAccess().getCommaKeyword_5_1_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getOperationCSAccess().getOwnedParametersParameterCSParserRuleCall_5_1_1_0()); |
| } |
| lv_ownedParameters_10_0=ruleParameterCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getOperationCSRule()); |
| } |
| add( |
| $current, |
| "ownedParameters", |
| lv_ownedParameters_10_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.ParameterCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ))*)? otherlv_11=')' |
| { |
| newLeafNode(otherlv_11, grammarAccess.getOperationCSAccess().getRightParenthesisKeyword_6()); |
| } |
| ( otherlv_12=':' |
| { |
| newLeafNode(otherlv_12, grammarAccess.getOperationCSAccess().getColonKeyword_7_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getOperationCSAccess().getOwnedTypeTypedMultiplicityRefCSParserRuleCall_7_1_0()); |
| } |
| lv_ownedType_13_0=ruleTypedMultiplicityRefCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getOperationCSRule()); |
| } |
| set( |
| $current, |
| "ownedType", |
| lv_ownedType_13_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.TypedMultiplicityRefCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ))?( otherlv_14='throws' |
| { |
| newLeafNode(otherlv_14, grammarAccess.getOperationCSAccess().getThrowsKeyword_8_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getOperationCSAccess().getOwnedExceptionsTypedRefCSParserRuleCall_8_1_0()); |
| } |
| lv_ownedExceptions_15_0=ruleTypedRefCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getOperationCSRule()); |
| } |
| add( |
| $current, |
| "ownedExceptions", |
| lv_ownedExceptions_15_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.TypedRefCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )( otherlv_16=',' |
| { |
| newLeafNode(otherlv_16, grammarAccess.getOperationCSAccess().getCommaKeyword_8_2_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getOperationCSAccess().getOwnedExceptionsTypedRefCSParserRuleCall_8_2_1_0()); |
| } |
| lv_ownedExceptions_17_0=ruleTypedRefCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getOperationCSRule()); |
| } |
| add( |
| $current, |
| "ownedExceptions", |
| lv_ownedExceptions_17_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.TypedRefCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ))*)?( otherlv_18='{' |
| { |
| newLeafNode(otherlv_18, grammarAccess.getOperationCSAccess().getLeftCurlyBracketKeyword_9_0()); |
| } |
| ((( |
| ( |
| lv_qualifiers_19_0= 'derived' |
| { |
| newLeafNode(lv_qualifiers_19_0, grammarAccess.getOperationCSAccess().getQualifiersDerivedKeyword_9_1_0_0_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getOperationCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_19_0, "derived"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_20_0= '!derived' |
| { |
| newLeafNode(lv_qualifiers_20_0, grammarAccess.getOperationCSAccess().getQualifiersDerivedKeyword_9_1_0_1_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getOperationCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_20_0, "!derived"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_21_0= 'ordered' |
| { |
| newLeafNode(lv_qualifiers_21_0, grammarAccess.getOperationCSAccess().getQualifiersOrderedKeyword_9_1_0_2_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getOperationCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_21_0, "ordered"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_22_0= '!ordered' |
| { |
| newLeafNode(lv_qualifiers_22_0, grammarAccess.getOperationCSAccess().getQualifiersOrderedKeyword_9_1_0_3_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getOperationCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_22_0, "!ordered"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_23_0= 'transient' |
| { |
| newLeafNode(lv_qualifiers_23_0, grammarAccess.getOperationCSAccess().getQualifiersTransientKeyword_9_1_0_4_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getOperationCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_23_0, "transient"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_24_0= '!transient' |
| { |
| newLeafNode(lv_qualifiers_24_0, grammarAccess.getOperationCSAccess().getQualifiersTransientKeyword_9_1_0_5_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getOperationCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_24_0, "!transient"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_25_0= 'unique' |
| { |
| newLeafNode(lv_qualifiers_25_0, grammarAccess.getOperationCSAccess().getQualifiersUniqueKeyword_9_1_0_6_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getOperationCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_25_0, "unique"); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| lv_qualifiers_26_0= '!unique' |
| { |
| newLeafNode(lv_qualifiers_26_0, grammarAccess.getOperationCSAccess().getQualifiersUniqueKeyword_9_1_0_7_0()); |
| } |
| |
| { |
| if ($current==null) { |
| $current = createModelElement(grammarAccess.getOperationCSRule()); |
| } |
| addWithLastConsumed($current, "qualifiers", lv_qualifiers_26_0, "!unique"); |
| } |
| |
| ) |
| ))( otherlv_27=',' |
| { |
| newLeafNode(otherlv_27, grammarAccess.getOperationCSAccess().getCommaKeyword_9_1_1()); |
| } |
| )?)+ otherlv_28='}' |
| { |
| newLeafNode(otherlv_28, grammarAccess.getOperationCSAccess().getRightCurlyBracketKeyword_9_2()); |
| } |
| )?(( otherlv_29='{' |
| { |
| newLeafNode(otherlv_29, grammarAccess.getOperationCSAccess().getLeftCurlyBracketKeyword_10_0_0()); |
| } |
| (( |
| ( |
| { |
| newCompositeNode(grammarAccess.getOperationCSAccess().getOwnedAnnotationsAnnotationElementCSParserRuleCall_10_0_1_0_0()); |
| } |
| lv_ownedAnnotations_30_0=ruleAnnotationElementCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getOperationCSRule()); |
| } |
| add( |
| $current, |
| "ownedAnnotations", |
| lv_ownedAnnotations_30_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.AnnotationElementCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) |
| |( |
| ( |
| { |
| newCompositeNode(grammarAccess.getOperationCSAccess().getOwnedPreconditionsPreconditionConstraintCSParserRuleCall_10_0_1_1_0()); |
| } |
| lv_ownedPreconditions_31_0=rulePreconditionConstraintCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getOperationCSRule()); |
| } |
| add( |
| $current, |
| "ownedPreconditions", |
| lv_ownedPreconditions_31_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.PreconditionConstraintCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ) |
| |( otherlv_32='body' |
| { |
| newLeafNode(otherlv_32, grammarAccess.getOperationCSAccess().getBodyKeyword_10_0_1_2_0()); |
| } |
| ( |
| { |
| /* */ |
| } |
| { |
| newCompositeNode(grammarAccess.getOperationCSAccess().getUnrestrictedNameParserRuleCall_10_0_1_2_1()); |
| } |
| ruleUnrestrictedName |
| { |
| afterParserOrEnumRuleCall(); |
| } |
| )? otherlv_34=':' |
| { |
| newLeafNode(otherlv_34, grammarAccess.getOperationCSAccess().getColonKeyword_10_0_1_2_2()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getOperationCSAccess().getOwnedBodyExpressionsSpecificationCSParserRuleCall_10_0_1_2_3_0()); |
| } |
| lv_ownedBodyExpressions_35_0=ruleSpecificationCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getOperationCSRule()); |
| } |
| add( |
| $current, |
| "ownedBodyExpressions", |
| lv_ownedBodyExpressions_35_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.SpecificationCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )? otherlv_36=';' |
| { |
| newLeafNode(otherlv_36, grammarAccess.getOperationCSAccess().getSemicolonKeyword_10_0_1_2_4()); |
| } |
| ) |
| |( |
| ( |
| { |
| newCompositeNode(grammarAccess.getOperationCSAccess().getOwnedPostconditionsPostconditionConstraintCSParserRuleCall_10_0_1_3_0()); |
| } |
| lv_ownedPostconditions_37_0=rulePostconditionConstraintCS { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getOperationCSRule()); |
| } |
| add( |
| $current, |
| "ownedPostconditions", |
| lv_ownedPostconditions_37_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.PostconditionConstraintCS"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| ))* otherlv_38='}' |
| { |
| newLeafNode(otherlv_38, grammarAccess.getOperationCSAccess().getRightCurlyBracketKeyword_10_0_2()); |
| } |
| ) |
| | otherlv_39=';' |
| { |
| newLeafNode(otherlv_39, grammarAccess.getOperationCSAccess().getSemicolonKeyword_10_1()); |
| } |
| )) |
| ; |
| |
| |
| |
| |
| |
| // Entry rule entryRulePackageCS |
| entryRulePackageCS returns [EObject current=null] |
| : |
| { newCompositeNode(grammarAccess.getPackageCSRule()); } |
| iv_rulePackageCS=rulePackageCS |
| { $current=$iv_rulePackageCS.current; } |
| EOF |
| ; |
| |
| // Rule PackageCS |
| rulePackageCS returns [EObject current=null] |
| @init { enterRule(); |
| } |
| @after { leaveRule(); }: |
| ( otherlv_0='package' |
| { |
| newLeafNode(otherlv_0, grammarAccess.getPackageCSAccess().getPackageKeyword_0()); |
| } |
| ( |
| ( |
| { |
| newCompositeNode(grammarAccess.getPackageCSAccess().getNameUnrestrictedNameParserRuleCall_1_0()); |
| } |
| lv_name_1_0=ruleUnrestrictedName { |
| if ($current==null) { |
| $current = createModelElementForParent(grammarAccess.getPackageCSRule()); |
| } |
| set( |
| $current, |
| "name", |
| lv_name_1_0, |
| "org.eclipse.ocl.xtext.oclinecore.OCLinEcore.UnrestrictedName"); |
| afterParserOrEnumRuleCall(); |
| } |
| |
| ) |
| )( otherlv_2=':' |
| { |
| newLeafNode(otherlv_2, grammarAccess.getPackageCSAccess().getColonKeyword_2_0()); |
| } |
| ( |
| ( |
|