Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 146761 Details for
Bug 255786
Investigate support for Constraints directly annotated to Ecore
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
updated patch based on HEAD
255786.patch (text/plain), 342.15 KB, created by
Kenn Hussey
on 2009-09-09 11:46:00 EDT
(
hide
)
Description:
updated patch based on HEAD
Filename:
MIME Type:
Creator:
Kenn Hussey
Created:
2009-09-09 11:46:00 EDT
Size:
342.15 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.emf.codegen.ecore >Index: templates/model/ValidatorClass.javajet >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/templates/model/ValidatorClass.javajet,v >retrieving revision 1.33 >diff -u -r1.33 ValidatorClass.javajet >--- templates/model/ValidatorClass.javajet 7 Jan 2009 01:58:23 -0000 1.33 >+++ templates/model/ValidatorClass.javajet 8 Sep 2009 17:31:20 -0000 >@@ -3,7 +3,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2002-2006 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -31,6 +31,7 @@ > <%genModel.addPseudoImport("org.eclipse.emf.ecore.EValidator.Registry");%> > <%genModel.addPseudoImport("org.eclipse.emf.ecore.EValidator.SubstitutionLabelProvider");%> > <%genModel.addPseudoImport("org.eclipse.emf.ecore.EValidator.PatternMatcher");%> >+<%genModel.addPseudoImport("org.eclipse.emf.ecore.EValidator.ValidationDelegate");%> > > /** > * <!-- begin-user-doc --> >@@ -284,6 +285,16 @@ > > <%}%> > <%}%> >+<%if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF26_VALUE && genClassifier.hasValidationExpression(constraint)) {%> >+ /** >+ * The cached validation expression for the <%=constraint%> constraint of '<em><%=genClassifier.getFormattedName()%></em>'. >+ * <!-- begin-user-doc --> >+ * <!-- end-user-doc --> >+ * @generated >+ */ >+ protected static final <%=genModel.getImportedName("java.lang.String")%> <%=genClassifier.getClassifierID()%>__<%=CodeGenUtil.upperName(constraint)%>__EXP = "<%=genClassifier.getValidationExpression(constraint, genModel.getIndentation(stringBuffer))%>";<%=genModel.getNonNLS()%> >+ >+<%}%> > /** > * Validates the <%=constraint%> constraint of '<em><%=genClassifier.getFormattedName()%></em>'. > * <!-- begin-user-doc --> >@@ -481,6 +492,55 @@ > } > return <%=delegate%>validate<%=constraintDelegate.getName()%>_<%=constraint%>(<%=genClassifier.getSafeUncapName()%><%=accessor%>, <%=diagnostics%>, <%=context%>); > <%} else {%> >+ <%if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF26_VALUE && genClassifier.hasValidationExpression(constraint)) {%> >+ <%=genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")%>.Registry registry = getValidationDelegateRegistry(<%=context%>); >+ <%=genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")%> delegate = registry.getValidationDelegate(<%=genModel.getImportedName("org.eclipse.emf.common.util.URI")%>.createURI("<%=genClassifier.getValidationDelegate(constraint)%>"));<%=genModel.getNonNLS()%> >+ if (delegate != null) { >+ try { >+ if (!delegate.validate(<%=genClassifier.getClassifierID()%>__<%=CodeGenUtil.upperName(constraint)%>__EXP, <%=genClassifier.getQualifiedClassifierAccessor()%>, <%=genClassifier.getSafeUncapName()%>, <%=context%>)) { >+ if (diagnostics != null) { >+ <%=diagnostics%>.add >+ (createDiagnostic >+ (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_GenericConstraint_diagnostic",<%=genModel.getNonNLS()%> >+ new Object[] { "<%=constraint%>", getValueLabel(<%=genDataType.getQualifiedClassifierAccessor()%>, <%=genClassifier.getSafeUncapName()%>, <%=context%>) },<%=genModel.getNonNLS()%> >+ new Object[] { <%=genClassifier.getSafeUncapName()%> }, >+ context)); >+ } >+ return false; >+ } >+ return true; >+ } catch (<%=genModel.getImportedName("java.lang.Throwable")%> throwable) { >+ if (diagnostics != null) { >+ <%=diagnostics%>.add >+ (createDiagnostic >+ (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_ConstraintDelegateException_diagnostic",<%=genModel.getNonNLS()%> >+ new Object[] { "<%=constraint%>", getValueLabel(<%=genDataType.getQualifiedClassifierAccessor()%>, <%=genClassifier.getSafeUncapName()%>, <%=context%>), throwable.getLocalizedMessage() },<%=genModel.getNonNLS()%> >+ new Object[] { <%=genClassifier.getSafeUncapName()%> }, >+ context)); >+ } >+ return false; >+ } >+ } else { >+ if (diagnostics != null) { >+ <%=diagnostics%>.add >+ (createDiagnostic >+ (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_ConstraintDelegateNotFound_diagnostic",<%=genModel.getNonNLS()%> >+ new Object[] { "<%=constraint%>", getValueLabel(<%=genDataType.getQualifiedClassifierAccessor()%>, <%=genClassifier.getSafeUncapName()%>, <%=context%>), "<%=genClassifier.getValidationDelegate(constraint)%>" },<%=genModel.getNonNLS()%><%=genModel.getNonNLS(2)%> >+ new Object[] { <%=genClassifier.getSafeUncapName()%> }, >+ context)); >+ } >+ return false; >+ } >+ <%} else {%> > // TODO implement the constraint > // -> specify the condition that violates the constraint > // -> verify the diagnostic details, including severity, code, and message >@@ -490,7 +550,7 @@ > if (<%=diagnostics%> != null) > { > <%=diagnostics%>.add >-<%if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE) {%> >+ <%if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE) {%> > (createDiagnostic > (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, > DIAGNOSTIC_SOURCE, >@@ -499,18 +559,19 @@ > new Object[] { "<%=constraint%>", getValueLabel(<%=genDataType.getQualifiedClassifierAccessor()%>, <%=genClassifier.getSafeUncapName()%>, <%=context%>) },<%=genModel.getNonNLS()%> > new Object[] { <%=genClassifier.getSafeUncapName()%> }, > context)); >-<%} else {%> >+ <%} else {%> > (new <%=genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")%> > (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, > DIAGNOSTIC_SOURCE, > 0, > <%=genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")%>.INSTANCE.getString("_UI_GenericConstraint_diagnostic", new Object[] { "<%=constraint%>", getValueLabel(<%=genDataType.getQualifiedClassifierAccessor()%>, <%=genClassifier.getSafeUncapName()%>, <%=context%>) }),<%=genModel.getNonNLS()%><%=genModel.getNonNLS(2)%> > new Object[] { <%=genClassifier.getSafeUncapName()%> })); >-<%}%> >+ <%}%> > } > return false; > } > return true; >+ <%}%> > <%}%> > <%} else if (constraintDelegate != null) {%> > // TODO override the constraint, if desired >@@ -523,7 +584,7 @@ > if (<%=diagnostics%> != null) > { > <%=diagnostics%>.add >-<%if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE) {%> >+ <%if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE) {%> > (createDiagnostic > (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, > DIAGNOSTIC_SOURCE, >@@ -532,14 +593,14 @@ > new Object[] { "<%=constraint%>", getObjectLabel(<%=genClassifier.getSafeUncapName()%>, <%=context%>) },<%=genModel.getNonNLS()%> > new Object[] { <%=genClassifier.getSafeUncapName()%> }, > context)); >-<%} else {%> >+ <%} else {%> > (new <%=genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")%> > (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, > DIAGNOSTIC_SOURCE, > 0, > <%=genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")%>.INSTANCE.getString("_UI_GenericConstraint_diagnostic", new Object[] { "<%=constraint%>", getObjectLabel(<%=genClassifier.getSafeUncapName()%>, <%=context%>) }),<%=genModel.getNonNLS()%><%=genModel.getNonNLS(2)%> > new Object[] { <%=genClassifier.getSafeUncapName()%> })); >-<%}%> >+ <%}%> > } > return false; > } >@@ -547,6 +608,55 @@ > <%} else { GenOperation genOperation = ((GenClass)genClassifier).getInvariantOperation(constraint); if (genOperation != null) {%> > return <%=genClassifier.getSafeUncapName()%>.<%=constraint%>(<%=diagnostics%>, <%=context%>); > <%} else {%> >+ <%if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF26_VALUE && genClassifier.hasValidationExpression(constraint)) {%> >+ <%=genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")%>.Registry registry = getValidationDelegateRegistry(<%=context%>); >+ <%=genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")%> delegate = registry.getValidationDelegate(<%=genModel.getImportedName("org.eclipse.emf.common.util.URI")%>.createURI("<%=genClassifier.getValidationDelegate(constraint)%>"));<%=genModel.getNonNLS()%> >+ if (delegate != null) { >+ try { >+ if (!delegate.validate(<%=genClassifier.getClassifierID()%>__<%=CodeGenUtil.upperName(constraint)%>__EXP, <%=genClassifier.getQualifiedClassifierAccessor()%>, <%=genClassifier.getSafeUncapName()%>, <%=context%>)) { >+ if (diagnostics != null) { >+ <%=diagnostics%>.add >+ (createDiagnostic >+ (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_GenericConstraint_diagnostic",<%=genModel.getNonNLS()%> >+ new Object[] { "<%=constraint%>", getObjectLabel(<%=genClassifier.getSafeUncapName()%>, <%=context%>) },<%=genModel.getNonNLS()%> >+ new Object[] { <%=genClassifier.getSafeUncapName()%> }, >+ context)); >+ } >+ return false; >+ } >+ return true; >+ } catch (<%=genModel.getImportedName("java.lang.Throwable")%> throwable) { >+ if (diagnostics != null) { >+ <%=diagnostics%>.add >+ (createDiagnostic >+ (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_ConstraintDelegateException_diagnostic",<%=genModel.getNonNLS()%> >+ new Object[] { "<%=constraint%>", getObjectLabel(<%=genClassifier.getSafeUncapName()%>, <%=context%>), throwable.getLocalizedMessage() },<%=genModel.getNonNLS()%> >+ new Object[] { <%=genClassifier.getSafeUncapName()%> }, >+ context)); >+ } >+ return false; >+ } >+ } else { >+ if (diagnostics != null) { >+ <%=diagnostics%>.add >+ (createDiagnostic >+ (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_ConstraintDelegateNotFound_diagnostic",<%=genModel.getNonNLS()%> >+ new Object[] { "<%=constraint%>", getObjectLabel(<%=genClassifier.getSafeUncapName()%>, <%=context%>), "<%=genClassifier.getValidationDelegate(constraint)%>" },<%=genModel.getNonNLS()%><%=genModel.getNonNLS(2)%> >+ new Object[] { <%=genClassifier.getSafeUncapName()%> }, >+ context)); >+ } >+ return false; >+ } >+ <%} else {%> > // TODO implement the constraint > // -> specify the condition that violates the constraint > // -> verify the diagnostic details, including severity, code, and message >@@ -556,7 +666,7 @@ > if (<%=diagnostics%> != null) > { > <%=diagnostics%>.add >-<%if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE) {%> >+ <%if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE) {%> > (createDiagnostic > (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, > DIAGNOSTIC_SOURCE, >@@ -565,18 +675,19 @@ > new Object[] { "<%=constraint%>", getObjectLabel(<%=genClassifier.getSafeUncapName()%>, <%=context%>) },<%=genModel.getNonNLS()%> > new Object[] { <%=genClassifier.getSafeUncapName()%> }, > context)); >-<%} else {%> >+ <%} else {%> > (new <%=genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")%> > (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, > DIAGNOSTIC_SOURCE, > 0, > <%=genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")%>.INSTANCE.getString("_UI_GenericConstraint_diagnostic", new Object[] { "<%=constraint%>", getObjectLabel(<%=genClassifier.getSafeUncapName()%>, <%=context%>) }),<%=genModel.getNonNLS()%><%=genModel.getNonNLS(2)%> > new Object[] { <%=genClassifier.getSafeUncapName()%> })); >-<%}%> >+ <%}%> > } > return false; > } > return true; >+ <%}%> > <%}}%> > } > >Index: templates/model/Class.javajet >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/templates/model/Class.javajet,v >retrieving revision 1.85 >diff -u -r1.85 Class.javajet >--- templates/model/Class.javajet 18 Apr 2009 12:13:48 -0000 1.85 >+++ templates/model/Class.javajet 8 Sep 2009 17:31:20 -0000 >@@ -1,9 +1,9 @@ >-<%@ jet package="org.eclipse.emf.codegen.ecore.templates.model" imports="java.util.* org.eclipse.emf.codegen.ecore.genmodel.*" class="Class" version="$Id: Class.javajet,v 1.85 2009/04/18 12:13:48 emerks Exp $" %> >+<%@ jet package="org.eclipse.emf.codegen.ecore.templates.model" imports="java.util.* org.eclipse.emf.codegen.ecore.genmodel.* org.eclipse.emf.codegen.util.CodeGenUtil" class="Class" version="$Id: Class.javajet,v 1.85 2009/04/18 12:13:48 emerks Exp $" %> > <% > /** > * <copyright> > * >- * Copyright (c) 2002-2007 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -1320,6 +1320,17 @@ > <%for (GenOperation genOperation : (isImplementation ? genClass.getImplementedGenOperations() : genClass.getDeclaredGenOperations())) {%> > <%@ include file="Class/genOperation.override.javajetinc" fail="alternative" %> > <%@ start %> >+ <%if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF26_VALUE && isImplementation && genOperation.isInvariant() && genOperation.hasValidationExpression()) {%> >+ /** >+ * The cached validation expression for the '{@link #<%=genOperation.getName()%>(<%=genOperation.getParameterTypes(", ")%>) <em><%=genOperation.getFormattedName()%></em>}' operation. >+ * <!-- begin-user-doc --> >+ * <!-- end-user-doc --> >+ * @see #<%=genOperation.getName()%>(<%=genOperation.getParameterTypes(", ")%>) >+ * @generated >+ */ >+ protected static final <%=genModel.getImportedName("java.lang.String")%> <%=CodeGenUtil.upperName(genOperation.getName(), genModel.getLocale())%><%=genOperation.getGenParameters().size() == 0 ? "" : "__" + CodeGenUtil.upperName(genOperation.getParameterTypes("_", false), genModel.getLocale())%>__EXP = "<%=genOperation.getValidationExpression("\t\t")%>";<%=genModel.getNonNLS()%> >+ >+ <%}%> > <%if (isInterface) {%> > <%@ include file="Class/genOperation.javadoc.override.javajetinc" fail="alternative" %> > <%@ start %> >@@ -1373,6 +1384,49 @@ > <%if (genOperation.hasBody()) {%> > <%=genOperation.getBody(genModel.getIndentation(stringBuffer))%> > <%} else if (genOperation.isInvariant()) {GenClass opClass = genOperation.getGenClass(); String diagnostics = genOperation.getGenParameters().get(0).getName(); String context = genOperation.getGenParameters().get(1).getName();%> >+ <%if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF26_VALUE && genOperation.hasValidationExpression()) {%> >+ <%=genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")%>.Registry registry = <%=context%> == null ? <%=genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")%>.Registry.INSTANCE : (<%=genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")%>.Registry)<%=context%>.get(<%=genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")%>.Registry.class); >+ <%=genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")%> delegate = (registry == null ? <%=genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")%>.Registry.INSTANCE : registry).getValidationDelegate(<%=genModel.getImportedName("org.eclipse.emf.common.util.URI")%>.createURI("<%=genOperation.getValidationDelegate()%>"));<%=genModel.getNonNLS()%> >+ if (delegate != null) { >+ try { >+ if (!delegate.validate(<%=CodeGenUtil.upperName(genOperation.getName(), genModel.getLocale())%><%=genOperation.getGenParameters().size() == 0 ? "" : "__" + CodeGenUtil.upperName(genOperation.getParameterTypes("_", false), genModel.getLocale())%>__EXP, <%=genClass.getQualifiedClassifierAccessor()%>, this, <%=context%>)) { >+ if (diagnostics != null) { >+ <%=diagnostics%>.add >+ (new <%=genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")%> >+ (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, >+ <%=opClass.getGenPackage().getImportedValidatorClassName()%>.DIAGNOSTIC_SOURCE, >+ <%=opClass.getGenPackage().getImportedValidatorClassName()%>.<%=opClass.getOperationID(genOperation)%>, >+ <%=genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")%>.INSTANCE.getString("_UI_GenericInvariant_diagnostic", new Object[] { "<%=genOperation.getName()%>", <%=genModel.getImportedName("org.eclipse.emf.ecore.util.EObjectValidator")%>.getObjectLabel(this, <%=context%>) }),<%=genModel.getNonNLS()%><%=genModel.getNonNLS(2)%> >+ new Object [] { this })); >+ } >+ return false; >+ } >+ return true; >+ } catch (<%=genModel.getImportedName("java.lang.Throwable")%> throwable) { >+ if (diagnostics != null) { >+ <%=diagnostics%>.add >+ (new <%=genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")%> >+ (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, >+ <%=opClass.getGenPackage().getImportedValidatorClassName()%>.DIAGNOSTIC_SOURCE, >+ <%=opClass.getGenPackage().getImportedValidatorClassName()%>.<%=opClass.getOperationID(genOperation)%>, >+ <%=genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")%>.INSTANCE.getString("_UI_InvariantDelegateException_diagnostic", new Object[] { "<%=genOperation.getName()%>", <%=genModel.getImportedName("org.eclipse.emf.ecore.util.EObjectValidator")%>.getObjectLabel(this, <%=context%>), throwable.getLocalizedMessage() }),<%=genModel.getNonNLS()%><%=genModel.getNonNLS(2)%> >+ new Object [] { this })); >+ } >+ return false; >+ } >+ } else { >+ if (diagnostics != null) { >+ <%=diagnostics%>.add >+ (new <%=genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")%> >+ (<%=genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")%>.ERROR, >+ <%=opClass.getGenPackage().getImportedValidatorClassName()%>.DIAGNOSTIC_SOURCE, >+ <%=opClass.getGenPackage().getImportedValidatorClassName()%>.<%=opClass.getOperationID(genOperation)%>, >+ <%=genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")%>.INSTANCE.getString("_UI_InvariantDelegateNotFound_diagnostic", new Object[] { "<%=genOperation.getName()%>", <%=genModel.getImportedName("org.eclipse.emf.ecore.util.EObjectValidator")%>.getObjectLabel(this, <%=context%>), "<%=genOperation.getValidationDelegate()%>" }),<%=genModel.getNonNLS()%><%=genModel.getNonNLS(2)%><%=genModel.getNonNLS(3)%> >+ new Object [] { this })); >+ } >+ return false; >+ } >+ <%} else {%> > // TODO: implement this method > // -> specify the condition that violates the invariant > // -> verify the details of the diagnostic, including severity and message >@@ -1392,6 +1446,7 @@ > return false; > } > return true; >+ <%}%> > <%} else {%> > <%@ include file="Class/implementedGenOperation.TODO.override.javajetinc" fail="alternative" %> > <%@ start %> >Index: src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenEnumLiteralImpl.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenEnumLiteralImpl.java,v >retrieving revision 1.19 >diff -u -r1.19 GenEnumLiteralImpl.java >--- src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenEnumLiteralImpl.java 18 Apr 2009 11:38:01 -0000 1.19 >+++ src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenEnumLiteralImpl.java 8 Sep 2009 17:31:02 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2002-2006 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -22,6 +22,7 @@ > import org.eclipse.emf.codegen.ecore.genmodel.GenJDKLevel; > import org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage; > import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; >+import org.eclipse.emf.codegen.util.CodeGenUtil; > import org.eclipse.emf.common.notify.Notification; > import org.eclipse.emf.common.notify.NotificationChain; > import org.eclipse.emf.ecore.EClass; >@@ -328,7 +329,7 @@ > > public String getEnumLiteralID() > { >- return format(getName(), '_', null, false, true).toUpperCase(getGenModel().getLocale()); >+ return CodeGenUtil.upperName(getName(), getGenModel().getLocale()); > } > > public String getEnumLiteralInstanceConstantName() >Index: src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenModelPackageImpl.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenModelPackageImpl.java,v >retrieving revision 1.60 >diff -u -r1.60 GenModelPackageImpl.java >--- src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenModelPackageImpl.java 12 May 2009 15:54:38 -0000 1.60 >+++ src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenModelPackageImpl.java 8 Sep 2009 17:31:07 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2002-2007 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -2383,6 +2383,7 @@ > addEEnumLiteral(genRuntimeVersionEEnum, GenRuntimeVersion.EMF23); > addEEnumLiteral(genRuntimeVersionEEnum, GenRuntimeVersion.EMF24); > addEEnumLiteral(genRuntimeVersionEEnum, GenRuntimeVersion.EMF25); >+ addEEnumLiteral(genRuntimeVersionEEnum, GenRuntimeVersion.EMF26); > > // Create resource > createResource(eNS_URI); >Index: src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenBaseImpl.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenBaseImpl.java,v >retrieving revision 1.69 >diff -u -r1.69 GenBaseImpl.java >--- src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenBaseImpl.java 13 Mar 2009 21:09:02 -0000 1.69 >+++ src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenBaseImpl.java 8 Sep 2009 17:31:02 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2002-2007 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -2502,13 +2502,18 @@ > > protected String indent(String text, String indentation) > { >+ return indent(text, indentation, getGenModel().getLineDelimiter()); >+ } >+ >+ protected String indent(String text, String indentation, String lineDelimiter) >+ { > if (text == null) > { > return null; > } > else > { >- String separator = getGenModel().getLineDelimiter() + indentation; >+ String separator = lineDelimiter + indentation; > int increment = separator.length() - 1; > StringBuffer stringBuffer = new StringBuffer(text); > for (int i = 0; i < stringBuffer.length(); ++i) >Index: src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenOperationImpl.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenOperationImpl.java,v >retrieving revision 1.36 >diff -u -r1.36 GenOperationImpl.java >--- src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenOperationImpl.java 18 Apr 2009 11:38:01 -0000 1.36 >+++ src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenOperationImpl.java 8 Sep 2009 17:31:07 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2002-2006 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -927,6 +927,42 @@ > } > } > >+ protected String getValidationExpression() >+ { >+ for (String validationDelegate : EcoreUtil.getValidationDelegates(getGenPackage().getEcorePackage())) >+ { >+ String expression = EcoreUtil.getAnnotation(getEcoreOperation(), validationDelegate, "body"); >+ if (expression != null) >+ { >+ return expression; >+ } >+ } >+ return null; >+ } >+ >+ public boolean hasValidationExpression() >+ { >+ return getValidationExpression() != null; >+ } >+ >+ public String getValidationExpression(String indentation) >+ { >+ return indent(getValidationExpression(), indentation + "\"", "\" +" + getGenModel().getNonNLS() + getGenModel().getLineDelimiter()); >+ } >+ >+ public String getValidationDelegate() >+ { >+ for (String validationDelegate : EcoreUtil.getValidationDelegates(getGenPackage().getEcorePackage())) >+ { >+ String expression = EcoreUtil.getAnnotation(getEcoreOperation(), validationDelegate, "body"); >+ if (expression != null) >+ { >+ return validationDelegate; >+ } >+ } >+ return null; >+ } >+ > public List<GenClassifier> getGenExceptions() > { > List<GenClassifier> result = new ArrayList<GenClassifier>(); >Index: src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenClassifierImpl.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenClassifierImpl.java,v >retrieving revision 1.14 >diff -u -r1.14 GenClassifierImpl.java >--- src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenClassifierImpl.java 10 Mar 2008 19:10:25 -0000 1.14 >+++ src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenClassifierImpl.java 8 Sep 2009 17:31:02 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2002-2006 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -303,4 +303,40 @@ > { > return getImportedInstanceClassName(); > } >+ >+ protected String getValidationExpression(String constraint) >+ { >+ for (String validationDelegate : EcoreUtil.getValidationDelegates(getGenPackage().getEcorePackage())) >+ { >+ String expression = EcoreUtil.getAnnotation(getEcoreClassifier(), validationDelegate, constraint); >+ if (expression != null) >+ { >+ return expression; >+ } >+ } >+ return null; >+ } >+ >+ public boolean hasValidationExpression(String constraint) >+ { >+ return getValidationExpression(constraint) != null; >+ } >+ >+ public String getValidationExpression(String constraint, String indentation) >+ { >+ return indent(getValidationExpression(constraint), indentation); >+ } >+ >+ public String getValidationDelegate(String constraint) >+ { >+ for (String validationDelegate : EcoreUtil.getValidationDelegates(getGenPackage().getEcorePackage())) >+ { >+ String expression = EcoreUtil.getAnnotation(getEcoreClassifier(), validationDelegate, constraint); >+ if (expression != null) >+ { >+ return validationDelegate; >+ } >+ } >+ return null; >+ } > } >Index: src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenFeatureImpl.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenFeatureImpl.java,v >retrieving revision 1.57 >diff -u -r1.57 GenFeatureImpl.java >--- src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenFeatureImpl.java 18 Apr 2009 11:38:01 -0000 1.57 >+++ src/org/eclipse/emf/codegen/ecore/genmodel/impl/GenFeatureImpl.java 8 Sep 2009 17:31:04 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2002-2006 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -33,6 +33,7 @@ > import org.eclipse.emf.codegen.ecore.genmodel.GenOperation; > import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; > import org.eclipse.emf.codegen.ecore.genmodel.GenPropertyKind; >+import org.eclipse.emf.codegen.util.CodeGenUtil; > import org.eclipse.emf.common.notify.Notification; > import org.eclipse.emf.common.notify.NotificationChain; > import org.eclipse.emf.common.util.EList; >@@ -969,7 +970,7 @@ > > public String getUpperName() > { >- return format(getName(), '_', null, false, true).toUpperCase(getGenModel().getLocale()); >+ return CodeGenUtil.upperName(getName(), getGenModel().getLocale()); > } > > public String getUncapName() >Index: model/GenModel.ecore >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/model/GenModel.ecore,v >retrieving revision 1.41 >diff -u -r1.41 GenModel.ecore >--- model/GenModel.ecore 9 Feb 2009 12:51:26 -0000 1.41 >+++ model/GenModel.ecore 8 Sep 2009 17:30:57 -0000 >@@ -308,5 +308,6 @@ > <eLiterals name="EMF23" value="1" literal="2.3"/> > <eLiterals name="EMF24" value="2" literal="2.4"/> > <eLiterals name="EMF25" value="3" literal="2.5"/> >+ <eLiterals name="EMF26" value="4" literal="2.6"/> > </eClassifiers> > </ecore:EPackage> >Index: model/GenModel.genmodel >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/model/GenModel.genmodel,v >retrieving revision 1.47 >diff -u -r1.47 GenModel.genmodel >--- model/GenModel.genmodel 11 Dec 2008 01:51:45 -0000 1.47 >+++ model/GenModel.genmodel 8 Sep 2009 17:30:59 -0000 >@@ -5,12 +5,10 @@ > creationCommands="false" editDirectory="/org.eclipse.emf.codegen.ecore.ui/src" > editorDirectory="/org.eclipse.emf.codegen.ecore.ui/src" modelPluginID="org.eclipse.emf.codegen.ecore" > runtimeJar="true" modelName="GenModel" editPluginClass="org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelEditPlugin" >- editorPluginClass="" updateClasspath="false" testsDirectory="" importerID="org.eclipse.emf.importer.rose" >+ editorPluginClass="" updateClasspath="false" testsDirectory="" importerID="org.eclipse.emf.importer.ecore" > complianceLevel="5.0" editPluginID="org.eclipse.emf.codegen.ecore.ui" language="en" > usedGenPackages="../../org.eclipse.emf.ecore/model/Ecore.genmodel#//ecore"> >- <foreignModel>GenModel.mdl</foreignModel> >- <foreignModel>VABASE_PLUGINS_PATH</foreignModel> >- <foreignModel>../..</foreignModel> >+ <foreignModel>GenModel.ecore</foreignModel> > <genPackages prefix="GenModel" basePackage="org.eclipse.emf.codegen.ecore" disposableProviderFactory="true" > multipleEditorPages="false" generateModelWizard="false" contentTypeIdentifier="org.eclipse.emf.codegen.genmodel" > ecorePackage="GenModel.ecore#/"> >@@ -45,6 +43,8 @@ > <genEnumLiterals ecoreEnumLiteral="GenModel.ecore#//GenRuntimeVersion/EMF22"/> > <genEnumLiterals ecoreEnumLiteral="GenModel.ecore#//GenRuntimeVersion/EMF23"/> > <genEnumLiterals ecoreEnumLiteral="GenModel.ecore#//GenRuntimeVersion/EMF24"/> >+ <genEnumLiterals ecoreEnumLiteral="GenModel.ecore#//GenRuntimeVersion/EMF25"/> >+ <genEnumLiterals ecoreEnumLiteral="GenModel.ecore#//GenRuntimeVersion/EMF26"/> > </genEnums> > <genClasses ecoreClass="GenModel.ecore#//GenModel"> > <genFeatures createChild="false" propertyCategory="All" propertyDescription="A copyright string to appear in the header of each generated artifact" >Index: src/org/eclipse/emf/codegen/ecore/genmodel/GenRuntimeVersion.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/src/org/eclipse/emf/codegen/ecore/genmodel/GenRuntimeVersion.java,v >retrieving revision 1.3 >diff -u -r1.3 GenRuntimeVersion.java >--- src/org/eclipse/emf/codegen/ecore/genmodel/GenRuntimeVersion.java 9 Feb 2009 12:51:26 -0000 1.3 >+++ src/org/eclipse/emf/codegen/ecore/genmodel/GenRuntimeVersion.java 8 Sep 2009 17:30:59 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2008 IBM Corporation and others. >+ * Copyright (c) 2008-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -66,7 +66,15 @@ > * @generated > * @ordered > */ >- EMF25(3, "EMF25", "2.5"); >+ EMF25(3, "EMF25", "2.5"), /** >+ * The '<em><b>EMF26</b></em>' literal object. >+ * <!-- begin-user-doc --> >+ * <!-- end-user-doc --> >+ * @see #EMF26_VALUE >+ * @generated >+ * @ordered >+ */ >+ EMF26(4, "EMF26", "2.6"); > > /** > * The '<em><b>EMF22</b></em>' literal value. >@@ -114,6 +122,18 @@ > public static final int EMF25_VALUE = 3; > > /** >+ * The '<em><b>EMF26</b></em>' literal value. >+ * <!-- begin-user-doc --> >+ * @since 2.6 >+ * <!-- end-user-doc --> >+ * @see #EMF26 >+ * @model literal="2.6" >+ * @generated >+ * @ordered >+ */ >+ public static final int EMF26_VALUE = 4; >+ >+ /** > * An array of all the '<em><b>Gen Runtime Version</b></em>' enumerators. > * <!-- begin-user-doc --> > * <!-- end-user-doc --> >@@ -126,6 +146,7 @@ > EMF23, > EMF24, > EMF25, >+ EMF26, > }; > > /** >@@ -188,6 +209,7 @@ > case EMF23_VALUE: return EMF23; > case EMF24_VALUE: return EMF24; > case EMF25_VALUE: return EMF25; >+ case EMF26_VALUE: return EMF26; > } > return null; > } >Index: src/org/eclipse/emf/codegen/ecore/genmodel/GenClassifier.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/src/org/eclipse/emf/codegen/ecore/genmodel/GenClassifier.java,v >retrieving revision 1.12 >diff -u -r1.12 GenClassifier.java >--- src/org/eclipse/emf/codegen/ecore/genmodel/GenClassifier.java 4 May 2008 17:03:27 -0000 1.12 >+++ src/org/eclipse/emf/codegen/ecore/genmodel/GenClassifier.java 8 Sep 2009 17:30:59 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2002-2006 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -127,4 +127,8 @@ > boolean hasOnlyDefaultConstraints(); > > String getGeneratedInstanceClassFlag(); >+ >+ boolean hasValidationExpression(String constraint); >+ String getValidationExpression(String constraint, String indentation); >+ String getValidationDelegate(String constraint); > } >Index: src/org/eclipse/emf/codegen/ecore/genmodel/GenOperation.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/src/org/eclipse/emf/codegen/ecore/genmodel/GenOperation.java,v >retrieving revision 1.18 >diff -u -r1.18 GenOperation.java >--- src/org/eclipse/emf/codegen/ecore/genmodel/GenOperation.java 4 May 2008 17:03:27 -0000 1.18 >+++ src/org/eclipse/emf/codegen/ecore/genmodel/GenOperation.java 8 Sep 2009 17:30:59 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2002-2006 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -191,6 +191,10 @@ > boolean hasBody(); > String getBody(String indentation); > >+ boolean hasValidationExpression(); >+ String getValidationExpression(String indentation); >+ String getValidationDelegate(); >+ > List<GenClassifier> getGenExceptions(); > > /** >Index: src/org/eclipse/emf/codegen/ecore/templates/model/Class.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/src/org/eclipse/emf/codegen/ecore/templates/model/Class.java,v >retrieving revision 1.85 >diff -u -r1.85 Class.java >--- src/org/eclipse/emf/codegen/ecore/templates/model/Class.java 11 Aug 2009 16:53:37 -0000 1.85 >+++ src/org/eclipse/emf/codegen/ecore/templates/model/Class.java 8 Sep 2009 17:31:14 -0000 >@@ -2,6 +2,7 @@ > > import java.util.*; > import org.eclipse.emf.codegen.ecore.genmodel.*; >+import org.eclipse.emf.codegen.util.CodeGenUtil; > > public class Class > { >@@ -1120,471 +1121,531 @@ > protected final String TEXT_1103 = "' "; > protected final String TEXT_1104 = " is set" + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\tthrow new UnsupportedOperationException();"; > protected final String TEXT_1105 = NL + "\t}" + NL; >- protected final String TEXT_1106 = NL + "\t/**"; >- protected final String TEXT_1107 = NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->"; >- protected final String TEXT_1108 = NL + "\t * <!-- begin-model-doc -->"; >- protected final String TEXT_1109 = NL + "\t * "; >- protected final String TEXT_1110 = NL + "\t * @param "; >- protected final String TEXT_1111 = NL + "\t * "; >- protected final String TEXT_1112 = NL + "\t * @param "; >- protected final String TEXT_1113 = " "; >- protected final String TEXT_1114 = NL + "\t * <!-- end-model-doc -->"; >- protected final String TEXT_1115 = NL + "\t * @model "; >- protected final String TEXT_1116 = NL + "\t * "; >- protected final String TEXT_1117 = NL + "\t * @model"; >- protected final String TEXT_1118 = NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1119 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1120 = NL + "\t"; >- protected final String TEXT_1121 = " "; >- protected final String TEXT_1122 = "("; >- protected final String TEXT_1123 = ")"; >- protected final String TEXT_1124 = ";" + NL; >- protected final String TEXT_1125 = NL + "\tpublic "; >- protected final String TEXT_1126 = " "; >- protected final String TEXT_1127 = "("; >- protected final String TEXT_1128 = ")"; >- protected final String TEXT_1129 = NL + "\t{"; >- protected final String TEXT_1130 = NL + "\t\t"; >- protected final String TEXT_1131 = NL + "\t\t// TODO: implement this method" + NL + "\t\t// -> specify the condition that violates the invariant" + NL + "\t\t// -> verify the details of the diagnostic, including severity and message" + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\tif (false)" + NL + "\t\t{" + NL + "\t\t\tif ("; >- protected final String TEXT_1132 = " != null)" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >- protected final String TEXT_1133 = ".add" + NL + "\t\t\t\t\t(new "; >- protected final String TEXT_1134 = NL + "\t\t\t\t\t\t("; >- protected final String TEXT_1135 = ".ERROR," + NL + "\t\t\t\t\t\t "; >- protected final String TEXT_1136 = ".DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t "; >- protected final String TEXT_1137 = "."; >- protected final String TEXT_1138 = "," + NL + "\t\t\t\t\t\t "; >- protected final String TEXT_1139 = ".INSTANCE.getString(\"_UI_GenericInvariant_diagnostic\", new Object[] { \""; >- protected final String TEXT_1140 = "\", "; >- protected final String TEXT_1141 = ".getObjectLabel(this, "; >- protected final String TEXT_1142 = ") }),"; >- protected final String TEXT_1143 = NL + "\t\t\t\t\t\t new Object [] { this }));" + NL + "\t\t\t}" + NL + "\t\t\treturn false;" + NL + "\t\t}" + NL + "\t\treturn true;"; >- protected final String TEXT_1144 = NL + "\t\t// TODO: implement this method" + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\tthrow new UnsupportedOperationException();"; >- protected final String TEXT_1145 = NL + "\t}" + NL; >- protected final String TEXT_1146 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1147 = NL + "\t@SuppressWarnings(\"unchecked\")"; >- protected final String TEXT_1148 = NL + "\t@Override"; >- protected final String TEXT_1149 = NL + "\tpublic "; >- protected final String TEXT_1150 = " eInverseAdd("; >- protected final String TEXT_1151 = " otherEnd, int featureID, "; >- protected final String TEXT_1152 = " msgs)" + NL + "\t{" + NL + "\t\tswitch (featureID"; >- protected final String TEXT_1153 = ")" + NL + "\t\t{"; >- protected final String TEXT_1154 = NL + "\t\t\tcase "; >- protected final String TEXT_1155 = ":"; >- protected final String TEXT_1156 = NL + "\t\t\t\treturn (("; >- protected final String TEXT_1157 = "("; >- protected final String TEXT_1158 = ".InternalMapView"; >- protected final String TEXT_1159 = ")"; >- protected final String TEXT_1160 = "()).eMap()).basicAdd(otherEnd, msgs);"; >- protected final String TEXT_1161 = NL + "\t\t\t\treturn ("; >- protected final String TEXT_1162 = "()).basicAdd(otherEnd, msgs);"; >- protected final String TEXT_1163 = NL + "\t\t\t\tif (eInternalContainer() != null)" + NL + "\t\t\t\t\tmsgs = eBasicRemoveFromContainer(msgs);"; >- protected final String TEXT_1164 = NL + "\t\t\t\treturn basicSet"; >- protected final String TEXT_1165 = "(("; >- protected final String TEXT_1166 = ")otherEnd, msgs);"; >- protected final String TEXT_1167 = NL + "\t\t\t\treturn eBasicSetContainer(otherEnd, "; >- protected final String TEXT_1168 = ", msgs);"; >- protected final String TEXT_1169 = NL + "\t\t\t\t"; >- protected final String TEXT_1170 = " "; >- protected final String TEXT_1171 = " = ("; >- protected final String TEXT_1172 = ")eVirtualGet("; >- protected final String TEXT_1173 = ");"; >- protected final String TEXT_1174 = NL + "\t\t\t\t"; >- protected final String TEXT_1175 = " "; >- protected final String TEXT_1176 = " = "; >- protected final String TEXT_1177 = "basicGet"; >- protected final String TEXT_1178 = "();"; >- protected final String TEXT_1179 = NL + "\t\t\t\tif ("; >- protected final String TEXT_1180 = " != null)"; >- protected final String TEXT_1181 = NL + "\t\t\t\t\tmsgs = (("; >- protected final String TEXT_1182 = ")"; >- protected final String TEXT_1183 = ").eInverseRemove(this, EOPPOSITE_FEATURE_BASE - "; >- protected final String TEXT_1184 = ", null, msgs);"; >- protected final String TEXT_1185 = NL + "\t\t\t\t\tmsgs = (("; >- protected final String TEXT_1186 = ")"; >- protected final String TEXT_1187 = ").eInverseRemove(this, "; >- protected final String TEXT_1188 = ", "; >- protected final String TEXT_1189 = ".class, msgs);"; >- protected final String TEXT_1190 = NL + "\t\t\t\treturn basicSet"; >- protected final String TEXT_1191 = "(("; >- protected final String TEXT_1192 = ")otherEnd, msgs);"; >- protected final String TEXT_1193 = NL + "\t\t}"; >- protected final String TEXT_1194 = NL + "\t\treturn super.eInverseAdd(otherEnd, featureID, msgs);"; >- protected final String TEXT_1195 = NL + "\t\treturn eDynamicInverseAdd(otherEnd, featureID, msgs);"; >- protected final String TEXT_1196 = NL + "\t}" + NL; >- protected final String TEXT_1197 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1198 = NL + "\t@Override"; >- protected final String TEXT_1199 = NL + "\tpublic "; >- protected final String TEXT_1200 = " eInverseRemove("; >- protected final String TEXT_1201 = " otherEnd, int featureID, "; >- protected final String TEXT_1202 = " msgs)" + NL + "\t{" + NL + "\t\tswitch (featureID"; >- protected final String TEXT_1203 = ")" + NL + "\t\t{"; >- protected final String TEXT_1204 = NL + "\t\t\tcase "; >- protected final String TEXT_1205 = ":"; >- protected final String TEXT_1206 = NL + "\t\t\t\treturn (("; >- protected final String TEXT_1207 = ")(("; >- protected final String TEXT_1208 = ".InternalMapView"; >- protected final String TEXT_1209 = ")"; >- protected final String TEXT_1210 = "()).eMap()).basicRemove(otherEnd, msgs);"; >- protected final String TEXT_1211 = NL + "\t\t\t\treturn (("; >- protected final String TEXT_1212 = ")(("; >- protected final String TEXT_1213 = ".Internal.Wrapper)"; >- protected final String TEXT_1214 = "()).featureMap()).basicRemove(otherEnd, msgs);"; >- protected final String TEXT_1215 = NL + "\t\t\t\treturn (("; >- protected final String TEXT_1216 = ")"; >- protected final String TEXT_1217 = "()).basicRemove(otherEnd, msgs);"; >- protected final String TEXT_1218 = NL + "\t\t\t\treturn eBasicSetContainer(null, "; >- protected final String TEXT_1219 = ", msgs);"; >- protected final String TEXT_1220 = NL + "\t\t\t\treturn basicUnset"; >- protected final String TEXT_1221 = "(msgs);"; >- protected final String TEXT_1222 = NL + "\t\t\t\treturn basicSet"; >- protected final String TEXT_1223 = "(null, msgs);"; >- protected final String TEXT_1224 = NL + "\t\t}"; >- protected final String TEXT_1225 = NL + "\t\treturn super.eInverseRemove(otherEnd, featureID, msgs);"; >- protected final String TEXT_1226 = NL + "\t\treturn eDynamicInverseRemove(otherEnd, featureID, msgs);"; >- protected final String TEXT_1227 = NL + "\t}" + NL; >- protected final String TEXT_1228 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1229 = NL + "\t@Override"; >- protected final String TEXT_1230 = NL + "\tpublic "; >- protected final String TEXT_1231 = " eBasicRemoveFromContainerFeature("; >- protected final String TEXT_1232 = " msgs)" + NL + "\t{" + NL + "\t\tswitch (eContainerFeatureID()"; >- protected final String TEXT_1233 = ")" + NL + "\t\t{"; >- protected final String TEXT_1234 = NL + "\t\t\tcase "; >- protected final String TEXT_1235 = ":" + NL + "\t\t\t\treturn eInternalContainer().eInverseRemove(this, "; >- protected final String TEXT_1236 = ", "; >- protected final String TEXT_1237 = ".class, msgs);"; >- protected final String TEXT_1238 = NL + "\t\t}"; >- protected final String TEXT_1239 = NL + "\t\treturn super.eBasicRemoveFromContainerFeature(msgs);"; >- protected final String TEXT_1240 = NL + "\t\treturn eDynamicBasicRemoveFromContainer(msgs);"; >- protected final String TEXT_1241 = NL + "\t}" + NL; >- protected final String TEXT_1242 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1243 = NL + "\t@Override"; >- protected final String TEXT_1244 = NL + "\tpublic Object eGet(int featureID, boolean resolve, boolean coreType)" + NL + "\t{" + NL + "\t\tswitch (featureID"; >- protected final String TEXT_1245 = ")" + NL + "\t\t{"; >- protected final String TEXT_1246 = NL + "\t\t\tcase "; >- protected final String TEXT_1247 = ":"; >- protected final String TEXT_1248 = NL + "\t\t\t\treturn "; >- protected final String TEXT_1249 = "();"; >- protected final String TEXT_1250 = NL + "\t\t\t\treturn "; >- protected final String TEXT_1251 = "() ? Boolean.TRUE : Boolean.FALSE;"; >- protected final String TEXT_1252 = NL + "\t\t\t\treturn new "; >- protected final String TEXT_1253 = "("; >- protected final String TEXT_1254 = "());"; >- protected final String TEXT_1255 = NL + "\t\t\t\tif (resolve) return "; >- protected final String TEXT_1256 = "();" + NL + "\t\t\t\treturn basicGet"; >- protected final String TEXT_1257 = "();"; >- protected final String TEXT_1258 = NL + "\t\t\t\tif (coreType) return (("; >- protected final String TEXT_1259 = ".InternalMapView"; >- protected final String TEXT_1260 = ")"; >- protected final String TEXT_1261 = "()).eMap();" + NL + "\t\t\t\telse return "; >- protected final String TEXT_1262 = "();"; >- protected final String TEXT_1263 = NL + "\t\t\t\tif (coreType) return "; >- protected final String TEXT_1264 = "();" + NL + "\t\t\t\telse return "; >- protected final String TEXT_1265 = "().map();"; >- protected final String TEXT_1266 = NL + "\t\t\t\tif (coreType) return (("; >- protected final String TEXT_1267 = ".Internal.Wrapper)"; >- protected final String TEXT_1268 = "()).featureMap();" + NL + "\t\t\t\treturn "; >- protected final String TEXT_1269 = "();"; >- protected final String TEXT_1270 = NL + "\t\t\t\tif (coreType) return "; >- protected final String TEXT_1271 = "();" + NL + "\t\t\t\treturn (("; >- protected final String TEXT_1272 = ".Internal)"; >- protected final String TEXT_1273 = "()).getWrapper();"; >- protected final String TEXT_1274 = NL + "\t\t\t\treturn "; >- protected final String TEXT_1275 = "();"; >- protected final String TEXT_1276 = NL + "\t\t}"; >- protected final String TEXT_1277 = NL + "\t\treturn super.eGet(featureID, resolve, coreType);"; >- protected final String TEXT_1278 = NL + "\t\treturn eDynamicGet(featureID, resolve, coreType);"; >- protected final String TEXT_1279 = NL + "\t}" + NL; >- protected final String TEXT_1280 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1281 = NL + "\t@SuppressWarnings(\"unchecked\")"; >- protected final String TEXT_1282 = NL + "\t@Override"; >- protected final String TEXT_1283 = NL + "\tpublic void eSet(int featureID, Object newValue)" + NL + "\t{" + NL + "\t\tswitch (featureID"; >- protected final String TEXT_1284 = ")" + NL + "\t\t{"; >- protected final String TEXT_1285 = NL + "\t\t\tcase "; >- protected final String TEXT_1286 = ":"; >- protected final String TEXT_1287 = NL + "\t\t\t\t(("; >- protected final String TEXT_1288 = ".Internal)(("; >- protected final String TEXT_1289 = ".Internal.Wrapper)"; >- protected final String TEXT_1290 = "()).featureMap()).set(newValue);"; >- protected final String TEXT_1291 = NL + "\t\t\t\t(("; >- protected final String TEXT_1292 = ".Internal)"; >- protected final String TEXT_1293 = "()).set(newValue);"; >- protected final String TEXT_1294 = NL + "\t\t\t\t(("; >- protected final String TEXT_1295 = ".Setting)(("; >- protected final String TEXT_1296 = ".InternalMapView"; >- protected final String TEXT_1297 = ")"; >- protected final String TEXT_1298 = "()).eMap()).set(newValue);"; >- protected final String TEXT_1299 = NL + "\t\t\t\t(("; >- protected final String TEXT_1300 = ".Setting)"; >- protected final String TEXT_1301 = "()).set(newValue);"; >- protected final String TEXT_1302 = NL + "\t\t\t\t"; >- protected final String TEXT_1303 = "().clear();" + NL + "\t\t\t\t"; >- protected final String TEXT_1304 = "().addAll(("; >- protected final String TEXT_1305 = "<? extends "; >- protected final String TEXT_1306 = ">"; >- protected final String TEXT_1307 = ")newValue);"; >- protected final String TEXT_1308 = NL + "\t\t\t\tset"; >- protected final String TEXT_1309 = "((("; >- protected final String TEXT_1310 = ")newValue)."; >- protected final String TEXT_1311 = "());"; >- protected final String TEXT_1312 = NL + "\t\t\t\tset"; >+ protected final String TEXT_1106 = NL + "\t/**" + NL + "\t * The cached validation expression for the '{@link #"; >+ protected final String TEXT_1107 = "("; >+ protected final String TEXT_1108 = ") <em>"; >+ protected final String TEXT_1109 = "</em>}' operation." + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @see #"; >+ protected final String TEXT_1110 = "("; >+ protected final String TEXT_1111 = ")" + NL + "\t * @generated" + NL + "\t */" + NL + "\tprotected static final "; >+ protected final String TEXT_1112 = " "; >+ protected final String TEXT_1113 = "__EXP = \""; >+ protected final String TEXT_1114 = "\";"; >+ protected final String TEXT_1115 = NL; >+ protected final String TEXT_1116 = NL + "\t/**"; >+ protected final String TEXT_1117 = NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->"; >+ protected final String TEXT_1118 = NL + "\t * <!-- begin-model-doc -->"; >+ protected final String TEXT_1119 = NL + "\t * "; >+ protected final String TEXT_1120 = NL + "\t * @param "; >+ protected final String TEXT_1121 = NL + "\t * "; >+ protected final String TEXT_1122 = NL + "\t * @param "; >+ protected final String TEXT_1123 = " "; >+ protected final String TEXT_1124 = NL + "\t * <!-- end-model-doc -->"; >+ protected final String TEXT_1125 = NL + "\t * @model "; >+ protected final String TEXT_1126 = NL + "\t * "; >+ protected final String TEXT_1127 = NL + "\t * @model"; >+ protected final String TEXT_1128 = NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1129 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1130 = NL + "\t"; >+ protected final String TEXT_1131 = " "; >+ protected final String TEXT_1132 = "("; >+ protected final String TEXT_1133 = ")"; >+ protected final String TEXT_1134 = ";" + NL; >+ protected final String TEXT_1135 = NL + "\tpublic "; >+ protected final String TEXT_1136 = " "; >+ protected final String TEXT_1137 = "("; >+ protected final String TEXT_1138 = ")"; >+ protected final String TEXT_1139 = NL + "\t{"; >+ protected final String TEXT_1140 = NL + "\t\t"; >+ protected final String TEXT_1141 = NL + "\t\t"; >+ protected final String TEXT_1142 = ".Registry registry = "; >+ protected final String TEXT_1143 = " == null ? "; >+ protected final String TEXT_1144 = ".Registry.INSTANCE : ("; >+ protected final String TEXT_1145 = ".Registry)"; >+ protected final String TEXT_1146 = ".get("; >+ protected final String TEXT_1147 = ".Registry.class);" + NL + "\t\t"; >+ protected final String TEXT_1148 = " delegate = (registry == null ? "; >+ protected final String TEXT_1149 = ".Registry.INSTANCE : registry).getValidationDelegate("; >+ protected final String TEXT_1150 = ".createURI(\""; >+ protected final String TEXT_1151 = "\"));"; >+ protected final String TEXT_1152 = NL + "\t\tif (delegate != null) {" + NL + "\t\t\ttry {" + NL + "\t\t\t\tif (!delegate.validate("; >+ protected final String TEXT_1153 = "__EXP, "; >+ protected final String TEXT_1154 = ", this, "; >+ protected final String TEXT_1155 = ")) {" + NL + "\t\t\t\t\tif (diagnostics != null) {" + NL + "\t\t\t\t\t\t"; >+ protected final String TEXT_1156 = ".add" + NL + "\t\t\t\t\t\t\t(new "; >+ protected final String TEXT_1157 = NL + "\t\t\t\t\t\t\t\t("; >+ protected final String TEXT_1158 = ".ERROR," + NL + "\t\t\t\t\t\t\t\t "; >+ protected final String TEXT_1159 = ".DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t\t\t "; >+ protected final String TEXT_1160 = "."; >+ protected final String TEXT_1161 = "," + NL + "\t\t\t\t\t\t\t\t "; >+ protected final String TEXT_1162 = ".INSTANCE.getString(\"_UI_GenericInvariant_diagnostic\", new Object[] { \""; >+ protected final String TEXT_1163 = "\", "; >+ protected final String TEXT_1164 = ".getObjectLabel(this, "; >+ protected final String TEXT_1165 = ") }),"; >+ protected final String TEXT_1166 = NL + "\t\t\t\t\t\t\t\t new Object [] { this }));" + NL + "\t\t\t\t\t}" + NL + "\t\t\t\t\treturn false;" + NL + "\t\t\t\t}" + NL + "\t\t\t\treturn true;" + NL + "\t\t\t} catch ("; >+ protected final String TEXT_1167 = " throwable) {" + NL + "\t\t\t\tif (diagnostics != null) {" + NL + "\t\t\t\t\t"; >+ protected final String TEXT_1168 = ".add" + NL + "\t\t\t\t\t\t(new "; >+ protected final String TEXT_1169 = NL + "\t\t\t\t\t\t\t("; >+ protected final String TEXT_1170 = ".ERROR," + NL + "\t\t\t\t\t\t\t "; >+ protected final String TEXT_1171 = ".DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t\t "; >+ protected final String TEXT_1172 = "."; >+ protected final String TEXT_1173 = "," + NL + "\t\t\t\t\t\t\t "; >+ protected final String TEXT_1174 = ".INSTANCE.getString(\"_UI_InvariantDelegateException_diagnostic\", new Object[] { \""; >+ protected final String TEXT_1175 = "\", "; >+ protected final String TEXT_1176 = ".getObjectLabel(this, "; >+ protected final String TEXT_1177 = "), throwable.getLocalizedMessage() }),"; >+ protected final String TEXT_1178 = NL + "\t\t\t\t\t\t\t new Object [] { this }));" + NL + "\t\t\t\t}" + NL + "\t\t\t\treturn false;" + NL + "\t\t\t}" + NL + "\t\t} else {" + NL + "\t\t\tif (diagnostics != null) {" + NL + "\t\t\t\t"; >+ protected final String TEXT_1179 = ".add" + NL + "\t\t\t\t\t(new "; >+ protected final String TEXT_1180 = NL + "\t\t\t\t\t\t("; >+ protected final String TEXT_1181 = ".ERROR," + NL + "\t\t\t\t\t\t "; >+ protected final String TEXT_1182 = ".DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t "; >+ protected final String TEXT_1183 = "."; >+ protected final String TEXT_1184 = "," + NL + "\t\t\t\t\t\t "; >+ protected final String TEXT_1185 = ".INSTANCE.getString(\"_UI_InvariantDelegateNotFound_diagnostic\", new Object[] { \""; >+ protected final String TEXT_1186 = "\", "; >+ protected final String TEXT_1187 = ".getObjectLabel(this, "; >+ protected final String TEXT_1188 = "), \""; >+ protected final String TEXT_1189 = "\" }),"; >+ protected final String TEXT_1190 = NL + "\t\t\t\t\t\t new Object [] { this }));" + NL + "\t\t\t}" + NL + "\t\t\treturn false;" + NL + "\t\t}"; >+ protected final String TEXT_1191 = NL + "\t\t// TODO: implement this method" + NL + "\t\t// -> specify the condition that violates the invariant" + NL + "\t\t// -> verify the details of the diagnostic, including severity and message" + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\tif (false)" + NL + "\t\t{" + NL + "\t\t\tif ("; >+ protected final String TEXT_1192 = " != null)" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >+ protected final String TEXT_1193 = ".add" + NL + "\t\t\t\t\t(new "; >+ protected final String TEXT_1194 = NL + "\t\t\t\t\t\t("; >+ protected final String TEXT_1195 = ".ERROR," + NL + "\t\t\t\t\t\t "; >+ protected final String TEXT_1196 = ".DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t "; >+ protected final String TEXT_1197 = "."; >+ protected final String TEXT_1198 = "," + NL + "\t\t\t\t\t\t "; >+ protected final String TEXT_1199 = ".INSTANCE.getString(\"_UI_GenericInvariant_diagnostic\", new Object[] { \""; >+ protected final String TEXT_1200 = "\", "; >+ protected final String TEXT_1201 = ".getObjectLabel(this, "; >+ protected final String TEXT_1202 = ") }),"; >+ protected final String TEXT_1203 = NL + "\t\t\t\t\t\t new Object [] { this }));" + NL + "\t\t\t}" + NL + "\t\t\treturn false;" + NL + "\t\t}" + NL + "\t\treturn true;"; >+ protected final String TEXT_1204 = NL + "\t\t// TODO: implement this method" + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\tthrow new UnsupportedOperationException();"; >+ protected final String TEXT_1205 = NL + "\t}" + NL; >+ protected final String TEXT_1206 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1207 = NL + "\t@SuppressWarnings(\"unchecked\")"; >+ protected final String TEXT_1208 = NL + "\t@Override"; >+ protected final String TEXT_1209 = NL + "\tpublic "; >+ protected final String TEXT_1210 = " eInverseAdd("; >+ protected final String TEXT_1211 = " otherEnd, int featureID, "; >+ protected final String TEXT_1212 = " msgs)" + NL + "\t{" + NL + "\t\tswitch (featureID"; >+ protected final String TEXT_1213 = ")" + NL + "\t\t{"; >+ protected final String TEXT_1214 = NL + "\t\t\tcase "; >+ protected final String TEXT_1215 = ":"; >+ protected final String TEXT_1216 = NL + "\t\t\t\treturn (("; >+ protected final String TEXT_1217 = "("; >+ protected final String TEXT_1218 = ".InternalMapView"; >+ protected final String TEXT_1219 = ")"; >+ protected final String TEXT_1220 = "()).eMap()).basicAdd(otherEnd, msgs);"; >+ protected final String TEXT_1221 = NL + "\t\t\t\treturn ("; >+ protected final String TEXT_1222 = "()).basicAdd(otherEnd, msgs);"; >+ protected final String TEXT_1223 = NL + "\t\t\t\tif (eInternalContainer() != null)" + NL + "\t\t\t\t\tmsgs = eBasicRemoveFromContainer(msgs);"; >+ protected final String TEXT_1224 = NL + "\t\t\t\treturn basicSet"; >+ protected final String TEXT_1225 = "(("; >+ protected final String TEXT_1226 = ")otherEnd, msgs);"; >+ protected final String TEXT_1227 = NL + "\t\t\t\treturn eBasicSetContainer(otherEnd, "; >+ protected final String TEXT_1228 = ", msgs);"; >+ protected final String TEXT_1229 = NL + "\t\t\t\t"; >+ protected final String TEXT_1230 = " "; >+ protected final String TEXT_1231 = " = ("; >+ protected final String TEXT_1232 = ")eVirtualGet("; >+ protected final String TEXT_1233 = ");"; >+ protected final String TEXT_1234 = NL + "\t\t\t\t"; >+ protected final String TEXT_1235 = " "; >+ protected final String TEXT_1236 = " = "; >+ protected final String TEXT_1237 = "basicGet"; >+ protected final String TEXT_1238 = "();"; >+ protected final String TEXT_1239 = NL + "\t\t\t\tif ("; >+ protected final String TEXT_1240 = " != null)"; >+ protected final String TEXT_1241 = NL + "\t\t\t\t\tmsgs = (("; >+ protected final String TEXT_1242 = ")"; >+ protected final String TEXT_1243 = ").eInverseRemove(this, EOPPOSITE_FEATURE_BASE - "; >+ protected final String TEXT_1244 = ", null, msgs);"; >+ protected final String TEXT_1245 = NL + "\t\t\t\t\tmsgs = (("; >+ protected final String TEXT_1246 = ")"; >+ protected final String TEXT_1247 = ").eInverseRemove(this, "; >+ protected final String TEXT_1248 = ", "; >+ protected final String TEXT_1249 = ".class, msgs);"; >+ protected final String TEXT_1250 = NL + "\t\t\t\treturn basicSet"; >+ protected final String TEXT_1251 = "(("; >+ protected final String TEXT_1252 = ")otherEnd, msgs);"; >+ protected final String TEXT_1253 = NL + "\t\t}"; >+ protected final String TEXT_1254 = NL + "\t\treturn super.eInverseAdd(otherEnd, featureID, msgs);"; >+ protected final String TEXT_1255 = NL + "\t\treturn eDynamicInverseAdd(otherEnd, featureID, msgs);"; >+ protected final String TEXT_1256 = NL + "\t}" + NL; >+ protected final String TEXT_1257 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1258 = NL + "\t@Override"; >+ protected final String TEXT_1259 = NL + "\tpublic "; >+ protected final String TEXT_1260 = " eInverseRemove("; >+ protected final String TEXT_1261 = " otherEnd, int featureID, "; >+ protected final String TEXT_1262 = " msgs)" + NL + "\t{" + NL + "\t\tswitch (featureID"; >+ protected final String TEXT_1263 = ")" + NL + "\t\t{"; >+ protected final String TEXT_1264 = NL + "\t\t\tcase "; >+ protected final String TEXT_1265 = ":"; >+ protected final String TEXT_1266 = NL + "\t\t\t\treturn (("; >+ protected final String TEXT_1267 = ")(("; >+ protected final String TEXT_1268 = ".InternalMapView"; >+ protected final String TEXT_1269 = ")"; >+ protected final String TEXT_1270 = "()).eMap()).basicRemove(otherEnd, msgs);"; >+ protected final String TEXT_1271 = NL + "\t\t\t\treturn (("; >+ protected final String TEXT_1272 = ")(("; >+ protected final String TEXT_1273 = ".Internal.Wrapper)"; >+ protected final String TEXT_1274 = "()).featureMap()).basicRemove(otherEnd, msgs);"; >+ protected final String TEXT_1275 = NL + "\t\t\t\treturn (("; >+ protected final String TEXT_1276 = ")"; >+ protected final String TEXT_1277 = "()).basicRemove(otherEnd, msgs);"; >+ protected final String TEXT_1278 = NL + "\t\t\t\treturn eBasicSetContainer(null, "; >+ protected final String TEXT_1279 = ", msgs);"; >+ protected final String TEXT_1280 = NL + "\t\t\t\treturn basicUnset"; >+ protected final String TEXT_1281 = "(msgs);"; >+ protected final String TEXT_1282 = NL + "\t\t\t\treturn basicSet"; >+ protected final String TEXT_1283 = "(null, msgs);"; >+ protected final String TEXT_1284 = NL + "\t\t}"; >+ protected final String TEXT_1285 = NL + "\t\treturn super.eInverseRemove(otherEnd, featureID, msgs);"; >+ protected final String TEXT_1286 = NL + "\t\treturn eDynamicInverseRemove(otherEnd, featureID, msgs);"; >+ protected final String TEXT_1287 = NL + "\t}" + NL; >+ protected final String TEXT_1288 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1289 = NL + "\t@Override"; >+ protected final String TEXT_1290 = NL + "\tpublic "; >+ protected final String TEXT_1291 = " eBasicRemoveFromContainerFeature("; >+ protected final String TEXT_1292 = " msgs)" + NL + "\t{" + NL + "\t\tswitch (eContainerFeatureID()"; >+ protected final String TEXT_1293 = ")" + NL + "\t\t{"; >+ protected final String TEXT_1294 = NL + "\t\t\tcase "; >+ protected final String TEXT_1295 = ":" + NL + "\t\t\t\treturn eInternalContainer().eInverseRemove(this, "; >+ protected final String TEXT_1296 = ", "; >+ protected final String TEXT_1297 = ".class, msgs);"; >+ protected final String TEXT_1298 = NL + "\t\t}"; >+ protected final String TEXT_1299 = NL + "\t\treturn super.eBasicRemoveFromContainerFeature(msgs);"; >+ protected final String TEXT_1300 = NL + "\t\treturn eDynamicBasicRemoveFromContainer(msgs);"; >+ protected final String TEXT_1301 = NL + "\t}" + NL; >+ protected final String TEXT_1302 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1303 = NL + "\t@Override"; >+ protected final String TEXT_1304 = NL + "\tpublic Object eGet(int featureID, boolean resolve, boolean coreType)" + NL + "\t{" + NL + "\t\tswitch (featureID"; >+ protected final String TEXT_1305 = ")" + NL + "\t\t{"; >+ protected final String TEXT_1306 = NL + "\t\t\tcase "; >+ protected final String TEXT_1307 = ":"; >+ protected final String TEXT_1308 = NL + "\t\t\t\treturn "; >+ protected final String TEXT_1309 = "();"; >+ protected final String TEXT_1310 = NL + "\t\t\t\treturn "; >+ protected final String TEXT_1311 = "() ? Boolean.TRUE : Boolean.FALSE;"; >+ protected final String TEXT_1312 = NL + "\t\t\t\treturn new "; > protected final String TEXT_1313 = "("; >- protected final String TEXT_1314 = "("; >- protected final String TEXT_1315 = ")"; >- protected final String TEXT_1316 = "newValue);"; >- protected final String TEXT_1317 = NL + "\t\t\t\treturn;"; >- protected final String TEXT_1318 = NL + "\t\t}"; >- protected final String TEXT_1319 = NL + "\t\tsuper.eSet(featureID, newValue);"; >- protected final String TEXT_1320 = NL + "\t\teDynamicSet(featureID, newValue);"; >- protected final String TEXT_1321 = NL + "\t}" + NL; >- protected final String TEXT_1322 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1323 = NL + "\t@Override"; >- protected final String TEXT_1324 = NL + "\tpublic void eUnset(int featureID)" + NL + "\t{" + NL + "\t\tswitch (featureID"; >- protected final String TEXT_1325 = ")" + NL + "\t\t{"; >- protected final String TEXT_1326 = NL + "\t\t\tcase "; >- protected final String TEXT_1327 = ":"; >- protected final String TEXT_1328 = NL + "\t\t\t\t(("; >- protected final String TEXT_1329 = ".Internal.Wrapper)"; >- protected final String TEXT_1330 = "()).featureMap().clear();"; >- protected final String TEXT_1331 = NL + "\t\t\t\t"; >- protected final String TEXT_1332 = "().clear();"; >- protected final String TEXT_1333 = NL + "\t\t\t\tunset"; >- protected final String TEXT_1334 = "();"; >- protected final String TEXT_1335 = NL + "\t\t\t\tset"; >- protected final String TEXT_1336 = "(("; >- protected final String TEXT_1337 = ")null);"; >- protected final String TEXT_1338 = NL + "\t\t\t\tset"; >- protected final String TEXT_1339 = "("; >- protected final String TEXT_1340 = ");"; >- protected final String TEXT_1341 = NL + "\t\t\t\treturn;"; >- protected final String TEXT_1342 = NL + "\t\t}"; >- protected final String TEXT_1343 = NL + "\t\tsuper.eUnset(featureID);"; >- protected final String TEXT_1344 = NL + "\t\teDynamicUnset(featureID);"; >- protected final String TEXT_1345 = NL + "\t}" + NL; >- protected final String TEXT_1346 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1347 = NL + "\t@SuppressWarnings(\"unchecked\")"; >- protected final String TEXT_1348 = NL + "\t@Override"; >- protected final String TEXT_1349 = NL + "\tpublic boolean eIsSet(int featureID)" + NL + "\t{" + NL + "\t\tswitch (featureID"; >- protected final String TEXT_1350 = ")" + NL + "\t\t{"; >- protected final String TEXT_1351 = NL + "\t\t\tcase "; >- protected final String TEXT_1352 = ":"; >- protected final String TEXT_1353 = NL + "\t\t\t\treturn !(("; >- protected final String TEXT_1354 = ".Internal.Wrapper)"; >- protected final String TEXT_1355 = "()).featureMap().isEmpty();"; >- protected final String TEXT_1356 = NL + "\t\t\t\treturn "; >- protected final String TEXT_1357 = " != null && !"; >- protected final String TEXT_1358 = ".featureMap().isEmpty();"; >- protected final String TEXT_1359 = NL + "\t\t\t\treturn "; >- protected final String TEXT_1360 = " != null && !"; >- protected final String TEXT_1361 = ".isEmpty();"; >+ protected final String TEXT_1314 = "());"; >+ protected final String TEXT_1315 = NL + "\t\t\t\tif (resolve) return "; >+ protected final String TEXT_1316 = "();" + NL + "\t\t\t\treturn basicGet"; >+ protected final String TEXT_1317 = "();"; >+ protected final String TEXT_1318 = NL + "\t\t\t\tif (coreType) return (("; >+ protected final String TEXT_1319 = ".InternalMapView"; >+ protected final String TEXT_1320 = ")"; >+ protected final String TEXT_1321 = "()).eMap();" + NL + "\t\t\t\telse return "; >+ protected final String TEXT_1322 = "();"; >+ protected final String TEXT_1323 = NL + "\t\t\t\tif (coreType) return "; >+ protected final String TEXT_1324 = "();" + NL + "\t\t\t\telse return "; >+ protected final String TEXT_1325 = "().map();"; >+ protected final String TEXT_1326 = NL + "\t\t\t\tif (coreType) return (("; >+ protected final String TEXT_1327 = ".Internal.Wrapper)"; >+ protected final String TEXT_1328 = "()).featureMap();" + NL + "\t\t\t\treturn "; >+ protected final String TEXT_1329 = "();"; >+ protected final String TEXT_1330 = NL + "\t\t\t\tif (coreType) return "; >+ protected final String TEXT_1331 = "();" + NL + "\t\t\t\treturn (("; >+ protected final String TEXT_1332 = ".Internal)"; >+ protected final String TEXT_1333 = "()).getWrapper();"; >+ protected final String TEXT_1334 = NL + "\t\t\t\treturn "; >+ protected final String TEXT_1335 = "();"; >+ protected final String TEXT_1336 = NL + "\t\t}"; >+ protected final String TEXT_1337 = NL + "\t\treturn super.eGet(featureID, resolve, coreType);"; >+ protected final String TEXT_1338 = NL + "\t\treturn eDynamicGet(featureID, resolve, coreType);"; >+ protected final String TEXT_1339 = NL + "\t}" + NL; >+ protected final String TEXT_1340 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1341 = NL + "\t@SuppressWarnings(\"unchecked\")"; >+ protected final String TEXT_1342 = NL + "\t@Override"; >+ protected final String TEXT_1343 = NL + "\tpublic void eSet(int featureID, Object newValue)" + NL + "\t{" + NL + "\t\tswitch (featureID"; >+ protected final String TEXT_1344 = ")" + NL + "\t\t{"; >+ protected final String TEXT_1345 = NL + "\t\t\tcase "; >+ protected final String TEXT_1346 = ":"; >+ protected final String TEXT_1347 = NL + "\t\t\t\t(("; >+ protected final String TEXT_1348 = ".Internal)(("; >+ protected final String TEXT_1349 = ".Internal.Wrapper)"; >+ protected final String TEXT_1350 = "()).featureMap()).set(newValue);"; >+ protected final String TEXT_1351 = NL + "\t\t\t\t(("; >+ protected final String TEXT_1352 = ".Internal)"; >+ protected final String TEXT_1353 = "()).set(newValue);"; >+ protected final String TEXT_1354 = NL + "\t\t\t\t(("; >+ protected final String TEXT_1355 = ".Setting)(("; >+ protected final String TEXT_1356 = ".InternalMapView"; >+ protected final String TEXT_1357 = ")"; >+ protected final String TEXT_1358 = "()).eMap()).set(newValue);"; >+ protected final String TEXT_1359 = NL + "\t\t\t\t(("; >+ protected final String TEXT_1360 = ".Setting)"; >+ protected final String TEXT_1361 = "()).set(newValue);"; > protected final String TEXT_1362 = NL + "\t\t\t\t"; >- protected final String TEXT_1363 = " "; >- protected final String TEXT_1364 = " = ("; >- protected final String TEXT_1365 = ")eVirtualGet("; >- protected final String TEXT_1366 = ");" + NL + "\t\t\t\treturn "; >- protected final String TEXT_1367 = " != null && !"; >- protected final String TEXT_1368 = ".isEmpty();"; >- protected final String TEXT_1369 = NL + "\t\t\t\treturn !"; >- protected final String TEXT_1370 = "().isEmpty();"; >- protected final String TEXT_1371 = NL + "\t\t\t\treturn isSet"; >- protected final String TEXT_1372 = "();"; >- protected final String TEXT_1373 = NL + "\t\t\t\treturn "; >- protected final String TEXT_1374 = " != null;"; >- protected final String TEXT_1375 = NL + "\t\t\t\treturn eVirtualGet("; >- protected final String TEXT_1376 = ") != null;"; >- protected final String TEXT_1377 = NL + "\t\t\t\treturn basicGet"; >- protected final String TEXT_1378 = "() != null;"; >- protected final String TEXT_1379 = NL + "\t\t\t\treturn "; >- protected final String TEXT_1380 = " != null;"; >- protected final String TEXT_1381 = NL + "\t\t\t\treturn eVirtualGet("; >- protected final String TEXT_1382 = ") != null;"; >- protected final String TEXT_1383 = NL + "\t\t\t\treturn "; >- protected final String TEXT_1384 = "() != null;"; >- protected final String TEXT_1385 = NL + "\t\t\t\treturn (("; >- protected final String TEXT_1386 = " & "; >- protected final String TEXT_1387 = "_EFLAG) != 0) != "; >- protected final String TEXT_1388 = ";"; >- protected final String TEXT_1389 = NL + "\t\t\t\treturn ("; >- protected final String TEXT_1390 = " & "; >- protected final String TEXT_1391 = "_EFLAG) != "; >- protected final String TEXT_1392 = "_EFLAG_DEFAULT;"; >- protected final String TEXT_1393 = NL + "\t\t\t\treturn "; >- protected final String TEXT_1394 = " != "; >- protected final String TEXT_1395 = ";"; >- protected final String TEXT_1396 = NL + "\t\t\t\treturn eVirtualGet("; >- protected final String TEXT_1397 = ", "; >- protected final String TEXT_1398 = ") != "; >- protected final String TEXT_1399 = ";"; >- protected final String TEXT_1400 = NL + "\t\t\t\treturn "; >- protected final String TEXT_1401 = "() != "; >- protected final String TEXT_1402 = ";"; >- protected final String TEXT_1403 = NL + "\t\t\t\treturn "; >- protected final String TEXT_1404 = " == null ? "; >- protected final String TEXT_1405 = " != null : !"; >- protected final String TEXT_1406 = ".equals("; >- protected final String TEXT_1407 = ");"; >- protected final String TEXT_1408 = NL + "\t\t\t\t"; >- protected final String TEXT_1409 = " "; >- protected final String TEXT_1410 = " = ("; >- protected final String TEXT_1411 = ")eVirtualGet("; >- protected final String TEXT_1412 = ", "; >- protected final String TEXT_1413 = ");" + NL + "\t\t\t\treturn "; >- protected final String TEXT_1414 = " == null ? "; >- protected final String TEXT_1415 = " != null : !"; >- protected final String TEXT_1416 = ".equals("; >- protected final String TEXT_1417 = ");"; >- protected final String TEXT_1418 = NL + "\t\t\t\treturn "; >- protected final String TEXT_1419 = " == null ? "; >- protected final String TEXT_1420 = "() != null : !"; >- protected final String TEXT_1421 = ".equals("; >- protected final String TEXT_1422 = "());"; >- protected final String TEXT_1423 = NL + "\t\t}"; >- protected final String TEXT_1424 = NL + "\t\treturn super.eIsSet(featureID);"; >- protected final String TEXT_1425 = NL + "\t\treturn eDynamicIsSet(featureID);"; >- protected final String TEXT_1426 = NL + "\t}" + NL; >- protected final String TEXT_1427 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1428 = NL + "\t@Override"; >- protected final String TEXT_1429 = NL + "\tpublic int eBaseStructuralFeatureID(int derivedFeatureID, Class"; >- protected final String TEXT_1430 = " baseClass)" + NL + "\t{"; >- protected final String TEXT_1431 = NL + "\t\tif (baseClass == "; >- protected final String TEXT_1432 = ".class)" + NL + "\t\t{" + NL + "\t\t\tswitch (derivedFeatureID"; >- protected final String TEXT_1433 = ")" + NL + "\t\t\t{"; >- protected final String TEXT_1434 = NL + "\t\t\t\tcase "; >- protected final String TEXT_1435 = ": return "; >- protected final String TEXT_1436 = ";"; >- protected final String TEXT_1437 = NL + "\t\t\t\tdefault: return -1;" + NL + "\t\t\t}" + NL + "\t\t}"; >- protected final String TEXT_1438 = NL + "\t\treturn super.eBaseStructuralFeatureID(derivedFeatureID, baseClass);" + NL + "\t}"; >- protected final String TEXT_1439 = NL + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1440 = NL + "\t@Override"; >- protected final String TEXT_1441 = NL + "\tpublic int eDerivedStructuralFeatureID(int baseFeatureID, Class"; >- protected final String TEXT_1442 = " baseClass)" + NL + "\t{"; >- protected final String TEXT_1443 = NL + "\t\tif (baseClass == "; >- protected final String TEXT_1444 = ".class)" + NL + "\t\t{" + NL + "\t\t\tswitch (baseFeatureID)" + NL + "\t\t\t{"; >- protected final String TEXT_1445 = NL + "\t\t\t\tcase "; >- protected final String TEXT_1446 = ": return "; >- protected final String TEXT_1447 = ";"; >- protected final String TEXT_1448 = NL + "\t\t\t\tdefault: return -1;" + NL + "\t\t\t}" + NL + "\t\t}"; >- protected final String TEXT_1449 = NL + "\t\tif (baseClass == "; >- protected final String TEXT_1450 = ".class)" + NL + "\t\t{" + NL + "\t\t\tswitch (baseFeatureID"; >- protected final String TEXT_1451 = ")" + NL + "\t\t\t{"; >- protected final String TEXT_1452 = NL + "\t\t\t\tcase "; >- protected final String TEXT_1453 = ": return "; >- protected final String TEXT_1454 = ";"; >- protected final String TEXT_1455 = NL + "\t\t\t\tdefault: return -1;" + NL + "\t\t\t}" + NL + "\t\t}"; >- protected final String TEXT_1456 = NL + "\t\treturn super.eDerivedStructuralFeatureID(baseFeatureID, baseClass);" + NL + "\t}" + NL; >- protected final String TEXT_1457 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1458 = NL + "\t@Override"; >- protected final String TEXT_1459 = NL + "\tprotected Object[] eVirtualValues()" + NL + "\t{" + NL + "\t\treturn "; >- protected final String TEXT_1460 = ";" + NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1461 = NL + "\t@Override"; >- protected final String TEXT_1462 = NL + "\tprotected void eSetVirtualValues(Object[] newValues)" + NL + "\t{" + NL + "\t\t"; >- protected final String TEXT_1463 = " = newValues;" + NL + "\t}" + NL; >- protected final String TEXT_1464 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1465 = NL + "\t@Override"; >- protected final String TEXT_1466 = NL + "\tprotected int eVirtualIndexBits(int offset)" + NL + "\t{" + NL + "\t\tswitch (offset)" + NL + "\t\t{"; >- protected final String TEXT_1467 = NL + "\t\t\tcase "; >- protected final String TEXT_1468 = " :" + NL + "\t\t\t\treturn "; >- protected final String TEXT_1469 = ";"; >- protected final String TEXT_1470 = NL + "\t\t\tdefault :" + NL + "\t\t\t\tthrow new IndexOutOfBoundsException();" + NL + "\t\t}" + NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1471 = NL + "\t@Override"; >- protected final String TEXT_1472 = NL + "\tprotected void eSetVirtualIndexBits(int offset, int newIndexBits)" + NL + "\t{" + NL + "\t\tswitch (offset)" + NL + "\t\t{"; >- protected final String TEXT_1473 = NL + "\t\t\tcase "; >- protected final String TEXT_1474 = " :" + NL + "\t\t\t\t"; >- protected final String TEXT_1475 = " = newIndexBits;" + NL + "\t\t\t\tbreak;"; >- protected final String TEXT_1476 = NL + "\t\t\tdefault :" + NL + "\t\t\t\tthrow new IndexOutOfBoundsException();" + NL + "\t\t}" + NL + "\t}" + NL; >- protected final String TEXT_1477 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1478 = NL + "\t@Override"; >- protected final String TEXT_1479 = NL + "\tpublic String toString()" + NL + "\t{" + NL + "\t\tif (eIsProxy()) return super.toString();" + NL + "" + NL + "\t\tStringBuffer result = new StringBuffer(super.toString());"; >- protected final String TEXT_1480 = NL + "\t\tresult.append(\" ("; >- protected final String TEXT_1481 = ": \");"; >- protected final String TEXT_1482 = NL + "\t\tresult.append(\", "; >- protected final String TEXT_1483 = ": \");"; >- protected final String TEXT_1484 = NL + "\t\tif (eVirtualIsSet("; >- protected final String TEXT_1485 = ")) result.append(eVirtualGet("; >- protected final String TEXT_1486 = ")); else result.append(\"<unset>\");"; >- protected final String TEXT_1487 = NL + "\t\tif ("; >- protected final String TEXT_1488 = "("; >- protected final String TEXT_1489 = " & "; >- protected final String TEXT_1490 = "_ESETFLAG) != 0"; >- protected final String TEXT_1491 = "ESet"; >- protected final String TEXT_1492 = ") result.append(("; >- protected final String TEXT_1493 = " & "; >- protected final String TEXT_1494 = "_EFLAG) != 0); else result.append(\"<unset>\");"; >- protected final String TEXT_1495 = NL + "\t\tif ("; >- protected final String TEXT_1496 = "("; >- protected final String TEXT_1497 = " & "; >- protected final String TEXT_1498 = "_ESETFLAG) != 0"; >- protected final String TEXT_1499 = "ESet"; >- protected final String TEXT_1500 = ") result.append("; >- protected final String TEXT_1501 = "_EFLAG_VALUES[("; >- protected final String TEXT_1502 = " & "; >- protected final String TEXT_1503 = "_EFLAG) >>> "; >- protected final String TEXT_1504 = "_EFLAG_OFFSET]); else result.append(\"<unset>\");"; >- protected final String TEXT_1505 = NL + "\t\tif ("; >- protected final String TEXT_1506 = "("; >- protected final String TEXT_1507 = " & "; >- protected final String TEXT_1508 = "_ESETFLAG) != 0"; >- protected final String TEXT_1509 = "ESet"; >- protected final String TEXT_1510 = ") result.append("; >- protected final String TEXT_1511 = "); else result.append(\"<unset>\");"; >- protected final String TEXT_1512 = NL + "\t\tresult.append(eVirtualGet("; >- protected final String TEXT_1513 = ", "; >- protected final String TEXT_1514 = "));"; >- protected final String TEXT_1515 = NL + "\t\tresult.append(("; >- protected final String TEXT_1516 = " & "; >- protected final String TEXT_1517 = "_EFLAG) != 0);"; >- protected final String TEXT_1518 = NL + "\t\tresult.append("; >- protected final String TEXT_1519 = "_EFLAG_VALUES[("; >- protected final String TEXT_1520 = " & "; >- protected final String TEXT_1521 = "_EFLAG) >>> "; >- protected final String TEXT_1522 = "_EFLAG_OFFSET]);"; >- protected final String TEXT_1523 = NL + "\t\tresult.append("; >- protected final String TEXT_1524 = ");"; >- protected final String TEXT_1525 = NL + "\t\tresult.append(')');" + NL + "\t\treturn result.toString();" + NL + "\t}" + NL; >- protected final String TEXT_1526 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tprotected int hash = -1;" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic int getHash()" + NL + "\t{" + NL + "\t\tif (hash == -1)" + NL + "\t\t{" + NL + "\t\t\t"; >- protected final String TEXT_1527 = " theKey = getKey();" + NL + "\t\t\thash = (theKey == null ? 0 : theKey.hashCode());" + NL + "\t\t}" + NL + "\t\treturn hash;" + NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic void setHash(int hash)" + NL + "\t{" + NL + "\t\tthis.hash = hash;" + NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic "; >- protected final String TEXT_1528 = " getKey()" + NL + "\t{"; >- protected final String TEXT_1529 = NL + "\t\treturn new "; >- protected final String TEXT_1530 = "(getTypedKey());"; >- protected final String TEXT_1531 = NL + "\t\treturn getTypedKey();"; >- protected final String TEXT_1532 = NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic void setKey("; >- protected final String TEXT_1533 = " key)" + NL + "\t{"; >- protected final String TEXT_1534 = NL + "\t\tgetTypedKey().addAll("; >- protected final String TEXT_1535 = "("; >- protected final String TEXT_1536 = ")"; >- protected final String TEXT_1537 = "key);"; >- protected final String TEXT_1538 = NL + "\t\tsetTypedKey(key);"; >- protected final String TEXT_1539 = NL + "\t\tsetTypedKey((("; >- protected final String TEXT_1540 = ")key)."; >- protected final String TEXT_1541 = "());"; >- protected final String TEXT_1542 = NL + "\t\tsetTypedKey(("; >- protected final String TEXT_1543 = ")key);"; >- protected final String TEXT_1544 = NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic "; >- protected final String TEXT_1545 = " getValue()" + NL + "\t{"; >- protected final String TEXT_1546 = NL + "\t\treturn new "; >- protected final String TEXT_1547 = "(getTypedValue());"; >- protected final String TEXT_1548 = NL + "\t\treturn getTypedValue();"; >- protected final String TEXT_1549 = NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic "; >- protected final String TEXT_1550 = " setValue("; >- protected final String TEXT_1551 = " value)" + NL + "\t{" + NL + "\t\t"; >- protected final String TEXT_1552 = " oldValue = getValue();"; >- protected final String TEXT_1553 = NL + "\t\tgetTypedValue().clear();" + NL + "\t\tgetTypedValue().addAll("; >- protected final String TEXT_1554 = "("; >- protected final String TEXT_1555 = ")"; >- protected final String TEXT_1556 = "value);"; >- protected final String TEXT_1557 = NL + "\t\tsetTypedValue(value);"; >- protected final String TEXT_1558 = NL + "\t\tsetTypedValue((("; >- protected final String TEXT_1559 = ")value)."; >- protected final String TEXT_1560 = "());"; >- protected final String TEXT_1561 = NL + "\t\tsetTypedValue(("; >- protected final String TEXT_1562 = ")value);"; >- protected final String TEXT_1563 = NL + "\t\treturn oldValue;" + NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_1564 = NL + "\t@SuppressWarnings(\"unchecked\")"; >- protected final String TEXT_1565 = NL + "\tpublic "; >- protected final String TEXT_1566 = " getEMap()" + NL + "\t{" + NL + "\t\t"; >- protected final String TEXT_1567 = " container = eContainer();" + NL + "\t\treturn container == null ? null : ("; >- protected final String TEXT_1568 = ")container.eGet(eContainmentFeature());" + NL + "\t}" + NL; >- protected final String TEXT_1569 = NL + "} //"; >- protected final String TEXT_1570 = NL; >+ protected final String TEXT_1363 = "().clear();" + NL + "\t\t\t\t"; >+ protected final String TEXT_1364 = "().addAll(("; >+ protected final String TEXT_1365 = "<? extends "; >+ protected final String TEXT_1366 = ">"; >+ protected final String TEXT_1367 = ")newValue);"; >+ protected final String TEXT_1368 = NL + "\t\t\t\tset"; >+ protected final String TEXT_1369 = "((("; >+ protected final String TEXT_1370 = ")newValue)."; >+ protected final String TEXT_1371 = "());"; >+ protected final String TEXT_1372 = NL + "\t\t\t\tset"; >+ protected final String TEXT_1373 = "("; >+ protected final String TEXT_1374 = "("; >+ protected final String TEXT_1375 = ")"; >+ protected final String TEXT_1376 = "newValue);"; >+ protected final String TEXT_1377 = NL + "\t\t\t\treturn;"; >+ protected final String TEXT_1378 = NL + "\t\t}"; >+ protected final String TEXT_1379 = NL + "\t\tsuper.eSet(featureID, newValue);"; >+ protected final String TEXT_1380 = NL + "\t\teDynamicSet(featureID, newValue);"; >+ protected final String TEXT_1381 = NL + "\t}" + NL; >+ protected final String TEXT_1382 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1383 = NL + "\t@Override"; >+ protected final String TEXT_1384 = NL + "\tpublic void eUnset(int featureID)" + NL + "\t{" + NL + "\t\tswitch (featureID"; >+ protected final String TEXT_1385 = ")" + NL + "\t\t{"; >+ protected final String TEXT_1386 = NL + "\t\t\tcase "; >+ protected final String TEXT_1387 = ":"; >+ protected final String TEXT_1388 = NL + "\t\t\t\t(("; >+ protected final String TEXT_1389 = ".Internal.Wrapper)"; >+ protected final String TEXT_1390 = "()).featureMap().clear();"; >+ protected final String TEXT_1391 = NL + "\t\t\t\t"; >+ protected final String TEXT_1392 = "().clear();"; >+ protected final String TEXT_1393 = NL + "\t\t\t\tunset"; >+ protected final String TEXT_1394 = "();"; >+ protected final String TEXT_1395 = NL + "\t\t\t\tset"; >+ protected final String TEXT_1396 = "(("; >+ protected final String TEXT_1397 = ")null);"; >+ protected final String TEXT_1398 = NL + "\t\t\t\tset"; >+ protected final String TEXT_1399 = "("; >+ protected final String TEXT_1400 = ");"; >+ protected final String TEXT_1401 = NL + "\t\t\t\treturn;"; >+ protected final String TEXT_1402 = NL + "\t\t}"; >+ protected final String TEXT_1403 = NL + "\t\tsuper.eUnset(featureID);"; >+ protected final String TEXT_1404 = NL + "\t\teDynamicUnset(featureID);"; >+ protected final String TEXT_1405 = NL + "\t}" + NL; >+ protected final String TEXT_1406 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1407 = NL + "\t@SuppressWarnings(\"unchecked\")"; >+ protected final String TEXT_1408 = NL + "\t@Override"; >+ protected final String TEXT_1409 = NL + "\tpublic boolean eIsSet(int featureID)" + NL + "\t{" + NL + "\t\tswitch (featureID"; >+ protected final String TEXT_1410 = ")" + NL + "\t\t{"; >+ protected final String TEXT_1411 = NL + "\t\t\tcase "; >+ protected final String TEXT_1412 = ":"; >+ protected final String TEXT_1413 = NL + "\t\t\t\treturn !(("; >+ protected final String TEXT_1414 = ".Internal.Wrapper)"; >+ protected final String TEXT_1415 = "()).featureMap().isEmpty();"; >+ protected final String TEXT_1416 = NL + "\t\t\t\treturn "; >+ protected final String TEXT_1417 = " != null && !"; >+ protected final String TEXT_1418 = ".featureMap().isEmpty();"; >+ protected final String TEXT_1419 = NL + "\t\t\t\treturn "; >+ protected final String TEXT_1420 = " != null && !"; >+ protected final String TEXT_1421 = ".isEmpty();"; >+ protected final String TEXT_1422 = NL + "\t\t\t\t"; >+ protected final String TEXT_1423 = " "; >+ protected final String TEXT_1424 = " = ("; >+ protected final String TEXT_1425 = ")eVirtualGet("; >+ protected final String TEXT_1426 = ");" + NL + "\t\t\t\treturn "; >+ protected final String TEXT_1427 = " != null && !"; >+ protected final String TEXT_1428 = ".isEmpty();"; >+ protected final String TEXT_1429 = NL + "\t\t\t\treturn !"; >+ protected final String TEXT_1430 = "().isEmpty();"; >+ protected final String TEXT_1431 = NL + "\t\t\t\treturn isSet"; >+ protected final String TEXT_1432 = "();"; >+ protected final String TEXT_1433 = NL + "\t\t\t\treturn "; >+ protected final String TEXT_1434 = " != null;"; >+ protected final String TEXT_1435 = NL + "\t\t\t\treturn eVirtualGet("; >+ protected final String TEXT_1436 = ") != null;"; >+ protected final String TEXT_1437 = NL + "\t\t\t\treturn basicGet"; >+ protected final String TEXT_1438 = "() != null;"; >+ protected final String TEXT_1439 = NL + "\t\t\t\treturn "; >+ protected final String TEXT_1440 = " != null;"; >+ protected final String TEXT_1441 = NL + "\t\t\t\treturn eVirtualGet("; >+ protected final String TEXT_1442 = ") != null;"; >+ protected final String TEXT_1443 = NL + "\t\t\t\treturn "; >+ protected final String TEXT_1444 = "() != null;"; >+ protected final String TEXT_1445 = NL + "\t\t\t\treturn (("; >+ protected final String TEXT_1446 = " & "; >+ protected final String TEXT_1447 = "_EFLAG) != 0) != "; >+ protected final String TEXT_1448 = ";"; >+ protected final String TEXT_1449 = NL + "\t\t\t\treturn ("; >+ protected final String TEXT_1450 = " & "; >+ protected final String TEXT_1451 = "_EFLAG) != "; >+ protected final String TEXT_1452 = "_EFLAG_DEFAULT;"; >+ protected final String TEXT_1453 = NL + "\t\t\t\treturn "; >+ protected final String TEXT_1454 = " != "; >+ protected final String TEXT_1455 = ";"; >+ protected final String TEXT_1456 = NL + "\t\t\t\treturn eVirtualGet("; >+ protected final String TEXT_1457 = ", "; >+ protected final String TEXT_1458 = ") != "; >+ protected final String TEXT_1459 = ";"; >+ protected final String TEXT_1460 = NL + "\t\t\t\treturn "; >+ protected final String TEXT_1461 = "() != "; >+ protected final String TEXT_1462 = ";"; >+ protected final String TEXT_1463 = NL + "\t\t\t\treturn "; >+ protected final String TEXT_1464 = " == null ? "; >+ protected final String TEXT_1465 = " != null : !"; >+ protected final String TEXT_1466 = ".equals("; >+ protected final String TEXT_1467 = ");"; >+ protected final String TEXT_1468 = NL + "\t\t\t\t"; >+ protected final String TEXT_1469 = " "; >+ protected final String TEXT_1470 = " = ("; >+ protected final String TEXT_1471 = ")eVirtualGet("; >+ protected final String TEXT_1472 = ", "; >+ protected final String TEXT_1473 = ");" + NL + "\t\t\t\treturn "; >+ protected final String TEXT_1474 = " == null ? "; >+ protected final String TEXT_1475 = " != null : !"; >+ protected final String TEXT_1476 = ".equals("; >+ protected final String TEXT_1477 = ");"; >+ protected final String TEXT_1478 = NL + "\t\t\t\treturn "; >+ protected final String TEXT_1479 = " == null ? "; >+ protected final String TEXT_1480 = "() != null : !"; >+ protected final String TEXT_1481 = ".equals("; >+ protected final String TEXT_1482 = "());"; >+ protected final String TEXT_1483 = NL + "\t\t}"; >+ protected final String TEXT_1484 = NL + "\t\treturn super.eIsSet(featureID);"; >+ protected final String TEXT_1485 = NL + "\t\treturn eDynamicIsSet(featureID);"; >+ protected final String TEXT_1486 = NL + "\t}" + NL; >+ protected final String TEXT_1487 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1488 = NL + "\t@Override"; >+ protected final String TEXT_1489 = NL + "\tpublic int eBaseStructuralFeatureID(int derivedFeatureID, Class"; >+ protected final String TEXT_1490 = " baseClass)" + NL + "\t{"; >+ protected final String TEXT_1491 = NL + "\t\tif (baseClass == "; >+ protected final String TEXT_1492 = ".class)" + NL + "\t\t{" + NL + "\t\t\tswitch (derivedFeatureID"; >+ protected final String TEXT_1493 = ")" + NL + "\t\t\t{"; >+ protected final String TEXT_1494 = NL + "\t\t\t\tcase "; >+ protected final String TEXT_1495 = ": return "; >+ protected final String TEXT_1496 = ";"; >+ protected final String TEXT_1497 = NL + "\t\t\t\tdefault: return -1;" + NL + "\t\t\t}" + NL + "\t\t}"; >+ protected final String TEXT_1498 = NL + "\t\treturn super.eBaseStructuralFeatureID(derivedFeatureID, baseClass);" + NL + "\t}"; >+ protected final String TEXT_1499 = NL + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1500 = NL + "\t@Override"; >+ protected final String TEXT_1501 = NL + "\tpublic int eDerivedStructuralFeatureID(int baseFeatureID, Class"; >+ protected final String TEXT_1502 = " baseClass)" + NL + "\t{"; >+ protected final String TEXT_1503 = NL + "\t\tif (baseClass == "; >+ protected final String TEXT_1504 = ".class)" + NL + "\t\t{" + NL + "\t\t\tswitch (baseFeatureID)" + NL + "\t\t\t{"; >+ protected final String TEXT_1505 = NL + "\t\t\t\tcase "; >+ protected final String TEXT_1506 = ": return "; >+ protected final String TEXT_1507 = ";"; >+ protected final String TEXT_1508 = NL + "\t\t\t\tdefault: return -1;" + NL + "\t\t\t}" + NL + "\t\t}"; >+ protected final String TEXT_1509 = NL + "\t\tif (baseClass == "; >+ protected final String TEXT_1510 = ".class)" + NL + "\t\t{" + NL + "\t\t\tswitch (baseFeatureID"; >+ protected final String TEXT_1511 = ")" + NL + "\t\t\t{"; >+ protected final String TEXT_1512 = NL + "\t\t\t\tcase "; >+ protected final String TEXT_1513 = ": return "; >+ protected final String TEXT_1514 = ";"; >+ protected final String TEXT_1515 = NL + "\t\t\t\tdefault: return -1;" + NL + "\t\t\t}" + NL + "\t\t}"; >+ protected final String TEXT_1516 = NL + "\t\treturn super.eDerivedStructuralFeatureID(baseFeatureID, baseClass);" + NL + "\t}" + NL; >+ protected final String TEXT_1517 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1518 = NL + "\t@Override"; >+ protected final String TEXT_1519 = NL + "\tprotected Object[] eVirtualValues()" + NL + "\t{" + NL + "\t\treturn "; >+ protected final String TEXT_1520 = ";" + NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1521 = NL + "\t@Override"; >+ protected final String TEXT_1522 = NL + "\tprotected void eSetVirtualValues(Object[] newValues)" + NL + "\t{" + NL + "\t\t"; >+ protected final String TEXT_1523 = " = newValues;" + NL + "\t}" + NL; >+ protected final String TEXT_1524 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1525 = NL + "\t@Override"; >+ protected final String TEXT_1526 = NL + "\tprotected int eVirtualIndexBits(int offset)" + NL + "\t{" + NL + "\t\tswitch (offset)" + NL + "\t\t{"; >+ protected final String TEXT_1527 = NL + "\t\t\tcase "; >+ protected final String TEXT_1528 = " :" + NL + "\t\t\t\treturn "; >+ protected final String TEXT_1529 = ";"; >+ protected final String TEXT_1530 = NL + "\t\t\tdefault :" + NL + "\t\t\t\tthrow new IndexOutOfBoundsException();" + NL + "\t\t}" + NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1531 = NL + "\t@Override"; >+ protected final String TEXT_1532 = NL + "\tprotected void eSetVirtualIndexBits(int offset, int newIndexBits)" + NL + "\t{" + NL + "\t\tswitch (offset)" + NL + "\t\t{"; >+ protected final String TEXT_1533 = NL + "\t\t\tcase "; >+ protected final String TEXT_1534 = " :" + NL + "\t\t\t\t"; >+ protected final String TEXT_1535 = " = newIndexBits;" + NL + "\t\t\t\tbreak;"; >+ protected final String TEXT_1536 = NL + "\t\t\tdefault :" + NL + "\t\t\t\tthrow new IndexOutOfBoundsException();" + NL + "\t\t}" + NL + "\t}" + NL; >+ protected final String TEXT_1537 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1538 = NL + "\t@Override"; >+ protected final String TEXT_1539 = NL + "\tpublic String toString()" + NL + "\t{" + NL + "\t\tif (eIsProxy()) return super.toString();" + NL + "" + NL + "\t\tStringBuffer result = new StringBuffer(super.toString());"; >+ protected final String TEXT_1540 = NL + "\t\tresult.append(\" ("; >+ protected final String TEXT_1541 = ": \");"; >+ protected final String TEXT_1542 = NL + "\t\tresult.append(\", "; >+ protected final String TEXT_1543 = ": \");"; >+ protected final String TEXT_1544 = NL + "\t\tif (eVirtualIsSet("; >+ protected final String TEXT_1545 = ")) result.append(eVirtualGet("; >+ protected final String TEXT_1546 = ")); else result.append(\"<unset>\");"; >+ protected final String TEXT_1547 = NL + "\t\tif ("; >+ protected final String TEXT_1548 = "("; >+ protected final String TEXT_1549 = " & "; >+ protected final String TEXT_1550 = "_ESETFLAG) != 0"; >+ protected final String TEXT_1551 = "ESet"; >+ protected final String TEXT_1552 = ") result.append(("; >+ protected final String TEXT_1553 = " & "; >+ protected final String TEXT_1554 = "_EFLAG) != 0); else result.append(\"<unset>\");"; >+ protected final String TEXT_1555 = NL + "\t\tif ("; >+ protected final String TEXT_1556 = "("; >+ protected final String TEXT_1557 = " & "; >+ protected final String TEXT_1558 = "_ESETFLAG) != 0"; >+ protected final String TEXT_1559 = "ESet"; >+ protected final String TEXT_1560 = ") result.append("; >+ protected final String TEXT_1561 = "_EFLAG_VALUES[("; >+ protected final String TEXT_1562 = " & "; >+ protected final String TEXT_1563 = "_EFLAG) >>> "; >+ protected final String TEXT_1564 = "_EFLAG_OFFSET]); else result.append(\"<unset>\");"; >+ protected final String TEXT_1565 = NL + "\t\tif ("; >+ protected final String TEXT_1566 = "("; >+ protected final String TEXT_1567 = " & "; >+ protected final String TEXT_1568 = "_ESETFLAG) != 0"; >+ protected final String TEXT_1569 = "ESet"; >+ protected final String TEXT_1570 = ") result.append("; >+ protected final String TEXT_1571 = "); else result.append(\"<unset>\");"; >+ protected final String TEXT_1572 = NL + "\t\tresult.append(eVirtualGet("; >+ protected final String TEXT_1573 = ", "; >+ protected final String TEXT_1574 = "));"; >+ protected final String TEXT_1575 = NL + "\t\tresult.append(("; >+ protected final String TEXT_1576 = " & "; >+ protected final String TEXT_1577 = "_EFLAG) != 0);"; >+ protected final String TEXT_1578 = NL + "\t\tresult.append("; >+ protected final String TEXT_1579 = "_EFLAG_VALUES[("; >+ protected final String TEXT_1580 = " & "; >+ protected final String TEXT_1581 = "_EFLAG) >>> "; >+ protected final String TEXT_1582 = "_EFLAG_OFFSET]);"; >+ protected final String TEXT_1583 = NL + "\t\tresult.append("; >+ protected final String TEXT_1584 = ");"; >+ protected final String TEXT_1585 = NL + "\t\tresult.append(')');" + NL + "\t\treturn result.toString();" + NL + "\t}" + NL; >+ protected final String TEXT_1586 = NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tprotected int hash = -1;" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic int getHash()" + NL + "\t{" + NL + "\t\tif (hash == -1)" + NL + "\t\t{" + NL + "\t\t\t"; >+ protected final String TEXT_1587 = " theKey = getKey();" + NL + "\t\t\thash = (theKey == null ? 0 : theKey.hashCode());" + NL + "\t\t}" + NL + "\t\treturn hash;" + NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic void setHash(int hash)" + NL + "\t{" + NL + "\t\tthis.hash = hash;" + NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic "; >+ protected final String TEXT_1588 = " getKey()" + NL + "\t{"; >+ protected final String TEXT_1589 = NL + "\t\treturn new "; >+ protected final String TEXT_1590 = "(getTypedKey());"; >+ protected final String TEXT_1591 = NL + "\t\treturn getTypedKey();"; >+ protected final String TEXT_1592 = NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic void setKey("; >+ protected final String TEXT_1593 = " key)" + NL + "\t{"; >+ protected final String TEXT_1594 = NL + "\t\tgetTypedKey().addAll("; >+ protected final String TEXT_1595 = "("; >+ protected final String TEXT_1596 = ")"; >+ protected final String TEXT_1597 = "key);"; >+ protected final String TEXT_1598 = NL + "\t\tsetTypedKey(key);"; >+ protected final String TEXT_1599 = NL + "\t\tsetTypedKey((("; >+ protected final String TEXT_1600 = ")key)."; >+ protected final String TEXT_1601 = "());"; >+ protected final String TEXT_1602 = NL + "\t\tsetTypedKey(("; >+ protected final String TEXT_1603 = ")key);"; >+ protected final String TEXT_1604 = NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic "; >+ protected final String TEXT_1605 = " getValue()" + NL + "\t{"; >+ protected final String TEXT_1606 = NL + "\t\treturn new "; >+ protected final String TEXT_1607 = "(getTypedValue());"; >+ protected final String TEXT_1608 = NL + "\t\treturn getTypedValue();"; >+ protected final String TEXT_1609 = NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic "; >+ protected final String TEXT_1610 = " setValue("; >+ protected final String TEXT_1611 = " value)" + NL + "\t{" + NL + "\t\t"; >+ protected final String TEXT_1612 = " oldValue = getValue();"; >+ protected final String TEXT_1613 = NL + "\t\tgetTypedValue().clear();" + NL + "\t\tgetTypedValue().addAll("; >+ protected final String TEXT_1614 = "("; >+ protected final String TEXT_1615 = ")"; >+ protected final String TEXT_1616 = "value);"; >+ protected final String TEXT_1617 = NL + "\t\tsetTypedValue(value);"; >+ protected final String TEXT_1618 = NL + "\t\tsetTypedValue((("; >+ protected final String TEXT_1619 = ")value)."; >+ protected final String TEXT_1620 = "());"; >+ protected final String TEXT_1621 = NL + "\t\tsetTypedValue(("; >+ protected final String TEXT_1622 = ")value);"; >+ protected final String TEXT_1623 = NL + "\t\treturn oldValue;" + NL + "\t}" + NL + "" + NL + "\t/**" + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_1624 = NL + "\t@SuppressWarnings(\"unchecked\")"; >+ protected final String TEXT_1625 = NL + "\tpublic "; >+ protected final String TEXT_1626 = " getEMap()" + NL + "\t{" + NL + "\t\t"; >+ protected final String TEXT_1627 = " container = eContainer();" + NL + "\t\treturn container == null ? null : ("; >+ protected final String TEXT_1628 = ")container.eGet(eContainmentFeature());" + NL + "\t}" + NL; >+ protected final String TEXT_1629 = NL + "} //"; >+ protected final String TEXT_1630 = NL; > > public String generate(Object argument) > { >@@ -1593,7 +1654,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2002-2007 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -4189,1099 +4250,1228 @@ > }//for > }}.run(); > for (GenOperation genOperation : (isImplementation ? genClass.getImplementedGenOperations() : genClass.getDeclaredGenOperations())) { >- if (isInterface) { >+ if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF26_VALUE && isImplementation && genOperation.isInvariant() && genOperation.hasValidationExpression()) { > stringBuffer.append(TEXT_1106); >+ stringBuffer.append(genOperation.getName()); > stringBuffer.append(TEXT_1107); >- if (genOperation.hasDocumentation() || genOperation.hasParameterDocumentation()) { >+ stringBuffer.append(genOperation.getParameterTypes(", ")); > stringBuffer.append(TEXT_1108); >- if (genOperation.hasDocumentation()) { >+ stringBuffer.append(genOperation.getFormattedName()); > stringBuffer.append(TEXT_1109); >+ stringBuffer.append(genOperation.getName()); >+ stringBuffer.append(TEXT_1110); >+ stringBuffer.append(genOperation.getParameterTypes(", ")); >+ stringBuffer.append(TEXT_1111); >+ stringBuffer.append(genModel.getImportedName("java.lang.String")); >+ stringBuffer.append(TEXT_1112); >+ stringBuffer.append(CodeGenUtil.upperName(genOperation.getName(), genModel.getLocale())); >+ stringBuffer.append(genOperation.getGenParameters().size() == 0 ? "" : "__" + CodeGenUtil.upperName(genOperation.getParameterTypes("_", false), genModel.getLocale())); >+ stringBuffer.append(TEXT_1113); >+ stringBuffer.append(genOperation.getValidationExpression("\t\t")); >+ stringBuffer.append(TEXT_1114); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_1115); >+ } >+ if (isInterface) { >+ stringBuffer.append(TEXT_1116); >+ stringBuffer.append(TEXT_1117); >+ if (genOperation.hasDocumentation() || genOperation.hasParameterDocumentation()) { >+ stringBuffer.append(TEXT_1118); >+ if (genOperation.hasDocumentation()) { >+ stringBuffer.append(TEXT_1119); > stringBuffer.append(genOperation.getDocumentation(genModel.getIndentation(stringBuffer))); > } > for (GenParameter genParameter : genOperation.getGenParameters()) { > if (genParameter.hasDocumentation()) { String documentation = genParameter.getDocumentation(""); > if (documentation.contains("\n") || documentation.contains("\r")) { >- stringBuffer.append(TEXT_1110); >+ stringBuffer.append(TEXT_1120); > stringBuffer.append(genParameter.getName()); >- stringBuffer.append(TEXT_1111); >+ stringBuffer.append(TEXT_1121); > stringBuffer.append(genParameter.getDocumentation(genModel.getIndentation(stringBuffer))); > } else { >- stringBuffer.append(TEXT_1112); >+ stringBuffer.append(TEXT_1122); > stringBuffer.append(genParameter.getName()); >- stringBuffer.append(TEXT_1113); >+ stringBuffer.append(TEXT_1123); > stringBuffer.append(genParameter.getDocumentation(genModel.getIndentation(stringBuffer))); > } > } > } >- stringBuffer.append(TEXT_1114); >+ stringBuffer.append(TEXT_1124); > } > if (!genModel.isSuppressEMFModelTags()) { boolean first = true; for (StringTokenizer stringTokenizer = new StringTokenizer(genOperation.getModelInfo(), "\n\r"); stringTokenizer.hasMoreTokens(); ) { String modelInfo = stringTokenizer.nextToken(); if (first) { first = false; >- stringBuffer.append(TEXT_1115); >+ stringBuffer.append(TEXT_1125); > stringBuffer.append(modelInfo); > } else { >- stringBuffer.append(TEXT_1116); >+ stringBuffer.append(TEXT_1126); > stringBuffer.append(modelInfo); > }} if (first) { >- stringBuffer.append(TEXT_1117); >+ stringBuffer.append(TEXT_1127); > }} >- stringBuffer.append(TEXT_1118); >+ stringBuffer.append(TEXT_1128); > //Class/genOperation.javadoc.override.javajetinc > } else { >- stringBuffer.append(TEXT_1119); >+ stringBuffer.append(TEXT_1129); > if (isJDK50) { //Class/genOperation.annotations.insert.javajetinc > } > } > if (!isImplementation) { >- stringBuffer.append(TEXT_1120); >+ stringBuffer.append(TEXT_1130); > stringBuffer.append(genOperation.getTypeParameters(genClass)); > stringBuffer.append(genOperation.getImportedType(genClass)); >- stringBuffer.append(TEXT_1121); >+ stringBuffer.append(TEXT_1131); > stringBuffer.append(genOperation.getName()); >- stringBuffer.append(TEXT_1122); >+ stringBuffer.append(TEXT_1132); > stringBuffer.append(genOperation.getParameters(genClass)); >- stringBuffer.append(TEXT_1123); >+ stringBuffer.append(TEXT_1133); > stringBuffer.append(genOperation.getThrows(genClass)); >- stringBuffer.append(TEXT_1124); >+ stringBuffer.append(TEXT_1134); > } else { >- stringBuffer.append(TEXT_1125); >+ stringBuffer.append(TEXT_1135); > stringBuffer.append(genOperation.getTypeParameters(genClass)); > stringBuffer.append(genOperation.getImportedType(genClass)); >- stringBuffer.append(TEXT_1126); >+ stringBuffer.append(TEXT_1136); > stringBuffer.append(genOperation.getName()); >- stringBuffer.append(TEXT_1127); >+ stringBuffer.append(TEXT_1137); > stringBuffer.append(genOperation.getParameters(genClass)); >- stringBuffer.append(TEXT_1128); >+ stringBuffer.append(TEXT_1138); > stringBuffer.append(genOperation.getThrows(genClass)); >- stringBuffer.append(TEXT_1129); >+ stringBuffer.append(TEXT_1139); > if (genOperation.hasBody()) { >- stringBuffer.append(TEXT_1130); >+ stringBuffer.append(TEXT_1140); > stringBuffer.append(genOperation.getBody(genModel.getIndentation(stringBuffer))); > } else if (genOperation.isInvariant()) {GenClass opClass = genOperation.getGenClass(); String diagnostics = genOperation.getGenParameters().get(0).getName(); String context = genOperation.getGenParameters().get(1).getName(); >- stringBuffer.append(TEXT_1131); >+ if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF26_VALUE && genOperation.hasValidationExpression()) { >+ stringBuffer.append(TEXT_1141); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")); >+ stringBuffer.append(TEXT_1142); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_1143); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")); >+ stringBuffer.append(TEXT_1144); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")); >+ stringBuffer.append(TEXT_1145); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_1146); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")); >+ stringBuffer.append(TEXT_1147); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")); >+ stringBuffer.append(TEXT_1148); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")); >+ stringBuffer.append(TEXT_1149); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.URI")); >+ stringBuffer.append(TEXT_1150); >+ stringBuffer.append(genOperation.getValidationDelegate()); >+ stringBuffer.append(TEXT_1151); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_1152); >+ stringBuffer.append(CodeGenUtil.upperName(genOperation.getName(), genModel.getLocale())); >+ stringBuffer.append(genOperation.getGenParameters().size() == 0 ? "" : "__" + CodeGenUtil.upperName(genOperation.getParameterTypes("_", false), genModel.getLocale())); >+ stringBuffer.append(TEXT_1153); >+ stringBuffer.append(genClass.getQualifiedClassifierAccessor()); >+ stringBuffer.append(TEXT_1154); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_1155); > stringBuffer.append(diagnostics); >- stringBuffer.append(TEXT_1132); >+ stringBuffer.append(TEXT_1156); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")); >+ stringBuffer.append(TEXT_1157); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(TEXT_1158); >+ stringBuffer.append(opClass.getGenPackage().getImportedValidatorClassName()); >+ stringBuffer.append(TEXT_1159); >+ stringBuffer.append(opClass.getGenPackage().getImportedValidatorClassName()); >+ stringBuffer.append(TEXT_1160); >+ stringBuffer.append(opClass.getOperationID(genOperation)); >+ stringBuffer.append(TEXT_1161); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")); >+ stringBuffer.append(TEXT_1162); >+ stringBuffer.append(genOperation.getName()); >+ stringBuffer.append(TEXT_1163); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.EObjectValidator")); >+ stringBuffer.append(TEXT_1164); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_1165); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(genModel.getNonNLS(2)); >+ stringBuffer.append(TEXT_1166); >+ stringBuffer.append(genModel.getImportedName("java.lang.Throwable")); >+ stringBuffer.append(TEXT_1167); > stringBuffer.append(diagnostics); >- stringBuffer.append(TEXT_1133); >+ stringBuffer.append(TEXT_1168); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")); >- stringBuffer.append(TEXT_1134); >+ stringBuffer.append(TEXT_1169); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >- stringBuffer.append(TEXT_1135); >+ stringBuffer.append(TEXT_1170); > stringBuffer.append(opClass.getGenPackage().getImportedValidatorClassName()); >- stringBuffer.append(TEXT_1136); >+ stringBuffer.append(TEXT_1171); > stringBuffer.append(opClass.getGenPackage().getImportedValidatorClassName()); >- stringBuffer.append(TEXT_1137); >+ stringBuffer.append(TEXT_1172); > stringBuffer.append(opClass.getOperationID(genOperation)); >- stringBuffer.append(TEXT_1138); >+ stringBuffer.append(TEXT_1173); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")); >- stringBuffer.append(TEXT_1139); >+ stringBuffer.append(TEXT_1174); > stringBuffer.append(genOperation.getName()); >- stringBuffer.append(TEXT_1140); >+ stringBuffer.append(TEXT_1175); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.EObjectValidator")); >- stringBuffer.append(TEXT_1141); >+ stringBuffer.append(TEXT_1176); > stringBuffer.append(context); >- stringBuffer.append(TEXT_1142); >+ stringBuffer.append(TEXT_1177); > stringBuffer.append(genModel.getNonNLS()); > stringBuffer.append(genModel.getNonNLS(2)); >- stringBuffer.append(TEXT_1143); >+ stringBuffer.append(TEXT_1178); >+ stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_1179); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")); >+ stringBuffer.append(TEXT_1180); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(TEXT_1181); >+ stringBuffer.append(opClass.getGenPackage().getImportedValidatorClassName()); >+ stringBuffer.append(TEXT_1182); >+ stringBuffer.append(opClass.getGenPackage().getImportedValidatorClassName()); >+ stringBuffer.append(TEXT_1183); >+ stringBuffer.append(opClass.getOperationID(genOperation)); >+ stringBuffer.append(TEXT_1184); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")); >+ stringBuffer.append(TEXT_1185); >+ stringBuffer.append(genOperation.getName()); >+ stringBuffer.append(TEXT_1186); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.EObjectValidator")); >+ stringBuffer.append(TEXT_1187); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_1188); >+ stringBuffer.append(genOperation.getValidationDelegate()); >+ stringBuffer.append(TEXT_1189); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(genModel.getNonNLS(2)); >+ stringBuffer.append(genModel.getNonNLS(3)); >+ stringBuffer.append(TEXT_1190); > } else { >- stringBuffer.append(TEXT_1144); >+ stringBuffer.append(TEXT_1191); >+ stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_1192); >+ stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_1193); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")); >+ stringBuffer.append(TEXT_1194); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(TEXT_1195); >+ stringBuffer.append(opClass.getGenPackage().getImportedValidatorClassName()); >+ stringBuffer.append(TEXT_1196); >+ stringBuffer.append(opClass.getGenPackage().getImportedValidatorClassName()); >+ stringBuffer.append(TEXT_1197); >+ stringBuffer.append(opClass.getOperationID(genOperation)); >+ stringBuffer.append(TEXT_1198); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")); >+ stringBuffer.append(TEXT_1199); >+ stringBuffer.append(genOperation.getName()); >+ stringBuffer.append(TEXT_1200); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.EObjectValidator")); >+ stringBuffer.append(TEXT_1201); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_1202); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(genModel.getNonNLS(2)); >+ stringBuffer.append(TEXT_1203); >+ } >+ } else { >+ stringBuffer.append(TEXT_1204); > //Class/implementedGenOperation.todo.override.javajetinc > } >- stringBuffer.append(TEXT_1145); >+ stringBuffer.append(TEXT_1205); > } > //Class/implementedGenOperation.override.javajetinc > }//for > if (isImplementation && !genModel.isReflectiveDelegation() && genClass.implementsAny(genClass.getEInverseAddGenFeatures())) { >- stringBuffer.append(TEXT_1146); >+ stringBuffer.append(TEXT_1206); > if (genModel.useGenerics()) { > for (GenFeature genFeature : genClass.getEInverseAddGenFeatures()) { > if (genFeature.isUncheckedCast(genClass)) { >- stringBuffer.append(TEXT_1147); >+ stringBuffer.append(TEXT_1207); > break; } > } > } > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1148); >+ stringBuffer.append(TEXT_1208); > } >- stringBuffer.append(TEXT_1149); >+ stringBuffer.append(TEXT_1209); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.notify.NotificationChain")); >- stringBuffer.append(TEXT_1150); >+ stringBuffer.append(TEXT_1210); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.InternalEObject")); >- stringBuffer.append(TEXT_1151); >+ stringBuffer.append(TEXT_1211); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.notify.NotificationChain")); >- stringBuffer.append(TEXT_1152); >+ stringBuffer.append(TEXT_1212); > stringBuffer.append(negativeOffsetCorrection); >- stringBuffer.append(TEXT_1153); >+ stringBuffer.append(TEXT_1213); > for (GenFeature genFeature : genClass.getEInverseAddGenFeatures()) { >- stringBuffer.append(TEXT_1154); >+ stringBuffer.append(TEXT_1214); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); >- stringBuffer.append(TEXT_1155); >+ stringBuffer.append(TEXT_1215); > if (genFeature.isListType()) { String cast = "(" + genModel.getImportedName("org.eclipse.emf.ecore.util.InternalEList") + (!genModel.useGenerics() ? ")" : "<" + genModel.getImportedName("org.eclipse.emf.ecore.InternalEObject") + ">)(" + genModel.getImportedName("org.eclipse.emf.ecore.util.InternalEList") + "<?>)"); > if (genFeature.isMapType() && genFeature.isEffectiveSuppressEMFTypes()) { >- stringBuffer.append(TEXT_1156); >+ stringBuffer.append(TEXT_1216); > stringBuffer.append(cast); >- stringBuffer.append(TEXT_1157); >+ stringBuffer.append(TEXT_1217); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.EMap")); >- stringBuffer.append(TEXT_1158); >+ stringBuffer.append(TEXT_1218); > stringBuffer.append(genFeature.getImportedMapTemplateArguments(genClass)); >- stringBuffer.append(TEXT_1159); >+ stringBuffer.append(TEXT_1219); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1160); >+ stringBuffer.append(TEXT_1220); > } else { >- stringBuffer.append(TEXT_1161); >+ stringBuffer.append(TEXT_1221); > stringBuffer.append(cast); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1162); >+ stringBuffer.append(TEXT_1222); > } > } else if (genFeature.isContainer()) { >- stringBuffer.append(TEXT_1163); >+ stringBuffer.append(TEXT_1223); > if (genFeature.isBasicSet()) { >- stringBuffer.append(TEXT_1164); >+ stringBuffer.append(TEXT_1224); > stringBuffer.append(genFeature.getAccessorName()); >- stringBuffer.append(TEXT_1165); >+ stringBuffer.append(TEXT_1225); > stringBuffer.append(genFeature.getImportedType(genClass)); >- stringBuffer.append(TEXT_1166); >+ stringBuffer.append(TEXT_1226); > } else { >- stringBuffer.append(TEXT_1167); >+ stringBuffer.append(TEXT_1227); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(positiveOffsetCorrection); >- stringBuffer.append(TEXT_1168); >+ stringBuffer.append(TEXT_1228); > } > } else { > if (genClass.getImplementingGenModel(genFeature).isVirtualDelegation()) { >- stringBuffer.append(TEXT_1169); >+ stringBuffer.append(TEXT_1229); > stringBuffer.append(genFeature.getImportedType(genClass)); >- stringBuffer.append(TEXT_1170); >+ stringBuffer.append(TEXT_1230); > stringBuffer.append(genFeature.getSafeName()); >- stringBuffer.append(TEXT_1171); >+ stringBuffer.append(TEXT_1231); > stringBuffer.append(genFeature.getImportedType(genClass)); >- stringBuffer.append(TEXT_1172); >+ stringBuffer.append(TEXT_1232); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(positiveOffsetCorrection); >- stringBuffer.append(TEXT_1173); >+ stringBuffer.append(TEXT_1233); > } else if (genFeature.isVolatile() || genClass.getImplementingGenModel(genFeature).isDynamicDelegation()) { >- stringBuffer.append(TEXT_1174); >+ stringBuffer.append(TEXT_1234); > stringBuffer.append(genFeature.getImportedType(genClass)); >- stringBuffer.append(TEXT_1175); >+ stringBuffer.append(TEXT_1235); > stringBuffer.append(genFeature.getSafeName()); >- stringBuffer.append(TEXT_1176); >+ stringBuffer.append(TEXT_1236); > if (genFeature.isResolveProxies()) { >- stringBuffer.append(TEXT_1177); >+ stringBuffer.append(TEXT_1237); > stringBuffer.append(genFeature.getAccessorName()); > } else { > stringBuffer.append(genFeature.getGetAccessor()); > } >- stringBuffer.append(TEXT_1178); >+ stringBuffer.append(TEXT_1238); > } >- stringBuffer.append(TEXT_1179); >+ stringBuffer.append(TEXT_1239); > stringBuffer.append(genFeature.getSafeName()); >- stringBuffer.append(TEXT_1180); >+ stringBuffer.append(TEXT_1240); > if (genFeature.isEffectiveContains()) { >- stringBuffer.append(TEXT_1181); >+ stringBuffer.append(TEXT_1241); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.InternalEObject")); >- stringBuffer.append(TEXT_1182); >+ stringBuffer.append(TEXT_1242); > stringBuffer.append(genFeature.getSafeName()); >- stringBuffer.append(TEXT_1183); >+ stringBuffer.append(TEXT_1243); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(negativeOffsetCorrection); >- stringBuffer.append(TEXT_1184); >+ stringBuffer.append(TEXT_1244); > } else { GenFeature reverseFeature = genFeature.getReverse(); GenClass targetClass = reverseFeature.getGenClass(); String reverseOffsetCorrection = targetClass.hasOffsetCorrection() ? " + " + genClass.getOffsetCorrectionField(reverseFeature) : ""; >- stringBuffer.append(TEXT_1185); >+ stringBuffer.append(TEXT_1245); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.InternalEObject")); >- stringBuffer.append(TEXT_1186); >+ stringBuffer.append(TEXT_1246); > stringBuffer.append(genFeature.getSafeName()); >- stringBuffer.append(TEXT_1187); >+ stringBuffer.append(TEXT_1247); > stringBuffer.append(targetClass.getQualifiedFeatureID(reverseFeature)); > stringBuffer.append(reverseOffsetCorrection); >- stringBuffer.append(TEXT_1188); >+ stringBuffer.append(TEXT_1248); > stringBuffer.append(targetClass.getRawImportedInterfaceName()); >- stringBuffer.append(TEXT_1189); >+ stringBuffer.append(TEXT_1249); > } >- stringBuffer.append(TEXT_1190); >+ stringBuffer.append(TEXT_1250); > stringBuffer.append(genFeature.getAccessorName()); >- stringBuffer.append(TEXT_1191); >+ stringBuffer.append(TEXT_1251); > stringBuffer.append(genFeature.getImportedType(genClass)); >- stringBuffer.append(TEXT_1192); >+ stringBuffer.append(TEXT_1252); > } > } >- stringBuffer.append(TEXT_1193); >+ stringBuffer.append(TEXT_1253); > if (genModel.isMinimalReflectiveMethods()) { >- stringBuffer.append(TEXT_1194); >+ stringBuffer.append(TEXT_1254); > } else { >- stringBuffer.append(TEXT_1195); >+ stringBuffer.append(TEXT_1255); > } >- stringBuffer.append(TEXT_1196); >+ stringBuffer.append(TEXT_1256); > } > if (isImplementation && !genModel.isReflectiveDelegation() && genClass.implementsAny(genClass.getEInverseRemoveGenFeatures())) { >- stringBuffer.append(TEXT_1197); >+ stringBuffer.append(TEXT_1257); > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1198); >+ stringBuffer.append(TEXT_1258); > } >- stringBuffer.append(TEXT_1199); >+ stringBuffer.append(TEXT_1259); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.notify.NotificationChain")); >- stringBuffer.append(TEXT_1200); >+ stringBuffer.append(TEXT_1260); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.InternalEObject")); >- stringBuffer.append(TEXT_1201); >+ stringBuffer.append(TEXT_1261); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.notify.NotificationChain")); >- stringBuffer.append(TEXT_1202); >+ stringBuffer.append(TEXT_1262); > stringBuffer.append(negativeOffsetCorrection); >- stringBuffer.append(TEXT_1203); >+ stringBuffer.append(TEXT_1263); > for (GenFeature genFeature : genClass.getEInverseRemoveGenFeatures()) { >- stringBuffer.append(TEXT_1204); >+ stringBuffer.append(TEXT_1264); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); >- stringBuffer.append(TEXT_1205); >+ stringBuffer.append(TEXT_1265); > if (genFeature.isListType()) { > if (genFeature.isMapType() && genFeature.isEffectiveSuppressEMFTypes()) { >- stringBuffer.append(TEXT_1206); >+ stringBuffer.append(TEXT_1266); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.InternalEList")); > stringBuffer.append(singleWildcard); >- stringBuffer.append(TEXT_1207); >+ stringBuffer.append(TEXT_1267); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.EMap")); >- stringBuffer.append(TEXT_1208); >+ stringBuffer.append(TEXT_1268); > stringBuffer.append(genFeature.getImportedMapTemplateArguments(genClass)); >- stringBuffer.append(TEXT_1209); >+ stringBuffer.append(TEXT_1269); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1210); >+ stringBuffer.append(TEXT_1270); > } else if (genFeature.isWrappedFeatureMapType()) { >- stringBuffer.append(TEXT_1211); >+ stringBuffer.append(TEXT_1271); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.InternalEList")); > stringBuffer.append(singleWildcard); >- stringBuffer.append(TEXT_1212); >+ stringBuffer.append(TEXT_1272); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.FeatureMap")); >- stringBuffer.append(TEXT_1213); >+ stringBuffer.append(TEXT_1273); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1214); >+ stringBuffer.append(TEXT_1274); > } else { >- stringBuffer.append(TEXT_1215); >+ stringBuffer.append(TEXT_1275); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.InternalEList")); > stringBuffer.append(singleWildcard); >- stringBuffer.append(TEXT_1216); >+ stringBuffer.append(TEXT_1276); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1217); >+ stringBuffer.append(TEXT_1277); > } > } else if (genFeature.isContainer() && !genFeature.isBasicSet()) { >- stringBuffer.append(TEXT_1218); >+ stringBuffer.append(TEXT_1278); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(positiveOffsetCorrection); >- stringBuffer.append(TEXT_1219); >+ stringBuffer.append(TEXT_1279); > } else if (genFeature.isUnsettable()) { >- stringBuffer.append(TEXT_1220); >+ stringBuffer.append(TEXT_1280); > stringBuffer.append(genFeature.getAccessorName()); >- stringBuffer.append(TEXT_1221); >+ stringBuffer.append(TEXT_1281); > } else { >- stringBuffer.append(TEXT_1222); >+ stringBuffer.append(TEXT_1282); > stringBuffer.append(genFeature.getAccessorName()); >- stringBuffer.append(TEXT_1223); >+ stringBuffer.append(TEXT_1283); > } > } >- stringBuffer.append(TEXT_1224); >+ stringBuffer.append(TEXT_1284); > if (genModel.isMinimalReflectiveMethods()) { >- stringBuffer.append(TEXT_1225); >+ stringBuffer.append(TEXT_1285); > } else { >- stringBuffer.append(TEXT_1226); >+ stringBuffer.append(TEXT_1286); > } >- stringBuffer.append(TEXT_1227); >+ stringBuffer.append(TEXT_1287); > } > if (isImplementation && !genModel.isReflectiveDelegation() && genClass.implementsAny(genClass.getEBasicRemoveFromContainerGenFeatures())) { >- stringBuffer.append(TEXT_1228); >+ stringBuffer.append(TEXT_1288); > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1229); >+ stringBuffer.append(TEXT_1289); > } >- stringBuffer.append(TEXT_1230); >+ stringBuffer.append(TEXT_1290); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.notify.NotificationChain")); >- stringBuffer.append(TEXT_1231); >+ stringBuffer.append(TEXT_1291); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.notify.NotificationChain")); >- stringBuffer.append(TEXT_1232); >+ stringBuffer.append(TEXT_1292); > stringBuffer.append(negativeOffsetCorrection); >- stringBuffer.append(TEXT_1233); >+ stringBuffer.append(TEXT_1293); > for (GenFeature genFeature : genClass.getEBasicRemoveFromContainerGenFeatures()) { > GenFeature reverseFeature = genFeature.getReverse(); GenClass targetClass = reverseFeature.getGenClass(); String reverseOffsetCorrection = targetClass.hasOffsetCorrection() ? " + " + genClass.getOffsetCorrectionField(reverseFeature) : ""; >- stringBuffer.append(TEXT_1234); >+ stringBuffer.append(TEXT_1294); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); >- stringBuffer.append(TEXT_1235); >+ stringBuffer.append(TEXT_1295); > stringBuffer.append(targetClass.getQualifiedFeatureID(reverseFeature)); > stringBuffer.append(reverseOffsetCorrection); >- stringBuffer.append(TEXT_1236); >+ stringBuffer.append(TEXT_1296); > stringBuffer.append(targetClass.getRawImportedInterfaceName()); >- stringBuffer.append(TEXT_1237); >+ stringBuffer.append(TEXT_1297); > } >- stringBuffer.append(TEXT_1238); >+ stringBuffer.append(TEXT_1298); > if (genModel.isMinimalReflectiveMethods()) { >- stringBuffer.append(TEXT_1239); >+ stringBuffer.append(TEXT_1299); > } else { >- stringBuffer.append(TEXT_1240); >+ stringBuffer.append(TEXT_1300); > } >- stringBuffer.append(TEXT_1241); >+ stringBuffer.append(TEXT_1301); > } > if (isImplementation && !genModel.isReflectiveDelegation() && genClass.implementsAny(genClass.getEGetGenFeatures())) { >- stringBuffer.append(TEXT_1242); >+ stringBuffer.append(TEXT_1302); > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1243); >+ stringBuffer.append(TEXT_1303); > } >- stringBuffer.append(TEXT_1244); >+ stringBuffer.append(TEXT_1304); > stringBuffer.append(negativeOffsetCorrection); >- stringBuffer.append(TEXT_1245); >+ stringBuffer.append(TEXT_1305); > for (GenFeature genFeature : genClass.getEGetGenFeatures()) { >- stringBuffer.append(TEXT_1246); >+ stringBuffer.append(TEXT_1306); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); >- stringBuffer.append(TEXT_1247); >+ stringBuffer.append(TEXT_1307); > if (genFeature.isPrimitiveType()) { > if (isJDK50) { >- stringBuffer.append(TEXT_1248); >+ stringBuffer.append(TEXT_1308); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1249); >+ stringBuffer.append(TEXT_1309); > } else if (genFeature.isBooleanType()) { >- stringBuffer.append(TEXT_1250); >+ stringBuffer.append(TEXT_1310); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1251); >+ stringBuffer.append(TEXT_1311); > } else { >- stringBuffer.append(TEXT_1252); >+ stringBuffer.append(TEXT_1312); > stringBuffer.append(genFeature.getObjectType(genClass)); >- stringBuffer.append(TEXT_1253); >+ stringBuffer.append(TEXT_1313); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1254); >+ stringBuffer.append(TEXT_1314); > } > } else if (genFeature.isResolveProxies() && !genFeature.isListType()) { >- stringBuffer.append(TEXT_1255); >+ stringBuffer.append(TEXT_1315); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1256); >+ stringBuffer.append(TEXT_1316); > stringBuffer.append(genFeature.getAccessorName()); >- stringBuffer.append(TEXT_1257); >+ stringBuffer.append(TEXT_1317); > } else if (genFeature.isMapType()) { > if (genFeature.isEffectiveSuppressEMFTypes()) { >- stringBuffer.append(TEXT_1258); >+ stringBuffer.append(TEXT_1318); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.EMap")); >- stringBuffer.append(TEXT_1259); >+ stringBuffer.append(TEXT_1319); > stringBuffer.append(genFeature.getImportedMapTemplateArguments(genClass)); >- stringBuffer.append(TEXT_1260); >+ stringBuffer.append(TEXT_1320); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1261); >+ stringBuffer.append(TEXT_1321); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1262); >+ stringBuffer.append(TEXT_1322); > } else { >- stringBuffer.append(TEXT_1263); >+ stringBuffer.append(TEXT_1323); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1264); >+ stringBuffer.append(TEXT_1324); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1265); >+ stringBuffer.append(TEXT_1325); > } > } else if (genFeature.isWrappedFeatureMapType()) { >- stringBuffer.append(TEXT_1266); >+ stringBuffer.append(TEXT_1326); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.FeatureMap")); >- stringBuffer.append(TEXT_1267); >+ stringBuffer.append(TEXT_1327); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1268); >+ stringBuffer.append(TEXT_1328); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1269); >+ stringBuffer.append(TEXT_1329); > } else if (genFeature.isFeatureMapType()) { >- stringBuffer.append(TEXT_1270); >+ stringBuffer.append(TEXT_1330); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1271); >+ stringBuffer.append(TEXT_1331); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.FeatureMap")); >- stringBuffer.append(TEXT_1272); >+ stringBuffer.append(TEXT_1332); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1273); >+ stringBuffer.append(TEXT_1333); > } else { >- stringBuffer.append(TEXT_1274); >+ stringBuffer.append(TEXT_1334); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1275); >+ stringBuffer.append(TEXT_1335); > } > } >- stringBuffer.append(TEXT_1276); >+ stringBuffer.append(TEXT_1336); > if (genModel.isMinimalReflectiveMethods()) { >- stringBuffer.append(TEXT_1277); >+ stringBuffer.append(TEXT_1337); > } else { >- stringBuffer.append(TEXT_1278); >+ stringBuffer.append(TEXT_1338); > } >- stringBuffer.append(TEXT_1279); >+ stringBuffer.append(TEXT_1339); > } > if (isImplementation && !genModel.isReflectiveDelegation() && genClass.implementsAny(genClass.getESetGenFeatures())) { >- stringBuffer.append(TEXT_1280); >+ stringBuffer.append(TEXT_1340); > if (genModel.useGenerics()) { > for (GenFeature genFeature : genClass.getESetGenFeatures()) { > if (genFeature.isUncheckedCast(genClass) && !genFeature.isFeatureMapType() && !genFeature.isMapType()) { >- stringBuffer.append(TEXT_1281); >+ stringBuffer.append(TEXT_1341); > break; } > } > } > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1282); >+ stringBuffer.append(TEXT_1342); > } >- stringBuffer.append(TEXT_1283); >+ stringBuffer.append(TEXT_1343); > stringBuffer.append(negativeOffsetCorrection); >- stringBuffer.append(TEXT_1284); >+ stringBuffer.append(TEXT_1344); > for (GenFeature genFeature : genClass.getESetGenFeatures()) { >- stringBuffer.append(TEXT_1285); >+ stringBuffer.append(TEXT_1345); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); >- stringBuffer.append(TEXT_1286); >+ stringBuffer.append(TEXT_1346); > if (genFeature.isListType()) { > if (genFeature.isWrappedFeatureMapType()) { >- stringBuffer.append(TEXT_1287); >+ stringBuffer.append(TEXT_1347); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.FeatureMap")); >- stringBuffer.append(TEXT_1288); >+ stringBuffer.append(TEXT_1348); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.FeatureMap")); >- stringBuffer.append(TEXT_1289); >+ stringBuffer.append(TEXT_1349); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1290); >+ stringBuffer.append(TEXT_1350); > } else if (genFeature.isFeatureMapType()) { >- stringBuffer.append(TEXT_1291); >+ stringBuffer.append(TEXT_1351); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.FeatureMap")); >- stringBuffer.append(TEXT_1292); >+ stringBuffer.append(TEXT_1352); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1293); >+ stringBuffer.append(TEXT_1353); > } else if (genFeature.isMapType()) { > if (genFeature.isEffectiveSuppressEMFTypes()) { >- stringBuffer.append(TEXT_1294); >+ stringBuffer.append(TEXT_1354); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.EStructuralFeature")); >- stringBuffer.append(TEXT_1295); >+ stringBuffer.append(TEXT_1355); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.EMap")); >- stringBuffer.append(TEXT_1296); >+ stringBuffer.append(TEXT_1356); > stringBuffer.append(genFeature.getImportedMapTemplateArguments(genClass)); >- stringBuffer.append(TEXT_1297); >+ stringBuffer.append(TEXT_1357); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1298); >+ stringBuffer.append(TEXT_1358); > } else { >- stringBuffer.append(TEXT_1299); >+ stringBuffer.append(TEXT_1359); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.EStructuralFeature")); >- stringBuffer.append(TEXT_1300); >+ stringBuffer.append(TEXT_1360); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1301); >+ stringBuffer.append(TEXT_1361); > } > } else { >- stringBuffer.append(TEXT_1302); >+ stringBuffer.append(TEXT_1362); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1303); >+ stringBuffer.append(TEXT_1363); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1304); >+ stringBuffer.append(TEXT_1364); > stringBuffer.append(genModel.getImportedName("java.util.Collection")); > if (isJDK50) { >- stringBuffer.append(TEXT_1305); >+ stringBuffer.append(TEXT_1365); > stringBuffer.append(genFeature.getListItemType(genClass)); >- stringBuffer.append(TEXT_1306); >+ stringBuffer.append(TEXT_1366); > } >- stringBuffer.append(TEXT_1307); >+ stringBuffer.append(TEXT_1367); > } > } else if (!isJDK50 && genFeature.isPrimitiveType()) { >- stringBuffer.append(TEXT_1308); >+ stringBuffer.append(TEXT_1368); > stringBuffer.append(genFeature.getAccessorName()); >- stringBuffer.append(TEXT_1309); >+ stringBuffer.append(TEXT_1369); > stringBuffer.append(genFeature.getObjectType(genClass)); >- stringBuffer.append(TEXT_1310); >+ stringBuffer.append(TEXT_1370); > stringBuffer.append(genFeature.getPrimitiveValueFunction()); >- stringBuffer.append(TEXT_1311); >+ stringBuffer.append(TEXT_1371); > } else { >- stringBuffer.append(TEXT_1312); >+ stringBuffer.append(TEXT_1372); > stringBuffer.append(genFeature.getAccessorName()); >- stringBuffer.append(TEXT_1313); >+ stringBuffer.append(TEXT_1373); > if (genFeature.getTypeGenDataType() == null || !genFeature.getTypeGenDataType().isObjectType() || !genFeature.getRawType().equals(genFeature.getType(genClass))) { >- stringBuffer.append(TEXT_1314); >+ stringBuffer.append(TEXT_1374); > stringBuffer.append(genFeature.getObjectType(genClass)); >- stringBuffer.append(TEXT_1315); >+ stringBuffer.append(TEXT_1375); > } >- stringBuffer.append(TEXT_1316); >+ stringBuffer.append(TEXT_1376); > } >- stringBuffer.append(TEXT_1317); >+ stringBuffer.append(TEXT_1377); > } >- stringBuffer.append(TEXT_1318); >+ stringBuffer.append(TEXT_1378); > if (genModel.isMinimalReflectiveMethods()) { >- stringBuffer.append(TEXT_1319); >+ stringBuffer.append(TEXT_1379); > } else { >- stringBuffer.append(TEXT_1320); >+ stringBuffer.append(TEXT_1380); > } >- stringBuffer.append(TEXT_1321); >+ stringBuffer.append(TEXT_1381); > } > if (isImplementation && !genModel.isReflectiveDelegation() && genClass.implementsAny(genClass.getEUnsetGenFeatures())) { >- stringBuffer.append(TEXT_1322); >+ stringBuffer.append(TEXT_1382); > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1323); >+ stringBuffer.append(TEXT_1383); > } >- stringBuffer.append(TEXT_1324); >+ stringBuffer.append(TEXT_1384); > stringBuffer.append(negativeOffsetCorrection); >- stringBuffer.append(TEXT_1325); >+ stringBuffer.append(TEXT_1385); > for (GenFeature genFeature : genClass.getEUnsetGenFeatures()) { >- stringBuffer.append(TEXT_1326); >+ stringBuffer.append(TEXT_1386); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); >- stringBuffer.append(TEXT_1327); >+ stringBuffer.append(TEXT_1387); > if (genFeature.isListType() && !genFeature.isUnsettable()) { > if (genFeature.isWrappedFeatureMapType()) { >- stringBuffer.append(TEXT_1328); >+ stringBuffer.append(TEXT_1388); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.FeatureMap")); >- stringBuffer.append(TEXT_1329); >+ stringBuffer.append(TEXT_1389); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1330); >+ stringBuffer.append(TEXT_1390); > } else { >- stringBuffer.append(TEXT_1331); >+ stringBuffer.append(TEXT_1391); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1332); >+ stringBuffer.append(TEXT_1392); > } > } else if (genFeature.isUnsettable()) { >- stringBuffer.append(TEXT_1333); >+ stringBuffer.append(TEXT_1393); > stringBuffer.append(genFeature.getAccessorName()); >- stringBuffer.append(TEXT_1334); >+ stringBuffer.append(TEXT_1394); > } else if (!genFeature.hasEDefault()) { >- stringBuffer.append(TEXT_1335); >+ stringBuffer.append(TEXT_1395); > stringBuffer.append(genFeature.getAccessorName()); >- stringBuffer.append(TEXT_1336); >+ stringBuffer.append(TEXT_1396); > stringBuffer.append(genFeature.getImportedType(genClass)); >- stringBuffer.append(TEXT_1337); >+ stringBuffer.append(TEXT_1397); > } else { >- stringBuffer.append(TEXT_1338); >+ stringBuffer.append(TEXT_1398); > stringBuffer.append(genFeature.getAccessorName()); >- stringBuffer.append(TEXT_1339); >+ stringBuffer.append(TEXT_1399); > stringBuffer.append(genFeature.getEDefault()); >- stringBuffer.append(TEXT_1340); >+ stringBuffer.append(TEXT_1400); > } >- stringBuffer.append(TEXT_1341); >+ stringBuffer.append(TEXT_1401); > } >- stringBuffer.append(TEXT_1342); >+ stringBuffer.append(TEXT_1402); > if (genModel.isMinimalReflectiveMethods()) { >- stringBuffer.append(TEXT_1343); >+ stringBuffer.append(TEXT_1403); > } else { >- stringBuffer.append(TEXT_1344); >+ stringBuffer.append(TEXT_1404); > } >- stringBuffer.append(TEXT_1345); >+ stringBuffer.append(TEXT_1405); > //Class/eUnset.override.javajetinc > } > if (isImplementation && !genModel.isReflectiveDelegation() && genClass.implementsAny(genClass.getEIsSetGenFeatures())) { >- stringBuffer.append(TEXT_1346); >+ stringBuffer.append(TEXT_1406); > if (genModel.useGenerics()) { > for (GenFeature genFeature : genClass.getEIsSetGenFeatures()) { > if (genFeature.isListType() && !genFeature.isUnsettable() && !genFeature.isWrappedFeatureMapType() && !genClass.isField(genFeature) && genFeature.isField() && genClass.getImplementingGenModel(genFeature).isVirtualDelegation()) { >- stringBuffer.append(TEXT_1347); >+ stringBuffer.append(TEXT_1407); > break; } > } > } > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1348); >+ stringBuffer.append(TEXT_1408); > } >- stringBuffer.append(TEXT_1349); >+ stringBuffer.append(TEXT_1409); > stringBuffer.append(negativeOffsetCorrection); >- stringBuffer.append(TEXT_1350); >+ stringBuffer.append(TEXT_1410); > for (GenFeature genFeature : genClass.getEIsSetGenFeatures()) { String safeNameAccessor = genFeature.getSafeName(); if ("featureID".equals(safeNameAccessor)) { safeNameAccessor = "this." + safeNameAccessor; } >- stringBuffer.append(TEXT_1351); >+ stringBuffer.append(TEXT_1411); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); >- stringBuffer.append(TEXT_1352); >+ stringBuffer.append(TEXT_1412); > if (genFeature.isListType() && !genFeature.isUnsettable()) { > if (genFeature.isWrappedFeatureMapType()) { > if (genFeature.isVolatile()) { >- stringBuffer.append(TEXT_1353); >+ stringBuffer.append(TEXT_1413); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.util.FeatureMap")); >- stringBuffer.append(TEXT_1354); >+ stringBuffer.append(TEXT_1414); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1355); >+ stringBuffer.append(TEXT_1415); > } else { >- stringBuffer.append(TEXT_1356); >+ stringBuffer.append(TEXT_1416); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1357); >+ stringBuffer.append(TEXT_1417); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1358); >+ stringBuffer.append(TEXT_1418); > } > } else { > if (genClass.isField(genFeature)) { >- stringBuffer.append(TEXT_1359); >+ stringBuffer.append(TEXT_1419); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1360); >+ stringBuffer.append(TEXT_1420); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1361); >+ stringBuffer.append(TEXT_1421); > } else { > if (genFeature.isField() && genClass.getImplementingGenModel(genFeature).isVirtualDelegation()) { >- stringBuffer.append(TEXT_1362); >+ stringBuffer.append(TEXT_1422); > stringBuffer.append(genFeature.getImportedType(genClass)); >- stringBuffer.append(TEXT_1363); >+ stringBuffer.append(TEXT_1423); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1364); >+ stringBuffer.append(TEXT_1424); > stringBuffer.append(genFeature.getImportedType(genClass)); >- stringBuffer.append(TEXT_1365); >+ stringBuffer.append(TEXT_1425); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(positiveOffsetCorrection); >- stringBuffer.append(TEXT_1366); >+ stringBuffer.append(TEXT_1426); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1367); >+ stringBuffer.append(TEXT_1427); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1368); >+ stringBuffer.append(TEXT_1428); > } else { >- stringBuffer.append(TEXT_1369); >+ stringBuffer.append(TEXT_1429); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1370); >+ stringBuffer.append(TEXT_1430); > } > } > } > } else if (genFeature.isUnsettable()) { >- stringBuffer.append(TEXT_1371); >+ stringBuffer.append(TEXT_1431); > stringBuffer.append(genFeature.getAccessorName()); >- stringBuffer.append(TEXT_1372); >+ stringBuffer.append(TEXT_1432); > } else if (genFeature.isResolveProxies()) { > if (genClass.isField(genFeature)) { >- stringBuffer.append(TEXT_1373); >+ stringBuffer.append(TEXT_1433); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1374); >+ stringBuffer.append(TEXT_1434); > } else { > if (genFeature.isField() && genClass.getImplementingGenModel(genFeature).isVirtualDelegation()) { >- stringBuffer.append(TEXT_1375); >+ stringBuffer.append(TEXT_1435); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(positiveOffsetCorrection); >- stringBuffer.append(TEXT_1376); >+ stringBuffer.append(TEXT_1436); > } else { >- stringBuffer.append(TEXT_1377); >+ stringBuffer.append(TEXT_1437); > stringBuffer.append(genFeature.getAccessorName()); >- stringBuffer.append(TEXT_1378); >+ stringBuffer.append(TEXT_1438); > } > } > } else if (!genFeature.hasEDefault()) { > if (genClass.isField(genFeature)) { >- stringBuffer.append(TEXT_1379); >+ stringBuffer.append(TEXT_1439); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1380); >+ stringBuffer.append(TEXT_1440); > } else { > if (genFeature.isField() && genClass.getImplementingGenModel(genFeature).isVirtualDelegation()) { >- stringBuffer.append(TEXT_1381); >+ stringBuffer.append(TEXT_1441); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(positiveOffsetCorrection); >- stringBuffer.append(TEXT_1382); >+ stringBuffer.append(TEXT_1442); > } else { >- stringBuffer.append(TEXT_1383); >+ stringBuffer.append(TEXT_1443); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1384); >+ stringBuffer.append(TEXT_1444); > } > } > } else if (genFeature.isPrimitiveType() || genFeature.isEnumType()) { > if (genClass.isField(genFeature)) { > if (genClass.isFlag(genFeature)) { > if (genFeature.isBooleanType()) { >- stringBuffer.append(TEXT_1385); >+ stringBuffer.append(TEXT_1445); > stringBuffer.append(genClass.getFlagsField(genFeature)); >- stringBuffer.append(TEXT_1386); >+ stringBuffer.append(TEXT_1446); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1387); >+ stringBuffer.append(TEXT_1447); > stringBuffer.append(genFeature.getEDefault()); >- stringBuffer.append(TEXT_1388); >+ stringBuffer.append(TEXT_1448); > } else { >- stringBuffer.append(TEXT_1389); >+ stringBuffer.append(TEXT_1449); > stringBuffer.append(genClass.getFlagsField(genFeature)); >- stringBuffer.append(TEXT_1390); >+ stringBuffer.append(TEXT_1450); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1391); >+ stringBuffer.append(TEXT_1451); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1392); >+ stringBuffer.append(TEXT_1452); > } > } else { >- stringBuffer.append(TEXT_1393); >+ stringBuffer.append(TEXT_1453); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1394); >+ stringBuffer.append(TEXT_1454); > stringBuffer.append(genFeature.getEDefault()); >- stringBuffer.append(TEXT_1395); >+ stringBuffer.append(TEXT_1455); > } > } else { > if (genFeature.isEnumType() && genFeature.isField() && genClass.getImplementingGenModel(genFeature).isVirtualDelegation()) { >- stringBuffer.append(TEXT_1396); >+ stringBuffer.append(TEXT_1456); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(positiveOffsetCorrection); >- stringBuffer.append(TEXT_1397); >+ stringBuffer.append(TEXT_1457); > stringBuffer.append(genFeature.getEDefault()); >- stringBuffer.append(TEXT_1398); >+ stringBuffer.append(TEXT_1458); > stringBuffer.append(genFeature.getEDefault()); >- stringBuffer.append(TEXT_1399); >+ stringBuffer.append(TEXT_1459); > } else { >- stringBuffer.append(TEXT_1400); >+ stringBuffer.append(TEXT_1460); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1401); >+ stringBuffer.append(TEXT_1461); > stringBuffer.append(genFeature.getEDefault()); >- stringBuffer.append(TEXT_1402); >+ stringBuffer.append(TEXT_1462); > } > } > } else {//datatype > if (genClass.isField(genFeature)) { >- stringBuffer.append(TEXT_1403); >+ stringBuffer.append(TEXT_1463); > stringBuffer.append(genFeature.getEDefault()); >- stringBuffer.append(TEXT_1404); >+ stringBuffer.append(TEXT_1464); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1405); >+ stringBuffer.append(TEXT_1465); > stringBuffer.append(genFeature.getEDefault()); >- stringBuffer.append(TEXT_1406); >+ stringBuffer.append(TEXT_1466); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1407); >+ stringBuffer.append(TEXT_1467); > } else { > if (genFeature.isField() && genClass.getImplementingGenModel(genFeature).isVirtualDelegation()) { >- stringBuffer.append(TEXT_1408); >+ stringBuffer.append(TEXT_1468); > stringBuffer.append(genFeature.getImportedType(genClass)); >- stringBuffer.append(TEXT_1409); >+ stringBuffer.append(TEXT_1469); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1410); >+ stringBuffer.append(TEXT_1470); > stringBuffer.append(genFeature.getImportedType(genClass)); >- stringBuffer.append(TEXT_1411); >+ stringBuffer.append(TEXT_1471); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(positiveOffsetCorrection); >- stringBuffer.append(TEXT_1412); >+ stringBuffer.append(TEXT_1472); > stringBuffer.append(genFeature.getEDefault()); >- stringBuffer.append(TEXT_1413); >+ stringBuffer.append(TEXT_1473); > stringBuffer.append(genFeature.getEDefault()); >- stringBuffer.append(TEXT_1414); >+ stringBuffer.append(TEXT_1474); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1415); >+ stringBuffer.append(TEXT_1475); > stringBuffer.append(genFeature.getEDefault()); >- stringBuffer.append(TEXT_1416); >+ stringBuffer.append(TEXT_1476); > stringBuffer.append(safeNameAccessor); >- stringBuffer.append(TEXT_1417); >+ stringBuffer.append(TEXT_1477); > } else { >- stringBuffer.append(TEXT_1418); >+ stringBuffer.append(TEXT_1478); > stringBuffer.append(genFeature.getEDefault()); >- stringBuffer.append(TEXT_1419); >+ stringBuffer.append(TEXT_1479); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1420); >+ stringBuffer.append(TEXT_1480); > stringBuffer.append(genFeature.getEDefault()); >- stringBuffer.append(TEXT_1421); >+ stringBuffer.append(TEXT_1481); > stringBuffer.append(genFeature.getGetAccessor()); >- stringBuffer.append(TEXT_1422); >+ stringBuffer.append(TEXT_1482); > } > } > } > } >- stringBuffer.append(TEXT_1423); >+ stringBuffer.append(TEXT_1483); > if (genModel.isMinimalReflectiveMethods()) { >- stringBuffer.append(TEXT_1424); >+ stringBuffer.append(TEXT_1484); > } else { >- stringBuffer.append(TEXT_1425); >+ stringBuffer.append(TEXT_1485); > } >- stringBuffer.append(TEXT_1426); >+ stringBuffer.append(TEXT_1486); > //Class/eIsSet.override.javajetinc > } > if (isImplementation && (!genClass.getMixinGenFeatures().isEmpty() || genClass.hasOffsetCorrection() && !genClass.getGenFeatures().isEmpty())) { > if (!genClass.getMixinGenFeatures().isEmpty()) { >- stringBuffer.append(TEXT_1427); >+ stringBuffer.append(TEXT_1487); > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1428); >+ stringBuffer.append(TEXT_1488); > } >- stringBuffer.append(TEXT_1429); >+ stringBuffer.append(TEXT_1489); > stringBuffer.append(singleWildcard); >- stringBuffer.append(TEXT_1430); >+ stringBuffer.append(TEXT_1490); > for (GenClass mixinGenClass : genClass.getMixinGenClasses()) { >- stringBuffer.append(TEXT_1431); >+ stringBuffer.append(TEXT_1491); > stringBuffer.append(mixinGenClass.getRawImportedInterfaceName()); >- stringBuffer.append(TEXT_1432); >+ stringBuffer.append(TEXT_1492); > stringBuffer.append(negativeOffsetCorrection); >- stringBuffer.append(TEXT_1433); >+ stringBuffer.append(TEXT_1493); > for (GenFeature genFeature : mixinGenClass.getGenFeatures()) { >- stringBuffer.append(TEXT_1434); >+ stringBuffer.append(TEXT_1494); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); >- stringBuffer.append(TEXT_1435); >+ stringBuffer.append(TEXT_1495); > stringBuffer.append(mixinGenClass.getQualifiedFeatureID(genFeature)); >- stringBuffer.append(TEXT_1436); >+ stringBuffer.append(TEXT_1496); > } >- stringBuffer.append(TEXT_1437); >+ stringBuffer.append(TEXT_1497); > } >- stringBuffer.append(TEXT_1438); >+ stringBuffer.append(TEXT_1498); > } >- stringBuffer.append(TEXT_1439); >+ stringBuffer.append(TEXT_1499); > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1440); >+ stringBuffer.append(TEXT_1500); > } >- stringBuffer.append(TEXT_1441); >+ stringBuffer.append(TEXT_1501); > stringBuffer.append(singleWildcard); >- stringBuffer.append(TEXT_1442); >+ stringBuffer.append(TEXT_1502); > for (GenClass mixinGenClass : genClass.getMixinGenClasses()) { >- stringBuffer.append(TEXT_1443); >+ stringBuffer.append(TEXT_1503); > stringBuffer.append(mixinGenClass.getRawImportedInterfaceName()); >- stringBuffer.append(TEXT_1444); >+ stringBuffer.append(TEXT_1504); > for (GenFeature genFeature : mixinGenClass.getGenFeatures()) { >- stringBuffer.append(TEXT_1445); >+ stringBuffer.append(TEXT_1505); > stringBuffer.append(mixinGenClass.getQualifiedFeatureID(genFeature)); >- stringBuffer.append(TEXT_1446); >+ stringBuffer.append(TEXT_1506); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(positiveOffsetCorrection); >- stringBuffer.append(TEXT_1447); >+ stringBuffer.append(TEXT_1507); > } >- stringBuffer.append(TEXT_1448); >+ stringBuffer.append(TEXT_1508); > } > if (genClass.hasOffsetCorrection() && !genClass.getGenFeatures().isEmpty()) { >- stringBuffer.append(TEXT_1449); >+ stringBuffer.append(TEXT_1509); > stringBuffer.append(genClass.getRawImportedInterfaceName()); >- stringBuffer.append(TEXT_1450); >+ stringBuffer.append(TEXT_1510); > stringBuffer.append(negativeOffsetCorrection); >- stringBuffer.append(TEXT_1451); >+ stringBuffer.append(TEXT_1511); > for (GenFeature genFeature : genClass.getGenFeatures()) { >- stringBuffer.append(TEXT_1452); >+ stringBuffer.append(TEXT_1512); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); >- stringBuffer.append(TEXT_1453); >+ stringBuffer.append(TEXT_1513); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(positiveOffsetCorrection); >- stringBuffer.append(TEXT_1454); >+ stringBuffer.append(TEXT_1514); > } >- stringBuffer.append(TEXT_1455); >+ stringBuffer.append(TEXT_1515); > } >- stringBuffer.append(TEXT_1456); >+ stringBuffer.append(TEXT_1516); > } > if (isImplementation && genModel.isVirtualDelegation()) { String eVirtualValuesField = genClass.getEVirtualValuesField(); > if (eVirtualValuesField != null) { >- stringBuffer.append(TEXT_1457); >+ stringBuffer.append(TEXT_1517); > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1458); >+ stringBuffer.append(TEXT_1518); > } >- stringBuffer.append(TEXT_1459); >+ stringBuffer.append(TEXT_1519); > stringBuffer.append(eVirtualValuesField); >- stringBuffer.append(TEXT_1460); >+ stringBuffer.append(TEXT_1520); > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1461); >+ stringBuffer.append(TEXT_1521); > } >- stringBuffer.append(TEXT_1462); >+ stringBuffer.append(TEXT_1522); > stringBuffer.append(eVirtualValuesField); >- stringBuffer.append(TEXT_1463); >+ stringBuffer.append(TEXT_1523); > } > { List<String> eVirtualIndexBitFields = genClass.getEVirtualIndexBitFields(new ArrayList<String>()); > if (!eVirtualIndexBitFields.isEmpty()) { List<String> allEVirtualIndexBitFields = genClass.getAllEVirtualIndexBitFields(new ArrayList<String>()); >- stringBuffer.append(TEXT_1464); >+ stringBuffer.append(TEXT_1524); > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1465); >+ stringBuffer.append(TEXT_1525); > } >- stringBuffer.append(TEXT_1466); >+ stringBuffer.append(TEXT_1526); > for (int i = 0; i < allEVirtualIndexBitFields.size(); i++) { >- stringBuffer.append(TEXT_1467); >+ stringBuffer.append(TEXT_1527); > stringBuffer.append(i); >- stringBuffer.append(TEXT_1468); >+ stringBuffer.append(TEXT_1528); > stringBuffer.append(allEVirtualIndexBitFields.get(i)); >- stringBuffer.append(TEXT_1469); >+ stringBuffer.append(TEXT_1529); > } >- stringBuffer.append(TEXT_1470); >+ stringBuffer.append(TEXT_1530); > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1471); >+ stringBuffer.append(TEXT_1531); > } >- stringBuffer.append(TEXT_1472); >+ stringBuffer.append(TEXT_1532); > for (int i = 0; i < allEVirtualIndexBitFields.size(); i++) { >- stringBuffer.append(TEXT_1473); >+ stringBuffer.append(TEXT_1533); > stringBuffer.append(i); >- stringBuffer.append(TEXT_1474); >+ stringBuffer.append(TEXT_1534); > stringBuffer.append(allEVirtualIndexBitFields.get(i)); >- stringBuffer.append(TEXT_1475); >+ stringBuffer.append(TEXT_1535); > } >- stringBuffer.append(TEXT_1476); >+ stringBuffer.append(TEXT_1536); > } > } > } > if (!genClass.hasImplementedToStringGenOperation() && isImplementation && !genModel.isReflectiveDelegation() && !genModel.isDynamicDelegation() && !genClass.getToStringGenFeatures().isEmpty()) { >- stringBuffer.append(TEXT_1477); >+ stringBuffer.append(TEXT_1537); > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_1478); >+ stringBuffer.append(TEXT_1538); > } >- stringBuffer.append(TEXT_1479); >+ stringBuffer.append(TEXT_1539); > { boolean first = true; > for (GenFeature genFeature : genClass.getToStringGenFeatures()) { > if (first) { first = false; >- stringBuffer.append(TEXT_1480); >+ stringBuffer.append(TEXT_1540); > stringBuffer.append(genFeature.getName()); >- stringBuffer.append(TEXT_1481); >+ stringBuffer.append(TEXT_1541); > stringBuffer.append(genModel.getNonNLS()); > } else { >- stringBuffer.append(TEXT_1482); >+ stringBuffer.append(TEXT_1542); > stringBuffer.append(genFeature.getName()); >- stringBuffer.append(TEXT_1483); >+ stringBuffer.append(TEXT_1543); > stringBuffer.append(genModel.getNonNLS()); > } > if (genFeature.isUnsettable() && !genFeature.isListType()) { > if (genModel.isVirtualDelegation() && !genFeature.isPrimitiveType()) { >- stringBuffer.append(TEXT_1484); >+ stringBuffer.append(TEXT_1544); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(positiveOffsetCorrection); >- stringBuffer.append(TEXT_1485); >+ stringBuffer.append(TEXT_1545); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(positiveOffsetCorrection); >- stringBuffer.append(TEXT_1486); >+ stringBuffer.append(TEXT_1546); > stringBuffer.append(genModel.getNonNLS()); > } else { > if (genClass.isFlag(genFeature)) { > if (genFeature.isBooleanType()) { >- stringBuffer.append(TEXT_1487); >+ stringBuffer.append(TEXT_1547); > if (genClass.isESetFlag(genFeature)) { >- stringBuffer.append(TEXT_1488); >+ stringBuffer.append(TEXT_1548); > stringBuffer.append(genClass.getESetFlagsField(genFeature)); >- stringBuffer.append(TEXT_1489); >+ stringBuffer.append(TEXT_1549); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1490); >+ stringBuffer.append(TEXT_1550); > } else { > stringBuffer.append(genFeature.getUncapName()); >- stringBuffer.append(TEXT_1491); >+ stringBuffer.append(TEXT_1551); > } >- stringBuffer.append(TEXT_1492); >+ stringBuffer.append(TEXT_1552); > stringBuffer.append(genClass.getFlagsField(genFeature)); >- stringBuffer.append(TEXT_1493); >+ stringBuffer.append(TEXT_1553); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1494); >+ stringBuffer.append(TEXT_1554); > stringBuffer.append(genModel.getNonNLS()); > } else { >- stringBuffer.append(TEXT_1495); >+ stringBuffer.append(TEXT_1555); > if (genClass.isESetFlag(genFeature)) { >- stringBuffer.append(TEXT_1496); >+ stringBuffer.append(TEXT_1556); > stringBuffer.append(genClass.getESetFlagsField(genFeature)); >- stringBuffer.append(TEXT_1497); >+ stringBuffer.append(TEXT_1557); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1498); >+ stringBuffer.append(TEXT_1558); > } else { > stringBuffer.append(genFeature.getUncapName()); >- stringBuffer.append(TEXT_1499); >+ stringBuffer.append(TEXT_1559); > } >- stringBuffer.append(TEXT_1500); >+ stringBuffer.append(TEXT_1560); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1501); >+ stringBuffer.append(TEXT_1561); > stringBuffer.append(genClass.getFlagsField(genFeature)); >- stringBuffer.append(TEXT_1502); >+ stringBuffer.append(TEXT_1562); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1503); >+ stringBuffer.append(TEXT_1563); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1504); >+ stringBuffer.append(TEXT_1564); > stringBuffer.append(genModel.getNonNLS()); > } > } else { >- stringBuffer.append(TEXT_1505); >+ stringBuffer.append(TEXT_1565); > if (genClass.isESetFlag(genFeature)) { >- stringBuffer.append(TEXT_1506); >+ stringBuffer.append(TEXT_1566); > stringBuffer.append(genClass.getESetFlagsField(genFeature)); >- stringBuffer.append(TEXT_1507); >+ stringBuffer.append(TEXT_1567); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1508); >+ stringBuffer.append(TEXT_1568); > } else { > stringBuffer.append(genFeature.getUncapName()); >- stringBuffer.append(TEXT_1509); >+ stringBuffer.append(TEXT_1569); > } >- stringBuffer.append(TEXT_1510); >+ stringBuffer.append(TEXT_1570); > stringBuffer.append(genFeature.getSafeName()); >- stringBuffer.append(TEXT_1511); >+ stringBuffer.append(TEXT_1571); > stringBuffer.append(genModel.getNonNLS()); > } > } > } else { > if (genModel.isVirtualDelegation() && !genFeature.isPrimitiveType()) { >- stringBuffer.append(TEXT_1512); >+ stringBuffer.append(TEXT_1572); > stringBuffer.append(genClass.getQualifiedFeatureID(genFeature)); > stringBuffer.append(positiveOffsetCorrection); > if (!genFeature.isListType() && !genFeature.isReferenceType()){ >- stringBuffer.append(TEXT_1513); >+ stringBuffer.append(TEXT_1573); > stringBuffer.append(genFeature.getEDefault()); > } >- stringBuffer.append(TEXT_1514); >+ stringBuffer.append(TEXT_1574); > } else { > if (genClass.isFlag(genFeature)) { > if (genFeature.isBooleanType()) { >- stringBuffer.append(TEXT_1515); >+ stringBuffer.append(TEXT_1575); > stringBuffer.append(genClass.getFlagsField(genFeature)); >- stringBuffer.append(TEXT_1516); >+ stringBuffer.append(TEXT_1576); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1517); >+ stringBuffer.append(TEXT_1577); > } else { >- stringBuffer.append(TEXT_1518); >+ stringBuffer.append(TEXT_1578); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1519); >+ stringBuffer.append(TEXT_1579); > stringBuffer.append(genClass.getFlagsField(genFeature)); >- stringBuffer.append(TEXT_1520); >+ stringBuffer.append(TEXT_1580); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1521); >+ stringBuffer.append(TEXT_1581); > stringBuffer.append(genFeature.getUpperName()); >- stringBuffer.append(TEXT_1522); >+ stringBuffer.append(TEXT_1582); > } > } else { >- stringBuffer.append(TEXT_1523); >+ stringBuffer.append(TEXT_1583); > stringBuffer.append(genFeature.getSafeName()); >- stringBuffer.append(TEXT_1524); >+ stringBuffer.append(TEXT_1584); > } > } > } > } > } >- stringBuffer.append(TEXT_1525); >+ stringBuffer.append(TEXT_1585); > } > if (isImplementation && genClass.isMapEntry()) { GenFeature keyFeature = genClass.getMapEntryKeyFeature(); GenFeature valueFeature = genClass.getMapEntryValueFeature(); > String objectType = genModel.getImportedName("java.lang.Object"); > String keyType = isJDK50 ? keyFeature.getObjectType(genClass) : objectType; > String valueType = isJDK50 ? valueFeature.getObjectType(genClass) : objectType; > String eMapType = genModel.getImportedName("org.eclipse.emf.common.util.EMap") + (isJDK50 ? "<" + keyType + ", " + valueType + ">" : ""); >- stringBuffer.append(TEXT_1526); >+ stringBuffer.append(TEXT_1586); > stringBuffer.append(objectType); >- stringBuffer.append(TEXT_1527); >+ stringBuffer.append(TEXT_1587); > stringBuffer.append(keyType); >- stringBuffer.append(TEXT_1528); >+ stringBuffer.append(TEXT_1588); > if (!isJDK50 && keyFeature.isPrimitiveType()) { >- stringBuffer.append(TEXT_1529); >+ stringBuffer.append(TEXT_1589); > stringBuffer.append(keyFeature.getObjectType(genClass)); >- stringBuffer.append(TEXT_1530); >+ stringBuffer.append(TEXT_1590); > } else { >- stringBuffer.append(TEXT_1531); >+ stringBuffer.append(TEXT_1591); > } >- stringBuffer.append(TEXT_1532); >+ stringBuffer.append(TEXT_1592); > stringBuffer.append(keyType); >- stringBuffer.append(TEXT_1533); >+ stringBuffer.append(TEXT_1593); > if (keyFeature.isListType()) { >- stringBuffer.append(TEXT_1534); >+ stringBuffer.append(TEXT_1594); > if (!genModel.useGenerics()) { >- stringBuffer.append(TEXT_1535); >+ stringBuffer.append(TEXT_1595); > stringBuffer.append(genModel.getImportedName("java.util.Collection")); >- stringBuffer.append(TEXT_1536); >+ stringBuffer.append(TEXT_1596); > } >- stringBuffer.append(TEXT_1537); >+ stringBuffer.append(TEXT_1597); > } else if (isJDK50) { >- stringBuffer.append(TEXT_1538); >+ stringBuffer.append(TEXT_1598); > } else if (keyFeature.isPrimitiveType()) { >- stringBuffer.append(TEXT_1539); >+ stringBuffer.append(TEXT_1599); > stringBuffer.append(keyFeature.getObjectType(genClass)); >- stringBuffer.append(TEXT_1540); >+ stringBuffer.append(TEXT_1600); > stringBuffer.append(keyFeature.getPrimitiveValueFunction()); >- stringBuffer.append(TEXT_1541); >+ stringBuffer.append(TEXT_1601); > } else { >- stringBuffer.append(TEXT_1542); >+ stringBuffer.append(TEXT_1602); > stringBuffer.append(keyFeature.getImportedType(genClass)); >- stringBuffer.append(TEXT_1543); >+ stringBuffer.append(TEXT_1603); > } >- stringBuffer.append(TEXT_1544); >+ stringBuffer.append(TEXT_1604); > stringBuffer.append(valueType); >- stringBuffer.append(TEXT_1545); >+ stringBuffer.append(TEXT_1605); > if (!isJDK50 && valueFeature.isPrimitiveType()) { >- stringBuffer.append(TEXT_1546); >+ stringBuffer.append(TEXT_1606); > stringBuffer.append(valueFeature.getObjectType(genClass)); >- stringBuffer.append(TEXT_1547); >+ stringBuffer.append(TEXT_1607); > } else { >- stringBuffer.append(TEXT_1548); >+ stringBuffer.append(TEXT_1608); > } >- stringBuffer.append(TEXT_1549); >+ stringBuffer.append(TEXT_1609); > stringBuffer.append(valueType); >- stringBuffer.append(TEXT_1550); >+ stringBuffer.append(TEXT_1610); > stringBuffer.append(valueType); >- stringBuffer.append(TEXT_1551); >+ stringBuffer.append(TEXT_1611); > stringBuffer.append(valueType); >- stringBuffer.append(TEXT_1552); >+ stringBuffer.append(TEXT_1612); > if (valueFeature.isListType()) { >- stringBuffer.append(TEXT_1553); >+ stringBuffer.append(TEXT_1613); > if (!genModel.useGenerics()) { >- stringBuffer.append(TEXT_1554); >+ stringBuffer.append(TEXT_1614); > stringBuffer.append(genModel.getImportedName("java.util.Collection")); >- stringBuffer.append(TEXT_1555); >+ stringBuffer.append(TEXT_1615); > } >- stringBuffer.append(TEXT_1556); >+ stringBuffer.append(TEXT_1616); > } else if (isJDK50) { >- stringBuffer.append(TEXT_1557); >+ stringBuffer.append(TEXT_1617); > } else if (valueFeature.isPrimitiveType()) { >- stringBuffer.append(TEXT_1558); >+ stringBuffer.append(TEXT_1618); > stringBuffer.append(valueFeature.getObjectType(genClass)); >- stringBuffer.append(TEXT_1559); >+ stringBuffer.append(TEXT_1619); > stringBuffer.append(valueFeature.getPrimitiveValueFunction()); >- stringBuffer.append(TEXT_1560); >+ stringBuffer.append(TEXT_1620); > } else { >- stringBuffer.append(TEXT_1561); >+ stringBuffer.append(TEXT_1621); > stringBuffer.append(valueFeature.getImportedType(genClass)); >- stringBuffer.append(TEXT_1562); >+ stringBuffer.append(TEXT_1622); > } >- stringBuffer.append(TEXT_1563); >+ stringBuffer.append(TEXT_1623); > if (genModel.useGenerics()) { >- stringBuffer.append(TEXT_1564); >+ stringBuffer.append(TEXT_1624); > } >- stringBuffer.append(TEXT_1565); >+ stringBuffer.append(TEXT_1625); > stringBuffer.append(eMapType); >- stringBuffer.append(TEXT_1566); >+ stringBuffer.append(TEXT_1626); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.EObject")); >- stringBuffer.append(TEXT_1567); >+ stringBuffer.append(TEXT_1627); > stringBuffer.append(eMapType); >- stringBuffer.append(TEXT_1568); >+ stringBuffer.append(TEXT_1628); > } >- stringBuffer.append(TEXT_1569); >+ stringBuffer.append(TEXT_1629); > stringBuffer.append(isInterface ? " " + genClass.getInterfaceName() : genClass.getClassName()); > // TODO fix the space above > genModel.emitSortedImports(); >- stringBuffer.append(TEXT_1570); >+ stringBuffer.append(TEXT_1630); > return stringBuffer.toString(); > } > } >Index: src/org/eclipse/emf/codegen/ecore/templates/model/ValidatorClass.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore/src/org/eclipse/emf/codegen/ecore/templates/model/ValidatorClass.java,v >retrieving revision 1.36 >diff -u -r1.36 ValidatorClass.java >--- src/org/eclipse/emf/codegen/ecore/templates/model/ValidatorClass.java 11 Aug 2009 16:53:38 -0000 1.36 >+++ src/org/eclipse/emf/codegen/ecore/templates/model/ValidatorClass.java 8 Sep 2009 17:31:17 -0000 >@@ -157,424 +157,511 @@ > protected final String TEXT_139 = "("; > protected final String TEXT_140 = ")"; > protected final String TEXT_141 = NL + "\t\t\t });" + NL; >- protected final String TEXT_142 = NL + "\t/**" + NL + "\t * Validates the "; >+ protected final String TEXT_142 = NL + "\t/**" + NL + "\t * The cached validation expression for the "; > protected final String TEXT_143 = " constraint of '<em>"; >- protected final String TEXT_144 = "</em>'." + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic boolean validate"; >- protected final String TEXT_145 = "_"; >- protected final String TEXT_146 = "("; >- protected final String TEXT_147 = " "; >- protected final String TEXT_148 = ", DiagnosticChain "; >- protected final String TEXT_149 = ", "; >- protected final String TEXT_150 = " "; >- protected final String TEXT_151 = ")" + NL + "\t{"; >- protected final String TEXT_152 = NL + "\t\tboolean "; >- protected final String TEXT_153 = " = true;" + NL + "\t\tfor ("; >- protected final String TEXT_154 = " i = "; >- protected final String TEXT_155 = ".iterator(); i.hasNext() && (result || diagnostics != null); )" + NL + "\t\t{" + NL + "\t\t\tObject item = i.next();"; >- protected final String TEXT_156 = NL + "\t\t\tif ("; >- protected final String TEXT_157 = ".isInstance(item))" + NL + "\t\t\t{" + NL + "\t\t\t\tresult &= "; >- protected final String TEXT_158 = "validate"; >- protected final String TEXT_159 = "("; >- protected final String TEXT_160 = "("; >- protected final String TEXT_161 = "("; >- protected final String TEXT_162 = ")"; >- protected final String TEXT_163 = ")."; >- protected final String TEXT_164 = "()"; >- protected final String TEXT_165 = ", "; >- protected final String TEXT_166 = ", "; >- protected final String TEXT_167 = ");" + NL + "\t\t\t}" + NL + "\t\t\telse"; >- protected final String TEXT_168 = NL + "\t\t\tif (!"; >- protected final String TEXT_169 = ".isInstance(item))"; >- protected final String TEXT_170 = NL + "\t\t\t{" + NL + "\t\t\t\tresult = false;" + NL + "\t\t\t\treportDataValueTypeViolation("; >- protected final String TEXT_171 = ", item, "; >- protected final String TEXT_172 = ", "; >- protected final String TEXT_173 = ");" + NL + "\t\t\t}" + NL + "\t\t}" + NL + "\t\treturn result;"; >- protected final String TEXT_174 = NL + "\t\tif (diagnostics != null)" + NL + "\t\t{" + NL + "\t\t\t"; >- protected final String TEXT_175 = " tempDiagnostics = new BasicDiagnostic();"; >- protected final String TEXT_176 = NL + "\t\t\tif ("; >- protected final String TEXT_177 = "validate"; >- protected final String TEXT_178 = "("; >- protected final String TEXT_179 = ", tempDiagnostics, "; >- protected final String TEXT_180 = ")) return true;"; >- protected final String TEXT_181 = NL + "\t\t\tif ("; >- protected final String TEXT_182 = ".isInstance("; >- protected final String TEXT_183 = "))" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >- protected final String TEXT_184 = "if ("; >+ protected final String TEXT_144 = "</em>'." + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tprotected static final "; >+ protected final String TEXT_145 = " "; >+ protected final String TEXT_146 = "__"; >+ protected final String TEXT_147 = "__EXP = \""; >+ protected final String TEXT_148 = "\";"; >+ protected final String TEXT_149 = NL; >+ protected final String TEXT_150 = NL + "\t/**" + NL + "\t * Validates the "; >+ protected final String TEXT_151 = " constraint of '<em>"; >+ protected final String TEXT_152 = "</em>'." + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */" + NL + "\tpublic boolean validate"; >+ protected final String TEXT_153 = "_"; >+ protected final String TEXT_154 = "("; >+ protected final String TEXT_155 = " "; >+ protected final String TEXT_156 = ", DiagnosticChain "; >+ protected final String TEXT_157 = ", "; >+ protected final String TEXT_158 = " "; >+ protected final String TEXT_159 = ")" + NL + "\t{"; >+ protected final String TEXT_160 = NL + "\t\tboolean "; >+ protected final String TEXT_161 = " = true;" + NL + "\t\tfor ("; >+ protected final String TEXT_162 = " i = "; >+ protected final String TEXT_163 = ".iterator(); i.hasNext() && (result || diagnostics != null); )" + NL + "\t\t{" + NL + "\t\t\tObject item = i.next();"; >+ protected final String TEXT_164 = NL + "\t\t\tif ("; >+ protected final String TEXT_165 = ".isInstance(item))" + NL + "\t\t\t{" + NL + "\t\t\t\tresult &= "; >+ protected final String TEXT_166 = "validate"; >+ protected final String TEXT_167 = "("; >+ protected final String TEXT_168 = "("; >+ protected final String TEXT_169 = "("; >+ protected final String TEXT_170 = ")"; >+ protected final String TEXT_171 = ")."; >+ protected final String TEXT_172 = "()"; >+ protected final String TEXT_173 = ", "; >+ protected final String TEXT_174 = ", "; >+ protected final String TEXT_175 = ");" + NL + "\t\t\t}" + NL + "\t\t\telse"; >+ protected final String TEXT_176 = NL + "\t\t\tif (!"; >+ protected final String TEXT_177 = ".isInstance(item))"; >+ protected final String TEXT_178 = NL + "\t\t\t{" + NL + "\t\t\t\tresult = false;" + NL + "\t\t\t\treportDataValueTypeViolation("; >+ protected final String TEXT_179 = ", item, "; >+ protected final String TEXT_180 = ", "; >+ protected final String TEXT_181 = ");" + NL + "\t\t\t}" + NL + "\t\t}" + NL + "\t\treturn result;"; >+ protected final String TEXT_182 = NL + "\t\tif (diagnostics != null)" + NL + "\t\t{" + NL + "\t\t\t"; >+ protected final String TEXT_183 = " tempDiagnostics = new BasicDiagnostic();"; >+ protected final String TEXT_184 = NL + "\t\t\tif ("; > protected final String TEXT_185 = "validate"; > protected final String TEXT_186 = "("; >- protected final String TEXT_187 = "("; >- protected final String TEXT_188 = "("; >- protected final String TEXT_189 = ")"; >- protected final String TEXT_190 = ")."; >- protected final String TEXT_191 = "()"; >- protected final String TEXT_192 = ", tempDiagnostics, "; >- protected final String TEXT_193 = ")) "; >- protected final String TEXT_194 = "return true;" + NL + "\t\t\t}"; >- protected final String TEXT_195 = NL + "\t\t\tfor ("; >- protected final String TEXT_196 = " diagnostic : tempDiagnostics.getChildren())" + NL + "\t\t\t{" + NL + "\t\t\t\tdiagnostics.add(diagnostic);" + NL + "\t\t\t}"; >- protected final String TEXT_197 = NL + "\t\t\t"; >- protected final String TEXT_198 = " children = tempDiagnostics.getChildren();" + NL + "\t\t\tfor (int i = 0; i < children.size(); i++)" + NL + "\t\t\t{" + NL + "\t\t\t\tdiagnostics.add(("; >- protected final String TEXT_199 = ")children.get(i));" + NL + "\t\t\t}"; >- protected final String TEXT_200 = NL + "\t\t}" + NL + "\t\telse" + NL + "\t\t{"; >- protected final String TEXT_201 = NL + "\t\t\tif ("; >- protected final String TEXT_202 = "validate"; >- protected final String TEXT_203 = "("; >- protected final String TEXT_204 = ", null, "; >- protected final String TEXT_205 = ")) return true;"; >- protected final String TEXT_206 = NL + "\t\t\tif ("; >- protected final String TEXT_207 = ".isInstance("; >- protected final String TEXT_208 = "))" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >- protected final String TEXT_209 = "if ("; >+ protected final String TEXT_187 = ", tempDiagnostics, "; >+ protected final String TEXT_188 = ")) return true;"; >+ protected final String TEXT_189 = NL + "\t\t\tif ("; >+ protected final String TEXT_190 = ".isInstance("; >+ protected final String TEXT_191 = "))" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >+ protected final String TEXT_192 = "if ("; >+ protected final String TEXT_193 = "validate"; >+ protected final String TEXT_194 = "("; >+ protected final String TEXT_195 = "("; >+ protected final String TEXT_196 = "("; >+ protected final String TEXT_197 = ")"; >+ protected final String TEXT_198 = ")."; >+ protected final String TEXT_199 = "()"; >+ protected final String TEXT_200 = ", tempDiagnostics, "; >+ protected final String TEXT_201 = ")) "; >+ protected final String TEXT_202 = "return true;" + NL + "\t\t\t}"; >+ protected final String TEXT_203 = NL + "\t\t\tfor ("; >+ protected final String TEXT_204 = " diagnostic : tempDiagnostics.getChildren())" + NL + "\t\t\t{" + NL + "\t\t\t\tdiagnostics.add(diagnostic);" + NL + "\t\t\t}"; >+ protected final String TEXT_205 = NL + "\t\t\t"; >+ protected final String TEXT_206 = " children = tempDiagnostics.getChildren();" + NL + "\t\t\tfor (int i = 0; i < children.size(); i++)" + NL + "\t\t\t{" + NL + "\t\t\t\tdiagnostics.add(("; >+ protected final String TEXT_207 = ")children.get(i));" + NL + "\t\t\t}"; >+ protected final String TEXT_208 = NL + "\t\t}" + NL + "\t\telse" + NL + "\t\t{"; >+ protected final String TEXT_209 = NL + "\t\t\tif ("; > protected final String TEXT_210 = "validate"; > protected final String TEXT_211 = "("; >- protected final String TEXT_212 = "("; >- protected final String TEXT_213 = "("; >- protected final String TEXT_214 = ")"; >- protected final String TEXT_215 = ")."; >- protected final String TEXT_216 = "()"; >- protected final String TEXT_217 = ", null, "; >- protected final String TEXT_218 = ")) "; >- protected final String TEXT_219 = "return true;" + NL + "\t\t\t}"; >- protected final String TEXT_220 = NL + "\t\t}" + NL + "\t\treturn false;"; >- protected final String TEXT_221 = NL + "\t\treturn validatePattern("; >- protected final String TEXT_222 = ", "; >- protected final String TEXT_223 = "new "; >- protected final String TEXT_224 = "("; >- protected final String TEXT_225 = ")"; >- protected final String TEXT_226 = ", "; >- protected final String TEXT_227 = "__VALUES, "; >- protected final String TEXT_228 = ", "; >- protected final String TEXT_229 = ");"; >- protected final String TEXT_230 = NL + "\t\t"; >- protected final String TEXT_231 = " "; >- protected final String TEXT_232 = " = new "; >- protected final String TEXT_233 = "("; >- protected final String TEXT_234 = ");"; >- protected final String TEXT_235 = NL + "\t\tboolean "; >- protected final String TEXT_236 = " = "; >- protected final String TEXT_237 = "__VALUES.contains("; >- protected final String TEXT_238 = ");" + NL + "\t\tif (!"; >- protected final String TEXT_239 = " && "; >- protected final String TEXT_240 = " != null)" + NL + "\t\t\treportEnumerationViolation("; >- protected final String TEXT_241 = ", "; >- protected final String TEXT_242 = ", "; >- protected final String TEXT_243 = "__VALUES, "; >- protected final String TEXT_244 = ", "; >- protected final String TEXT_245 = ");" + NL + "\t\treturn "; >- protected final String TEXT_246 = ";"; >- protected final String TEXT_247 = NL + "\t\tboolean "; >- protected final String TEXT_248 = " = "; >- protected final String TEXT_249 = " "; >- protected final String TEXT_250 = " "; >- protected final String TEXT_251 = "__VALUE;" + NL + "\t\tif (!"; >- protected final String TEXT_252 = " && "; >- protected final String TEXT_253 = " != null)"; >- protected final String TEXT_254 = NL + "\t\t\treportMinViolation("; >- protected final String TEXT_255 = ", new "; >- protected final String TEXT_256 = "("; >- protected final String TEXT_257 = "), new "; >- protected final String TEXT_258 = "("; >- protected final String TEXT_259 = "__VALUE), "; >- protected final String TEXT_260 = ", "; >- protected final String TEXT_261 = ", "; >- protected final String TEXT_262 = ");"; >- protected final String TEXT_263 = NL + "\t\t\treportMinViolation("; >- protected final String TEXT_264 = ", "; >- protected final String TEXT_265 = ", "; >- protected final String TEXT_266 = "__VALUE, "; >- protected final String TEXT_267 = ", "; >+ protected final String TEXT_212 = ", null, "; >+ protected final String TEXT_213 = ")) return true;"; >+ protected final String TEXT_214 = NL + "\t\t\tif ("; >+ protected final String TEXT_215 = ".isInstance("; >+ protected final String TEXT_216 = "))" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >+ protected final String TEXT_217 = "if ("; >+ protected final String TEXT_218 = "validate"; >+ protected final String TEXT_219 = "("; >+ protected final String TEXT_220 = "("; >+ protected final String TEXT_221 = "("; >+ protected final String TEXT_222 = ")"; >+ protected final String TEXT_223 = ")."; >+ protected final String TEXT_224 = "()"; >+ protected final String TEXT_225 = ", null, "; >+ protected final String TEXT_226 = ")) "; >+ protected final String TEXT_227 = "return true;" + NL + "\t\t\t}"; >+ protected final String TEXT_228 = NL + "\t\t}" + NL + "\t\treturn false;"; >+ protected final String TEXT_229 = NL + "\t\treturn validatePattern("; >+ protected final String TEXT_230 = ", "; >+ protected final String TEXT_231 = "new "; >+ protected final String TEXT_232 = "("; >+ protected final String TEXT_233 = ")"; >+ protected final String TEXT_234 = ", "; >+ protected final String TEXT_235 = "__VALUES, "; >+ protected final String TEXT_236 = ", "; >+ protected final String TEXT_237 = ");"; >+ protected final String TEXT_238 = NL + "\t\t"; >+ protected final String TEXT_239 = " "; >+ protected final String TEXT_240 = " = new "; >+ protected final String TEXT_241 = "("; >+ protected final String TEXT_242 = ");"; >+ protected final String TEXT_243 = NL + "\t\tboolean "; >+ protected final String TEXT_244 = " = "; >+ protected final String TEXT_245 = "__VALUES.contains("; >+ protected final String TEXT_246 = ");" + NL + "\t\tif (!"; >+ protected final String TEXT_247 = " && "; >+ protected final String TEXT_248 = " != null)" + NL + "\t\t\treportEnumerationViolation("; >+ protected final String TEXT_249 = ", "; >+ protected final String TEXT_250 = ", "; >+ protected final String TEXT_251 = "__VALUES, "; >+ protected final String TEXT_252 = ", "; >+ protected final String TEXT_253 = ");" + NL + "\t\treturn "; >+ protected final String TEXT_254 = ";"; >+ protected final String TEXT_255 = NL + "\t\tboolean "; >+ protected final String TEXT_256 = " = "; >+ protected final String TEXT_257 = " "; >+ protected final String TEXT_258 = " "; >+ protected final String TEXT_259 = "__VALUE;" + NL + "\t\tif (!"; >+ protected final String TEXT_260 = " && "; >+ protected final String TEXT_261 = " != null)"; >+ protected final String TEXT_262 = NL + "\t\t\treportMinViolation("; >+ protected final String TEXT_263 = ", new "; >+ protected final String TEXT_264 = "("; >+ protected final String TEXT_265 = "), new "; >+ protected final String TEXT_266 = "("; >+ protected final String TEXT_267 = "__VALUE), "; > protected final String TEXT_268 = ", "; >- protected final String TEXT_269 = ");"; >- protected final String TEXT_270 = NL + "\t\treturn "; >- protected final String TEXT_271 = ";"; >- protected final String TEXT_272 = NL + "\t\tint "; >- protected final String TEXT_273 = " = "; >- protected final String TEXT_274 = ".compareCalendar("; >+ protected final String TEXT_269 = ", "; >+ protected final String TEXT_270 = ");"; >+ protected final String TEXT_271 = NL + "\t\t\treportMinViolation("; >+ protected final String TEXT_272 = ", "; >+ protected final String TEXT_273 = ", "; >+ protected final String TEXT_274 = "__VALUE, "; > protected final String TEXT_275 = ", "; >- protected final String TEXT_276 = "__VALUE);" + NL + "\t\tboolean "; >- protected final String TEXT_277 = " = "; >- protected final String TEXT_278 = " == 0 || "; >- protected final String TEXT_279 = " == 1;"; >+ protected final String TEXT_276 = ", "; >+ protected final String TEXT_277 = ");"; >+ protected final String TEXT_278 = NL + "\t\treturn "; >+ protected final String TEXT_279 = ";"; > protected final String TEXT_280 = NL + "\t\tint "; > protected final String TEXT_281 = " = "; >- protected final String TEXT_282 = ".compareDuration("; >+ protected final String TEXT_282 = ".compareCalendar("; > protected final String TEXT_283 = ", "; > protected final String TEXT_284 = "__VALUE);" + NL + "\t\tboolean "; > protected final String TEXT_285 = " = "; > protected final String TEXT_286 = " == 0 || "; > protected final String TEXT_287 = " == 1;"; >- protected final String TEXT_288 = NL + "\t\tboolean "; >+ protected final String TEXT_288 = NL + "\t\tint "; > protected final String TEXT_289 = " = "; >- protected final String TEXT_290 = ".compareTo("; >- protected final String TEXT_291 = "__VALUE) "; >- protected final String TEXT_292 = " 0;"; >- protected final String TEXT_293 = NL + "\t\tif (!"; >- protected final String TEXT_294 = " && "; >- protected final String TEXT_295 = " != null)" + NL + "\t\t\treportMinViolation("; >- protected final String TEXT_296 = ", "; >- protected final String TEXT_297 = ", "; >- protected final String TEXT_298 = "__VALUE, "; >- protected final String TEXT_299 = ", "; >- protected final String TEXT_300 = ", "; >- protected final String TEXT_301 = ");" + NL + "\t\treturn "; >- protected final String TEXT_302 = ";"; >- protected final String TEXT_303 = NL + "\t\tboolean "; >- protected final String TEXT_304 = " = "; >- protected final String TEXT_305 = " "; >- protected final String TEXT_306 = " "; >- protected final String TEXT_307 = "__VALUE;" + NL + "\t\tif (!"; >- protected final String TEXT_308 = " && "; >- protected final String TEXT_309 = " != null)"; >- protected final String TEXT_310 = NL + "\t\t\treportMaxViolation("; >- protected final String TEXT_311 = ", new "; >- protected final String TEXT_312 = "("; >- protected final String TEXT_313 = "), new "; >- protected final String TEXT_314 = "("; >- protected final String TEXT_315 = "__VALUE), "; >- protected final String TEXT_316 = ", "; >- protected final String TEXT_317 = ", "; >- protected final String TEXT_318 = ");"; >- protected final String TEXT_319 = NL + "\t\t\treportMaxViolation("; >- protected final String TEXT_320 = ", "; >- protected final String TEXT_321 = ", "; >- protected final String TEXT_322 = "__VALUE, "; >- protected final String TEXT_323 = ", "; >+ protected final String TEXT_290 = ".compareDuration("; >+ protected final String TEXT_291 = ", "; >+ protected final String TEXT_292 = "__VALUE);" + NL + "\t\tboolean "; >+ protected final String TEXT_293 = " = "; >+ protected final String TEXT_294 = " == 0 || "; >+ protected final String TEXT_295 = " == 1;"; >+ protected final String TEXT_296 = NL + "\t\tboolean "; >+ protected final String TEXT_297 = " = "; >+ protected final String TEXT_298 = ".compareTo("; >+ protected final String TEXT_299 = "__VALUE) "; >+ protected final String TEXT_300 = " 0;"; >+ protected final String TEXT_301 = NL + "\t\tif (!"; >+ protected final String TEXT_302 = " && "; >+ protected final String TEXT_303 = " != null)" + NL + "\t\t\treportMinViolation("; >+ protected final String TEXT_304 = ", "; >+ protected final String TEXT_305 = ", "; >+ protected final String TEXT_306 = "__VALUE, "; >+ protected final String TEXT_307 = ", "; >+ protected final String TEXT_308 = ", "; >+ protected final String TEXT_309 = ");" + NL + "\t\treturn "; >+ protected final String TEXT_310 = ";"; >+ protected final String TEXT_311 = NL + "\t\tboolean "; >+ protected final String TEXT_312 = " = "; >+ protected final String TEXT_313 = " "; >+ protected final String TEXT_314 = " "; >+ protected final String TEXT_315 = "__VALUE;" + NL + "\t\tif (!"; >+ protected final String TEXT_316 = " && "; >+ protected final String TEXT_317 = " != null)"; >+ protected final String TEXT_318 = NL + "\t\t\treportMaxViolation("; >+ protected final String TEXT_319 = ", new "; >+ protected final String TEXT_320 = "("; >+ protected final String TEXT_321 = "), new "; >+ protected final String TEXT_322 = "("; >+ protected final String TEXT_323 = "__VALUE), "; > protected final String TEXT_324 = ", "; >- protected final String TEXT_325 = ");"; >- protected final String TEXT_326 = NL + "\t\treturn "; >- protected final String TEXT_327 = ";"; >- protected final String TEXT_328 = NL + "\t\tint "; >- protected final String TEXT_329 = " = "; >- protected final String TEXT_330 = ".compareCalendar("; >+ protected final String TEXT_325 = ", "; >+ protected final String TEXT_326 = ");"; >+ protected final String TEXT_327 = NL + "\t\t\treportMaxViolation("; >+ protected final String TEXT_328 = ", "; >+ protected final String TEXT_329 = ", "; >+ protected final String TEXT_330 = "__VALUE, "; > protected final String TEXT_331 = ", "; >- protected final String TEXT_332 = "__VALUE);" + NL + "\t\tboolean "; >- protected final String TEXT_333 = " = "; >- protected final String TEXT_334 = " == 0 || "; >- protected final String TEXT_335 = " == -1;"; >+ protected final String TEXT_332 = ", "; >+ protected final String TEXT_333 = ");"; >+ protected final String TEXT_334 = NL + "\t\treturn "; >+ protected final String TEXT_335 = ";"; > protected final String TEXT_336 = NL + "\t\tint "; > protected final String TEXT_337 = " = "; >- protected final String TEXT_338 = ".compareDuration("; >+ protected final String TEXT_338 = ".compareCalendar("; > protected final String TEXT_339 = ", "; > protected final String TEXT_340 = "__VALUE);" + NL + "\t\tboolean "; > protected final String TEXT_341 = " = "; > protected final String TEXT_342 = " == 0 || "; > protected final String TEXT_343 = " == -1;"; >- protected final String TEXT_344 = NL + "\t\tboolean "; >+ protected final String TEXT_344 = NL + "\t\tint "; > protected final String TEXT_345 = " = "; >- protected final String TEXT_346 = ".compareTo("; >- protected final String TEXT_347 = "__VALUE) "; >- protected final String TEXT_348 = " 0;"; >- protected final String TEXT_349 = NL + "\t\tif (!"; >- protected final String TEXT_350 = " && "; >- protected final String TEXT_351 = " != null)" + NL + "\t\t\treportMaxViolation("; >- protected final String TEXT_352 = ", "; >- protected final String TEXT_353 = ", "; >- protected final String TEXT_354 = "__VALUE, "; >- protected final String TEXT_355 = ", "; >- protected final String TEXT_356 = ", "; >- protected final String TEXT_357 = ");" + NL + "\t\treturn "; >- protected final String TEXT_358 = ";"; >- protected final String TEXT_359 = NL + "\t\tint length = "; >- protected final String TEXT_360 = "."; >- protected final String TEXT_361 = ";" + NL + "\t\tboolean "; >- protected final String TEXT_362 = " = length >= "; >- protected final String TEXT_363 = ";" + NL + "\t\tif (!"; >- protected final String TEXT_364 = " && "; >- protected final String TEXT_365 = " != null)" + NL + "\t\t\treportMinLengthViolation("; >- protected final String TEXT_366 = ", "; >- protected final String TEXT_367 = ", length, "; >- protected final String TEXT_368 = ", "; >- protected final String TEXT_369 = ", "; >- protected final String TEXT_370 = ");" + NL + "\t\treturn "; >- protected final String TEXT_371 = ";"; >- protected final String TEXT_372 = NL + "\t\tint length = "; >- protected final String TEXT_373 = "."; >- protected final String TEXT_374 = ";" + NL + "\t\tboolean "; >- protected final String TEXT_375 = " = length <= "; >- protected final String TEXT_376 = ";" + NL + "\t\tif (!"; >- protected final String TEXT_377 = " && "; >- protected final String TEXT_378 = " != null)" + NL + "\t\t\treportMaxLengthViolation("; >- protected final String TEXT_379 = ", "; >- protected final String TEXT_380 = ", length, "; >- protected final String TEXT_381 = ", "; >- protected final String TEXT_382 = ", "; >- protected final String TEXT_383 = ");" + NL + "\t\treturn "; >- protected final String TEXT_384 = ";"; >- protected final String TEXT_385 = NL + "\t\tboolean "; >- protected final String TEXT_386 = " = "; >- protected final String TEXT_387 = " > "; >- protected final String TEXT_388 = "__LOWER_BOUND && "; >- protected final String TEXT_389 = " < "; >- protected final String TEXT_390 = "__UPPER_BOUND;" + NL + "\t\tif (!"; >- protected final String TEXT_391 = " && "; >- protected final String TEXT_392 = " != null)"; >- protected final String TEXT_393 = NL + "\t\t\treportTotalDigitsViolation("; >- protected final String TEXT_394 = ", new "; >- protected final String TEXT_395 = "("; >- protected final String TEXT_396 = "), "; >- protected final String TEXT_397 = ", "; >- protected final String TEXT_398 = ", "; >- protected final String TEXT_399 = ");"; >- protected final String TEXT_400 = NL + "\t\t\treportTotalDigitsViolation("; >- protected final String TEXT_401 = ", "; >- protected final String TEXT_402 = ", "; >- protected final String TEXT_403 = ", "; >- protected final String TEXT_404 = ", "; >- protected final String TEXT_405 = ");"; >- protected final String TEXT_406 = NL + "\t\tboolean "; >- protected final String TEXT_407 = " = "; >- protected final String TEXT_408 = ".unscaledValue().abs().toString().length() <= "; >- protected final String TEXT_409 = ";" + NL + "\t\tif (!"; >- protected final String TEXT_410 = " && "; >- protected final String TEXT_411 = " != null)" + NL + "\t\t\treportTotalDigitsViolation("; >+ protected final String TEXT_346 = ".compareDuration("; >+ protected final String TEXT_347 = ", "; >+ protected final String TEXT_348 = "__VALUE);" + NL + "\t\tboolean "; >+ protected final String TEXT_349 = " = "; >+ protected final String TEXT_350 = " == 0 || "; >+ protected final String TEXT_351 = " == -1;"; >+ protected final String TEXT_352 = NL + "\t\tboolean "; >+ protected final String TEXT_353 = " = "; >+ protected final String TEXT_354 = ".compareTo("; >+ protected final String TEXT_355 = "__VALUE) "; >+ protected final String TEXT_356 = " 0;"; >+ protected final String TEXT_357 = NL + "\t\tif (!"; >+ protected final String TEXT_358 = " && "; >+ protected final String TEXT_359 = " != null)" + NL + "\t\t\treportMaxViolation("; >+ protected final String TEXT_360 = ", "; >+ protected final String TEXT_361 = ", "; >+ protected final String TEXT_362 = "__VALUE, "; >+ protected final String TEXT_363 = ", "; >+ protected final String TEXT_364 = ", "; >+ protected final String TEXT_365 = ");" + NL + "\t\treturn "; >+ protected final String TEXT_366 = ";"; >+ protected final String TEXT_367 = NL + "\t\tint length = "; >+ protected final String TEXT_368 = "."; >+ protected final String TEXT_369 = ";" + NL + "\t\tboolean "; >+ protected final String TEXT_370 = " = length >= "; >+ protected final String TEXT_371 = ";" + NL + "\t\tif (!"; >+ protected final String TEXT_372 = " && "; >+ protected final String TEXT_373 = " != null)" + NL + "\t\t\treportMinLengthViolation("; >+ protected final String TEXT_374 = ", "; >+ protected final String TEXT_375 = ", length, "; >+ protected final String TEXT_376 = ", "; >+ protected final String TEXT_377 = ", "; >+ protected final String TEXT_378 = ");" + NL + "\t\treturn "; >+ protected final String TEXT_379 = ";"; >+ protected final String TEXT_380 = NL + "\t\tint length = "; >+ protected final String TEXT_381 = "."; >+ protected final String TEXT_382 = ";" + NL + "\t\tboolean "; >+ protected final String TEXT_383 = " = length <= "; >+ protected final String TEXT_384 = ";" + NL + "\t\tif (!"; >+ protected final String TEXT_385 = " && "; >+ protected final String TEXT_386 = " != null)" + NL + "\t\t\treportMaxLengthViolation("; >+ protected final String TEXT_387 = ", "; >+ protected final String TEXT_388 = ", length, "; >+ protected final String TEXT_389 = ", "; >+ protected final String TEXT_390 = ", "; >+ protected final String TEXT_391 = ");" + NL + "\t\treturn "; >+ protected final String TEXT_392 = ";"; >+ protected final String TEXT_393 = NL + "\t\tboolean "; >+ protected final String TEXT_394 = " = "; >+ protected final String TEXT_395 = " > "; >+ protected final String TEXT_396 = "__LOWER_BOUND && "; >+ protected final String TEXT_397 = " < "; >+ protected final String TEXT_398 = "__UPPER_BOUND;" + NL + "\t\tif (!"; >+ protected final String TEXT_399 = " && "; >+ protected final String TEXT_400 = " != null)"; >+ protected final String TEXT_401 = NL + "\t\t\treportTotalDigitsViolation("; >+ protected final String TEXT_402 = ", new "; >+ protected final String TEXT_403 = "("; >+ protected final String TEXT_404 = "), "; >+ protected final String TEXT_405 = ", "; >+ protected final String TEXT_406 = ", "; >+ protected final String TEXT_407 = ");"; >+ protected final String TEXT_408 = NL + "\t\t\treportTotalDigitsViolation("; >+ protected final String TEXT_409 = ", "; >+ protected final String TEXT_410 = ", "; >+ protected final String TEXT_411 = ", "; > protected final String TEXT_412 = ", "; >- protected final String TEXT_413 = ", "; >- protected final String TEXT_414 = ", "; >- protected final String TEXT_415 = ", "; >- protected final String TEXT_416 = ");"; >- protected final String TEXT_417 = NL + "\t\tboolean "; >- protected final String TEXT_418 = " = "; >- protected final String TEXT_419 = ".compareTo("; >- protected final String TEXT_420 = "__LOWER_BOUND) > 0 && "; >- protected final String TEXT_421 = ".compareTo("; >- protected final String TEXT_422 = "__UPPER_BOUND) < 0;" + NL + "\t\tif (!"; >- protected final String TEXT_423 = " && "; >- protected final String TEXT_424 = " != null)" + NL + "\t\t\treportTotalDigitsViolation("; >- protected final String TEXT_425 = ", "; >- protected final String TEXT_426 = ", "; >- protected final String TEXT_427 = ", "; >- protected final String TEXT_428 = ", "; >- protected final String TEXT_429 = ");"; >- protected final String TEXT_430 = NL + "\t\treturn "; >- protected final String TEXT_431 = ";"; >- protected final String TEXT_432 = NL + "\t\tboolean "; >- protected final String TEXT_433 = " = "; >- protected final String TEXT_434 = ".scale() <= "; >- protected final String TEXT_435 = ";" + NL + "\t\tif (!"; >- protected final String TEXT_436 = " && "; >- protected final String TEXT_437 = " != null)" + NL + "\t\t\treportFractionDigitsViolation("; >- protected final String TEXT_438 = ", "; >- protected final String TEXT_439 = ", "; >- protected final String TEXT_440 = ", "; >- protected final String TEXT_441 = ", "; >- protected final String TEXT_442 = ");" + NL + "\t\treturn "; >- protected final String TEXT_443 = ";"; >- protected final String TEXT_444 = NL + "\t\t// TODO override the constraint, if desired" + NL + "\t\t// -> uncomment the scaffolding" + NL + "\t\t// -> specify the condition that violates the constraint" + NL + "\t\t// -> verify the diagnostic details, including severity, code, and message" + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\tif (false)" + NL + "\t\t{" + NL + "\t\t\tif ("; >- protected final String TEXT_445 = " != null)" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >- protected final String TEXT_446 = ".add"; >- protected final String TEXT_447 = NL + "\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t("; >- protected final String TEXT_448 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t \"_UI_GenericConstraint_diagnostic\","; >- protected final String TEXT_449 = NL + "\t\t\t\t\t\t new Object[] { \""; >- protected final String TEXT_450 = "\", getValueLabel("; >- protected final String TEXT_451 = ", "; >- protected final String TEXT_452 = ", "; >- protected final String TEXT_453 = ") },"; >- protected final String TEXT_454 = NL + "\t\t\t\t\t\t new Object[] { "; >- protected final String TEXT_455 = " }," + NL + "\t\t\t\t\t\t context));"; >- protected final String TEXT_456 = NL + "\t\t\t\t\t(new "; >- protected final String TEXT_457 = NL + "\t\t\t\t\t\t("; >- protected final String TEXT_458 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t "; >- protected final String TEXT_459 = ".INSTANCE.getString(\"_UI_GenericConstraint_diagnostic\", new Object[] { \""; >- protected final String TEXT_460 = "\", getValueLabel("; >- protected final String TEXT_461 = ", "; >- protected final String TEXT_462 = ", "; >- protected final String TEXT_463 = ") }),"; >- protected final String TEXT_464 = NL + "\t\t\t\t\t\t new Object[] { "; >- protected final String TEXT_465 = " }));"; >- protected final String TEXT_466 = NL + "\t\t\t}" + NL + "\t\t\treturn false;" + NL + "\t\t}" + NL + "\t\treturn "; >- protected final String TEXT_467 = "validate"; >- protected final String TEXT_468 = "_"; >- protected final String TEXT_469 = "("; >+ protected final String TEXT_413 = ");"; >+ protected final String TEXT_414 = NL + "\t\tboolean "; >+ protected final String TEXT_415 = " = "; >+ protected final String TEXT_416 = ".unscaledValue().abs().toString().length() <= "; >+ protected final String TEXT_417 = ";" + NL + "\t\tif (!"; >+ protected final String TEXT_418 = " && "; >+ protected final String TEXT_419 = " != null)" + NL + "\t\t\treportTotalDigitsViolation("; >+ protected final String TEXT_420 = ", "; >+ protected final String TEXT_421 = ", "; >+ protected final String TEXT_422 = ", "; >+ protected final String TEXT_423 = ", "; >+ protected final String TEXT_424 = ");"; >+ protected final String TEXT_425 = NL + "\t\tboolean "; >+ protected final String TEXT_426 = " = "; >+ protected final String TEXT_427 = ".compareTo("; >+ protected final String TEXT_428 = "__LOWER_BOUND) > 0 && "; >+ protected final String TEXT_429 = ".compareTo("; >+ protected final String TEXT_430 = "__UPPER_BOUND) < 0;" + NL + "\t\tif (!"; >+ protected final String TEXT_431 = " && "; >+ protected final String TEXT_432 = " != null)" + NL + "\t\t\treportTotalDigitsViolation("; >+ protected final String TEXT_433 = ", "; >+ protected final String TEXT_434 = ", "; >+ protected final String TEXT_435 = ", "; >+ protected final String TEXT_436 = ", "; >+ protected final String TEXT_437 = ");"; >+ protected final String TEXT_438 = NL + "\t\treturn "; >+ protected final String TEXT_439 = ";"; >+ protected final String TEXT_440 = NL + "\t\tboolean "; >+ protected final String TEXT_441 = " = "; >+ protected final String TEXT_442 = ".scale() <= "; >+ protected final String TEXT_443 = ";" + NL + "\t\tif (!"; >+ protected final String TEXT_444 = " && "; >+ protected final String TEXT_445 = " != null)" + NL + "\t\t\treportFractionDigitsViolation("; >+ protected final String TEXT_446 = ", "; >+ protected final String TEXT_447 = ", "; >+ protected final String TEXT_448 = ", "; >+ protected final String TEXT_449 = ", "; >+ protected final String TEXT_450 = ");" + NL + "\t\treturn "; >+ protected final String TEXT_451 = ";"; >+ protected final String TEXT_452 = NL + "\t\t// TODO override the constraint, if desired" + NL + "\t\t// -> uncomment the scaffolding" + NL + "\t\t// -> specify the condition that violates the constraint" + NL + "\t\t// -> verify the diagnostic details, including severity, code, and message" + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\tif (false)" + NL + "\t\t{" + NL + "\t\t\tif ("; >+ protected final String TEXT_453 = " != null)" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >+ protected final String TEXT_454 = ".add"; >+ protected final String TEXT_455 = NL + "\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t("; >+ protected final String TEXT_456 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t \"_UI_GenericConstraint_diagnostic\","; >+ protected final String TEXT_457 = NL + "\t\t\t\t\t\t new Object[] { \""; >+ protected final String TEXT_458 = "\", getValueLabel("; >+ protected final String TEXT_459 = ", "; >+ protected final String TEXT_460 = ", "; >+ protected final String TEXT_461 = ") },"; >+ protected final String TEXT_462 = NL + "\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_463 = " }," + NL + "\t\t\t\t\t\t context));"; >+ protected final String TEXT_464 = NL + "\t\t\t\t\t(new "; >+ protected final String TEXT_465 = NL + "\t\t\t\t\t\t("; >+ protected final String TEXT_466 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t "; >+ protected final String TEXT_467 = ".INSTANCE.getString(\"_UI_GenericConstraint_diagnostic\", new Object[] { \""; >+ protected final String TEXT_468 = "\", getValueLabel("; >+ protected final String TEXT_469 = ", "; > protected final String TEXT_470 = ", "; >- protected final String TEXT_471 = ", "; >- protected final String TEXT_472 = ");"; >- protected final String TEXT_473 = NL + "\t\t// TODO implement the constraint" + NL + "\t\t// -> specify the condition that violates the constraint" + NL + "\t\t// -> verify the diagnostic details, including severity, code, and message" + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\tif (false)" + NL + "\t\t{" + NL + "\t\t\tif ("; >- protected final String TEXT_474 = " != null)" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >- protected final String TEXT_475 = ".add"; >- protected final String TEXT_476 = NL + "\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t("; >- protected final String TEXT_477 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t \"_UI_GenericConstraint_diagnostic\","; >- protected final String TEXT_478 = NL + "\t\t\t\t\t\t new Object[] { \""; >- protected final String TEXT_479 = "\", getValueLabel("; >- protected final String TEXT_480 = ", "; >- protected final String TEXT_481 = ", "; >- protected final String TEXT_482 = ") },"; >- protected final String TEXT_483 = NL + "\t\t\t\t\t\t new Object[] { "; >- protected final String TEXT_484 = " }," + NL + "\t\t\t\t\t\t context));"; >- protected final String TEXT_485 = NL + "\t\t\t\t\t(new "; >- protected final String TEXT_486 = NL + "\t\t\t\t\t\t("; >- protected final String TEXT_487 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t "; >- protected final String TEXT_488 = ".INSTANCE.getString(\"_UI_GenericConstraint_diagnostic\", new Object[] { \""; >- protected final String TEXT_489 = "\", getValueLabel("; >+ protected final String TEXT_471 = ") }),"; >+ protected final String TEXT_472 = NL + "\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_473 = " }));"; >+ protected final String TEXT_474 = NL + "\t\t\t}" + NL + "\t\t\treturn false;" + NL + "\t\t}" + NL + "\t\treturn "; >+ protected final String TEXT_475 = "validate"; >+ protected final String TEXT_476 = "_"; >+ protected final String TEXT_477 = "("; >+ protected final String TEXT_478 = ", "; >+ protected final String TEXT_479 = ", "; >+ protected final String TEXT_480 = ");"; >+ protected final String TEXT_481 = NL + "\t\t"; >+ protected final String TEXT_482 = ".Registry registry = getValidationDelegateRegistry("; >+ protected final String TEXT_483 = ");" + NL + "\t\t"; >+ protected final String TEXT_484 = " delegate = registry.getValidationDelegate("; >+ protected final String TEXT_485 = ".createURI(\""; >+ protected final String TEXT_486 = "\"));"; >+ protected final String TEXT_487 = NL + "\t\tif (delegate != null) {" + NL + "\t\t\ttry {" + NL + "\t\t\t\tif (!delegate.validate("; >+ protected final String TEXT_488 = "__"; >+ protected final String TEXT_489 = "__EXP, "; > protected final String TEXT_490 = ", "; > protected final String TEXT_491 = ", "; >- protected final String TEXT_492 = ") }),"; >- protected final String TEXT_493 = NL + "\t\t\t\t\t\t new Object[] { "; >- protected final String TEXT_494 = " }));"; >- protected final String TEXT_495 = NL + "\t\t\t}" + NL + "\t\t\treturn false;" + NL + "\t\t}" + NL + "\t\treturn true;"; >- protected final String TEXT_496 = NL + "\t\t// TODO override the constraint, if desired" + NL + "\t\t// -> uncomment the scaffolding" + NL + "\t\t// -> specify the condition that violates the constraint" + NL + "\t\t// -> verify the diagnostic details, including severity, code, and message" + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\tif (false)" + NL + "\t\t{" + NL + "\t\t\tif ("; >- protected final String TEXT_497 = " != null)" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >- protected final String TEXT_498 = ".add"; >- protected final String TEXT_499 = NL + "\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t("; >- protected final String TEXT_500 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t \"_UI_GenericConstraint_diagnostic\","; >- protected final String TEXT_501 = NL + "\t\t\t\t\t\t new Object[] { \""; >- protected final String TEXT_502 = "\", getObjectLabel("; >- protected final String TEXT_503 = ", "; >- protected final String TEXT_504 = ") },"; >- protected final String TEXT_505 = NL + "\t\t\t\t\t\t new Object[] { "; >- protected final String TEXT_506 = " }," + NL + "\t\t\t\t\t\t context));"; >- protected final String TEXT_507 = NL + "\t\t\t\t\t(new "; >- protected final String TEXT_508 = NL + "\t\t\t\t\t\t("; >- protected final String TEXT_509 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t "; >- protected final String TEXT_510 = ".INSTANCE.getString(\"_UI_GenericConstraint_diagnostic\", new Object[] { \""; >- protected final String TEXT_511 = "\", getObjectLabel("; >- protected final String TEXT_512 = ", "; >- protected final String TEXT_513 = ") }),"; >- protected final String TEXT_514 = NL + "\t\t\t\t\t\t new Object[] { "; >- protected final String TEXT_515 = " }));"; >- protected final String TEXT_516 = NL + "\t\t\t}" + NL + "\t\t\treturn false;" + NL + "\t\t}" + NL + "\t\treturn "; >- protected final String TEXT_517 = "validate"; >- protected final String TEXT_518 = "_"; >- protected final String TEXT_519 = "("; >- protected final String TEXT_520 = ", "; >- protected final String TEXT_521 = ", "; >- protected final String TEXT_522 = ");"; >- protected final String TEXT_523 = NL + "\t\treturn "; >- protected final String TEXT_524 = "."; >- protected final String TEXT_525 = "("; >- protected final String TEXT_526 = ", "; >- protected final String TEXT_527 = ");"; >- protected final String TEXT_528 = NL + "\t\t// TODO implement the constraint" + NL + "\t\t// -> specify the condition that violates the constraint" + NL + "\t\t// -> verify the diagnostic details, including severity, code, and message" + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\tif (false)" + NL + "\t\t{" + NL + "\t\t\tif ("; >- protected final String TEXT_529 = " != null)" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >- protected final String TEXT_530 = ".add"; >- protected final String TEXT_531 = NL + "\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t("; >- protected final String TEXT_532 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t \"_UI_GenericConstraint_diagnostic\","; >- protected final String TEXT_533 = NL + "\t\t\t\t\t\t new Object[] { \""; >- protected final String TEXT_534 = "\", getObjectLabel("; >- protected final String TEXT_535 = ", "; >- protected final String TEXT_536 = ") },"; >- protected final String TEXT_537 = NL + "\t\t\t\t\t\t new Object[] { "; >- protected final String TEXT_538 = " }," + NL + "\t\t\t\t\t\t context));"; >- protected final String TEXT_539 = NL + "\t\t\t\t\t(new "; >- protected final String TEXT_540 = NL + "\t\t\t\t\t\t("; >- protected final String TEXT_541 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t "; >- protected final String TEXT_542 = ".INSTANCE.getString(\"_UI_GenericConstraint_diagnostic\", new Object[] { \""; >- protected final String TEXT_543 = "\", getObjectLabel("; >- protected final String TEXT_544 = ", "; >- protected final String TEXT_545 = ") }),"; >- protected final String TEXT_546 = NL + "\t\t\t\t\t\t new Object[] { "; >- protected final String TEXT_547 = " }));"; >- protected final String TEXT_548 = NL + "\t\t\t}" + NL + "\t\t\treturn false;" + NL + "\t\t}" + NL + "\t\treturn true;"; >- protected final String TEXT_549 = NL + "\t}" + NL; >- protected final String TEXT_550 = NL + "\t/**" + NL + "\t * Returns the resource locator that will be used to fetch messages for this validator's diagnostics." + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >- protected final String TEXT_551 = NL + "\t@Override"; >- protected final String TEXT_552 = NL + "\tpublic "; >- protected final String TEXT_553 = " getResourceLocator()" + NL + "\t{"; >- protected final String TEXT_554 = NL + "\t\treturn "; >- protected final String TEXT_555 = ".INSTANCE;"; >- protected final String TEXT_556 = NL + "\t\t// TODO" + NL + "\t\t// Specialize this to return a resource locator for messages specific to this validator." + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\treturn super.getResourceLocator();"; >- protected final String TEXT_557 = NL + "\t}" + NL; >- protected final String TEXT_558 = NL + "} //"; >- protected final String TEXT_559 = NL; >+ protected final String TEXT_492 = ")) {" + NL + "\t\t\t\t\tif (diagnostics != null) {" + NL + "\t\t\t\t\t\t"; >+ protected final String TEXT_493 = ".add" + NL + "\t\t\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t\t\t("; >+ protected final String TEXT_494 = ".ERROR," + NL + "\t\t\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t\t\t \"_UI_GenericConstraint_diagnostic\","; >+ protected final String TEXT_495 = NL + "\t\t\t\t\t\t\t\t new Object[] { \""; >+ protected final String TEXT_496 = "\", getValueLabel("; >+ protected final String TEXT_497 = ", "; >+ protected final String TEXT_498 = ", "; >+ protected final String TEXT_499 = ") },"; >+ protected final String TEXT_500 = NL + "\t\t\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_501 = " }," + NL + "\t\t\t\t\t\t\t\t context));" + NL + "\t\t\t\t\t}" + NL + "\t\t\t\t\treturn false;" + NL + "\t\t\t\t}" + NL + "\t\t\t\treturn true;" + NL + "\t\t\t} catch ("; >+ protected final String TEXT_502 = " throwable) {" + NL + "\t\t\t\tif (diagnostics != null) {" + NL + "\t\t\t\t\t"; >+ protected final String TEXT_503 = ".add" + NL + "\t\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t\t("; >+ protected final String TEXT_504 = ".ERROR," + NL + "\t\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t\t \"_UI_ConstraintDelegateException_diagnostic\","; >+ protected final String TEXT_505 = NL + "\t\t\t\t\t\t\t new Object[] { \""; >+ protected final String TEXT_506 = "\", getValueLabel("; >+ protected final String TEXT_507 = ", "; >+ protected final String TEXT_508 = ", "; >+ protected final String TEXT_509 = "), throwable.getLocalizedMessage() },"; >+ protected final String TEXT_510 = NL + "\t\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_511 = " }," + NL + "\t\t\t\t\t\t\t context));" + NL + "\t\t\t\t}" + NL + "\t\t\t\treturn false;" + NL + "\t\t\t}" + NL + "\t\t} else {" + NL + "\t\t\tif (diagnostics != null) {" + NL + "\t\t\t\t"; >+ protected final String TEXT_512 = ".add" + NL + "\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t("; >+ protected final String TEXT_513 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t \"_UI_ConstraintDelegateNotFound_diagnostic\","; >+ protected final String TEXT_514 = NL + "\t\t\t\t\t\t new Object[] { \""; >+ protected final String TEXT_515 = "\", getValueLabel("; >+ protected final String TEXT_516 = ", "; >+ protected final String TEXT_517 = ", "; >+ protected final String TEXT_518 = "), \""; >+ protected final String TEXT_519 = "\" },"; >+ protected final String TEXT_520 = NL + "\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_521 = " }," + NL + "\t\t\t\t\t\t context));" + NL + "\t\t\t}" + NL + "\t\t\treturn false;" + NL + "\t\t}"; >+ protected final String TEXT_522 = NL + "\t\t// TODO implement the constraint" + NL + "\t\t// -> specify the condition that violates the constraint" + NL + "\t\t// -> verify the diagnostic details, including severity, code, and message" + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\tif (false)" + NL + "\t\t{" + NL + "\t\t\tif ("; >+ protected final String TEXT_523 = " != null)" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >+ protected final String TEXT_524 = ".add"; >+ protected final String TEXT_525 = NL + "\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t("; >+ protected final String TEXT_526 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t \"_UI_GenericConstraint_diagnostic\","; >+ protected final String TEXT_527 = NL + "\t\t\t\t\t\t new Object[] { \""; >+ protected final String TEXT_528 = "\", getValueLabel("; >+ protected final String TEXT_529 = ", "; >+ protected final String TEXT_530 = ", "; >+ protected final String TEXT_531 = ") },"; >+ protected final String TEXT_532 = NL + "\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_533 = " }," + NL + "\t\t\t\t\t\t context));"; >+ protected final String TEXT_534 = NL + "\t\t\t\t\t(new "; >+ protected final String TEXT_535 = NL + "\t\t\t\t\t\t("; >+ protected final String TEXT_536 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t "; >+ protected final String TEXT_537 = ".INSTANCE.getString(\"_UI_GenericConstraint_diagnostic\", new Object[] { \""; >+ protected final String TEXT_538 = "\", getValueLabel("; >+ protected final String TEXT_539 = ", "; >+ protected final String TEXT_540 = ", "; >+ protected final String TEXT_541 = ") }),"; >+ protected final String TEXT_542 = NL + "\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_543 = " }));"; >+ protected final String TEXT_544 = NL + "\t\t\t}" + NL + "\t\t\treturn false;" + NL + "\t\t}" + NL + "\t\treturn true;"; >+ protected final String TEXT_545 = NL + "\t\t// TODO override the constraint, if desired" + NL + "\t\t// -> uncomment the scaffolding" + NL + "\t\t// -> specify the condition that violates the constraint" + NL + "\t\t// -> verify the diagnostic details, including severity, code, and message" + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\tif (false)" + NL + "\t\t{" + NL + "\t\t\tif ("; >+ protected final String TEXT_546 = " != null)" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >+ protected final String TEXT_547 = ".add"; >+ protected final String TEXT_548 = NL + "\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t("; >+ protected final String TEXT_549 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t \"_UI_GenericConstraint_diagnostic\","; >+ protected final String TEXT_550 = NL + "\t\t\t\t\t\t new Object[] { \""; >+ protected final String TEXT_551 = "\", getObjectLabel("; >+ protected final String TEXT_552 = ", "; >+ protected final String TEXT_553 = ") },"; >+ protected final String TEXT_554 = NL + "\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_555 = " }," + NL + "\t\t\t\t\t\t context));"; >+ protected final String TEXT_556 = NL + "\t\t\t\t\t(new "; >+ protected final String TEXT_557 = NL + "\t\t\t\t\t\t("; >+ protected final String TEXT_558 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t "; >+ protected final String TEXT_559 = ".INSTANCE.getString(\"_UI_GenericConstraint_diagnostic\", new Object[] { \""; >+ protected final String TEXT_560 = "\", getObjectLabel("; >+ protected final String TEXT_561 = ", "; >+ protected final String TEXT_562 = ") }),"; >+ protected final String TEXT_563 = NL + "\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_564 = " }));"; >+ protected final String TEXT_565 = NL + "\t\t\t}" + NL + "\t\t\treturn false;" + NL + "\t\t}" + NL + "\t\treturn "; >+ protected final String TEXT_566 = "validate"; >+ protected final String TEXT_567 = "_"; >+ protected final String TEXT_568 = "("; >+ protected final String TEXT_569 = ", "; >+ protected final String TEXT_570 = ", "; >+ protected final String TEXT_571 = ");"; >+ protected final String TEXT_572 = NL + "\t\treturn "; >+ protected final String TEXT_573 = "."; >+ protected final String TEXT_574 = "("; >+ protected final String TEXT_575 = ", "; >+ protected final String TEXT_576 = ");"; >+ protected final String TEXT_577 = NL + "\t\t"; >+ protected final String TEXT_578 = ".Registry registry = getValidationDelegateRegistry("; >+ protected final String TEXT_579 = ");" + NL + "\t\t"; >+ protected final String TEXT_580 = " delegate = registry.getValidationDelegate("; >+ protected final String TEXT_581 = ".createURI(\""; >+ protected final String TEXT_582 = "\"));"; >+ protected final String TEXT_583 = NL + "\t\tif (delegate != null) {" + NL + "\t\t\ttry {" + NL + "\t\t\t\tif (!delegate.validate("; >+ protected final String TEXT_584 = "__"; >+ protected final String TEXT_585 = "__EXP, "; >+ protected final String TEXT_586 = ", "; >+ protected final String TEXT_587 = ", "; >+ protected final String TEXT_588 = ")) {" + NL + "\t\t\t\t\tif (diagnostics != null) {" + NL + "\t\t\t\t\t\t"; >+ protected final String TEXT_589 = ".add" + NL + "\t\t\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t\t\t("; >+ protected final String TEXT_590 = ".ERROR," + NL + "\t\t\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t\t\t \"_UI_GenericConstraint_diagnostic\","; >+ protected final String TEXT_591 = NL + "\t\t\t\t\t\t\t\t new Object[] { \""; >+ protected final String TEXT_592 = "\", getObjectLabel("; >+ protected final String TEXT_593 = ", "; >+ protected final String TEXT_594 = ") },"; >+ protected final String TEXT_595 = NL + "\t\t\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_596 = " }," + NL + "\t\t\t\t\t\t\t\t context));" + NL + "\t\t\t\t\t}" + NL + "\t\t\t\t\treturn false;" + NL + "\t\t\t\t}" + NL + "\t\t\t\treturn true;" + NL + "\t\t\t} catch ("; >+ protected final String TEXT_597 = " throwable) {" + NL + "\t\t\t\tif (diagnostics != null) {" + NL + "\t\t\t\t\t"; >+ protected final String TEXT_598 = ".add" + NL + "\t\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t\t("; >+ protected final String TEXT_599 = ".ERROR," + NL + "\t\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t\t \"_UI_ConstraintDelegateException_diagnostic\","; >+ protected final String TEXT_600 = NL + "\t\t\t\t\t\t\t new Object[] { \""; >+ protected final String TEXT_601 = "\", getObjectLabel("; >+ protected final String TEXT_602 = ", "; >+ protected final String TEXT_603 = "), throwable.getLocalizedMessage() },"; >+ protected final String TEXT_604 = NL + "\t\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_605 = " }," + NL + "\t\t\t\t\t\t\t context));" + NL + "\t\t\t\t}" + NL + "\t\t\t\treturn false;" + NL + "\t\t\t}" + NL + "\t\t} else {" + NL + "\t\t\tif (diagnostics != null) {" + NL + "\t\t\t\t"; >+ protected final String TEXT_606 = ".add" + NL + "\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t("; >+ protected final String TEXT_607 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t \"_UI_ConstraintDelegateNotFound_diagnostic\","; >+ protected final String TEXT_608 = NL + "\t\t\t\t\t\t new Object[] { \""; >+ protected final String TEXT_609 = "\", getObjectLabel("; >+ protected final String TEXT_610 = ", "; >+ protected final String TEXT_611 = "), \""; >+ protected final String TEXT_612 = "\" },"; >+ protected final String TEXT_613 = NL + "\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_614 = " }," + NL + "\t\t\t\t\t\t context));" + NL + "\t\t\t}" + NL + "\t\t\treturn false;" + NL + "\t\t}"; >+ protected final String TEXT_615 = NL + "\t\t// TODO implement the constraint" + NL + "\t\t// -> specify the condition that violates the constraint" + NL + "\t\t// -> verify the diagnostic details, including severity, code, and message" + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\tif (false)" + NL + "\t\t{" + NL + "\t\t\tif ("; >+ protected final String TEXT_616 = " != null)" + NL + "\t\t\t{" + NL + "\t\t\t\t"; >+ protected final String TEXT_617 = ".add"; >+ protected final String TEXT_618 = NL + "\t\t\t\t\t(createDiagnostic" + NL + "\t\t\t\t\t\t("; >+ protected final String TEXT_619 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t \"_UI_GenericConstraint_diagnostic\","; >+ protected final String TEXT_620 = NL + "\t\t\t\t\t\t new Object[] { \""; >+ protected final String TEXT_621 = "\", getObjectLabel("; >+ protected final String TEXT_622 = ", "; >+ protected final String TEXT_623 = ") },"; >+ protected final String TEXT_624 = NL + "\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_625 = " }," + NL + "\t\t\t\t\t\t context));"; >+ protected final String TEXT_626 = NL + "\t\t\t\t\t(new "; >+ protected final String TEXT_627 = NL + "\t\t\t\t\t\t("; >+ protected final String TEXT_628 = ".ERROR," + NL + "\t\t\t\t\t\t DIAGNOSTIC_SOURCE," + NL + "\t\t\t\t\t\t 0," + NL + "\t\t\t\t\t\t "; >+ protected final String TEXT_629 = ".INSTANCE.getString(\"_UI_GenericConstraint_diagnostic\", new Object[] { \""; >+ protected final String TEXT_630 = "\", getObjectLabel("; >+ protected final String TEXT_631 = ", "; >+ protected final String TEXT_632 = ") }),"; >+ protected final String TEXT_633 = NL + "\t\t\t\t\t\t new Object[] { "; >+ protected final String TEXT_634 = " }));"; >+ protected final String TEXT_635 = NL + "\t\t\t}" + NL + "\t\t\treturn false;" + NL + "\t\t}" + NL + "\t\treturn true;"; >+ protected final String TEXT_636 = NL + "\t}" + NL; >+ protected final String TEXT_637 = NL + "\t/**" + NL + "\t * Returns the resource locator that will be used to fetch messages for this validator's diagnostics." + NL + "\t * <!-- begin-user-doc -->" + NL + "\t * <!-- end-user-doc -->" + NL + "\t * @generated" + NL + "\t */"; >+ protected final String TEXT_638 = NL + "\t@Override"; >+ protected final String TEXT_639 = NL + "\tpublic "; >+ protected final String TEXT_640 = " getResourceLocator()" + NL + "\t{"; >+ protected final String TEXT_641 = NL + "\t\treturn "; >+ protected final String TEXT_642 = ".INSTANCE;"; >+ protected final String TEXT_643 = NL + "\t\t// TODO" + NL + "\t\t// Specialize this to return a resource locator for messages specific to this validator." + NL + "\t\t// Ensure that you remove @generated or mark it @generated NOT" + NL + "\t\treturn super.getResourceLocator();"; >+ protected final String TEXT_644 = NL + "\t}" + NL; >+ protected final String TEXT_645 = NL + "} //"; >+ protected final String TEXT_646 = NL; > > public String generate(Object argument) > { >@@ -583,7 +670,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2002-2006 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -623,6 +710,7 @@ > genModel.addPseudoImport("org.eclipse.emf.ecore.EValidator.Registry"); > genModel.addPseudoImport("org.eclipse.emf.ecore.EValidator.SubstitutionLabelProvider"); > genModel.addPseudoImport("org.eclipse.emf.ecore.EValidator.PatternMatcher"); >+ genModel.addPseudoImport("org.eclipse.emf.ecore.EValidator.ValidationDelegate"); > stringBuffer.append(TEXT_8); > stringBuffer.append(genPackage.getQualifiedPackageInterfaceName()); > stringBuffer.append(TEXT_9); >@@ -926,305 +1014,304 @@ > stringBuffer.append(TEXT_141); > } > } >+ if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF26_VALUE && genClassifier.hasValidationExpression(constraint)) { > stringBuffer.append(TEXT_142); > stringBuffer.append(constraint); > stringBuffer.append(TEXT_143); > stringBuffer.append(genClassifier.getFormattedName()); > stringBuffer.append(TEXT_144); >- stringBuffer.append(genClassifier.getName()); >+ stringBuffer.append(genModel.getImportedName("java.lang.String")); > stringBuffer.append(TEXT_145); >- stringBuffer.append(constraint); >+ stringBuffer.append(genClassifier.getClassifierID()); > stringBuffer.append(TEXT_146); >- stringBuffer.append(genClassifier.getImportedWildcardInstanceClassName()); >+ stringBuffer.append(CodeGenUtil.upperName(constraint)); > stringBuffer.append(TEXT_147); >- stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(genClassifier.getValidationExpression(constraint, genModel.getIndentation(stringBuffer))); > stringBuffer.append(TEXT_148); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(genModel.getNonNLS()); > stringBuffer.append(TEXT_149); >- stringBuffer.append(_Map); >+ } > stringBuffer.append(TEXT_150); >- stringBuffer.append(context); >+ stringBuffer.append(constraint); > stringBuffer.append(TEXT_151); >+ stringBuffer.append(genClassifier.getFormattedName()); >+ stringBuffer.append(TEXT_152); >+ stringBuffer.append(genClassifier.getName()); >+ stringBuffer.append(TEXT_153); >+ stringBuffer.append(constraint); >+ stringBuffer.append(TEXT_154); >+ stringBuffer.append(genClassifier.getImportedWildcardInstanceClassName()); >+ stringBuffer.append(TEXT_155); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_156); >+ stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_157); >+ stringBuffer.append(_Map); >+ stringBuffer.append(TEXT_158); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_159); > if (genClassifier instanceof GenDataType) { GenDataType genDataType = (GenDataType)genClassifier; > if (constraint.equals("ItemType") && genDataType.getItemType() != null) { GenDataType itemType = genDataType.getItemType(); String itemDelegate = itemType.getGenPackage() == genPackage ? "" : genPackage.getValidatorPackageUniqueSafeName(itemType.getGenPackage()) + "Validator."; >- stringBuffer.append(TEXT_152); >+ stringBuffer.append(TEXT_160); > stringBuffer.append(result); >- stringBuffer.append(TEXT_153); >+ stringBuffer.append(TEXT_161); > stringBuffer.append(genModel.getImportedName("java.util.Iterator")); > stringBuffer.append(singleWildcard); >- stringBuffer.append(TEXT_154); >+ stringBuffer.append(TEXT_162); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_155); >+ stringBuffer.append(TEXT_163); > if (itemType.getGenPackage().hasConstraints()) { >- stringBuffer.append(TEXT_156); >+ stringBuffer.append(TEXT_164); > stringBuffer.append(itemType.getQualifiedClassifierAccessor()); >- stringBuffer.append(TEXT_157); >+ stringBuffer.append(TEXT_165); > stringBuffer.append(itemDelegate); >- stringBuffer.append(TEXT_158); >+ stringBuffer.append(TEXT_166); > stringBuffer.append(itemType.getName()); >- stringBuffer.append(TEXT_159); >+ stringBuffer.append(TEXT_167); > if (itemType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { >- stringBuffer.append(TEXT_160); >+ stringBuffer.append(TEXT_168); > } > if (!itemType.isObjectType()) { >- stringBuffer.append(TEXT_161); >+ stringBuffer.append(TEXT_169); > stringBuffer.append(itemType.getObjectInstanceClassName()); >- stringBuffer.append(TEXT_162); >+ stringBuffer.append(TEXT_170); > } > stringBuffer.append(item); > if (itemType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { >- stringBuffer.append(TEXT_163); >+ stringBuffer.append(TEXT_171); > stringBuffer.append(itemType.getPrimitiveValueFunction()); >- stringBuffer.append(TEXT_164); >+ stringBuffer.append(TEXT_172); > } >- stringBuffer.append(TEXT_165); >+ stringBuffer.append(TEXT_173); > stringBuffer.append(diagnostics); >- stringBuffer.append(TEXT_166); >+ stringBuffer.append(TEXT_174); > stringBuffer.append(context); >- stringBuffer.append(TEXT_167); >+ stringBuffer.append(TEXT_175); > } else { >- stringBuffer.append(TEXT_168); >+ stringBuffer.append(TEXT_176); > stringBuffer.append(itemType.getQualifiedClassifierAccessor()); >- stringBuffer.append(TEXT_169); >+ stringBuffer.append(TEXT_177); > } >- stringBuffer.append(TEXT_170); >+ stringBuffer.append(TEXT_178); > stringBuffer.append(itemType.getQualifiedClassifierAccessor()); >- stringBuffer.append(TEXT_171); >+ stringBuffer.append(TEXT_179); > stringBuffer.append(diagnostics); >- stringBuffer.append(TEXT_172); >+ stringBuffer.append(TEXT_180); > stringBuffer.append(context); >- stringBuffer.append(TEXT_173); >+ stringBuffer.append(TEXT_181); > } else if (constraint.equals("MemberTypes") && !genDataType.getMemberTypes().isEmpty()) { >- stringBuffer.append(TEXT_174); >+ stringBuffer.append(TEXT_182); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")); >- stringBuffer.append(TEXT_175); >+ stringBuffer.append(TEXT_183); > for (ListIterator<GenDataType> k = genDataType.getMemberTypes().listIterator(); k.hasNext(); ) { GenDataType memberType = k.next(); String memberDelegate = memberType.getGenPackage() == genPackage ? "" : genPackage.getValidatorPackageUniqueSafeName(memberType.getGenPackage()) + "Validator."; > if (genDataType.isPrimitiveType()) { >- stringBuffer.append(TEXT_176); >+ stringBuffer.append(TEXT_184); > stringBuffer.append(memberDelegate); >- stringBuffer.append(TEXT_177); >+ stringBuffer.append(TEXT_185); > stringBuffer.append(memberType.getName()); >- stringBuffer.append(TEXT_178); >+ stringBuffer.append(TEXT_186); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_179); >+ stringBuffer.append(TEXT_187); > stringBuffer.append(context); >- stringBuffer.append(TEXT_180); >+ stringBuffer.append(TEXT_188); > } else { >- stringBuffer.append(TEXT_181); >+ stringBuffer.append(TEXT_189); > stringBuffer.append(memberType.getQualifiedClassifierAccessor()); >- stringBuffer.append(TEXT_182); >+ stringBuffer.append(TEXT_190); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_183); >+ stringBuffer.append(TEXT_191); > if (memberType.getGenPackage().hasConstraints()) { >- stringBuffer.append(TEXT_184); >+ stringBuffer.append(TEXT_192); > stringBuffer.append(memberDelegate); >- stringBuffer.append(TEXT_185); >+ stringBuffer.append(TEXT_193); > stringBuffer.append(memberType.getName()); >- stringBuffer.append(TEXT_186); >+ stringBuffer.append(TEXT_194); > if (memberType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { >- stringBuffer.append(TEXT_187); >+ stringBuffer.append(TEXT_195); > } > if (!memberType.isObjectType() && !memberType.getQualifiedInstanceClassName().equals(genDataType.getQualifiedInstanceClassName())) { >- stringBuffer.append(TEXT_188); >+ stringBuffer.append(TEXT_196); > stringBuffer.append(memberType.getImportedWildcardObjectInstanceClassName()); >- stringBuffer.append(TEXT_189); >+ stringBuffer.append(TEXT_197); > } > stringBuffer.append(genClassifier.getSafeUncapName()); > if (memberType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { >- stringBuffer.append(TEXT_190); >+ stringBuffer.append(TEXT_198); > stringBuffer.append(memberType.getPrimitiveValueFunction()); >- stringBuffer.append(TEXT_191); >+ stringBuffer.append(TEXT_199); > } >- stringBuffer.append(TEXT_192); >+ stringBuffer.append(TEXT_200); > stringBuffer.append(context); >- stringBuffer.append(TEXT_193); >+ stringBuffer.append(TEXT_201); > } >- stringBuffer.append(TEXT_194); >+ stringBuffer.append(TEXT_202); > } > } > if (genModel.useGenerics()) { >- stringBuffer.append(TEXT_195); >+ stringBuffer.append(TEXT_203); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >- stringBuffer.append(TEXT_196); >+ stringBuffer.append(TEXT_204); > } else { >- stringBuffer.append(TEXT_197); >+ stringBuffer.append(TEXT_205); > stringBuffer.append(genModel.getImportedName("java.util.List")); >- stringBuffer.append(TEXT_198); >+ stringBuffer.append(TEXT_206); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >- stringBuffer.append(TEXT_199); >+ stringBuffer.append(TEXT_207); > } >- stringBuffer.append(TEXT_200); >+ stringBuffer.append(TEXT_208); > for (ListIterator<GenDataType> k = genDataType.getMemberTypes().listIterator(); k.hasNext(); ) { GenDataType memberType = k.next(); String memberDelegate = memberType.getGenPackage() == genPackage ? "" : genPackage.getValidatorPackageUniqueSafeName(memberType.getGenPackage()) + "Validator."; > if (genDataType.isPrimitiveType()) { >- stringBuffer.append(TEXT_201); >+ stringBuffer.append(TEXT_209); > stringBuffer.append(memberDelegate); >- stringBuffer.append(TEXT_202); >+ stringBuffer.append(TEXT_210); > stringBuffer.append(memberType.getName()); >- stringBuffer.append(TEXT_203); >+ stringBuffer.append(TEXT_211); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_204); >+ stringBuffer.append(TEXT_212); > stringBuffer.append(context); >- stringBuffer.append(TEXT_205); >+ stringBuffer.append(TEXT_213); > } else { >- stringBuffer.append(TEXT_206); >+ stringBuffer.append(TEXT_214); > stringBuffer.append(memberType.getQualifiedClassifierAccessor()); >- stringBuffer.append(TEXT_207); >+ stringBuffer.append(TEXT_215); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_208); >+ stringBuffer.append(TEXT_216); > if (memberType.getGenPackage().hasConstraints()) { >- stringBuffer.append(TEXT_209); >+ stringBuffer.append(TEXT_217); > stringBuffer.append(memberDelegate); >- stringBuffer.append(TEXT_210); >+ stringBuffer.append(TEXT_218); > stringBuffer.append(memberType.getName()); >- stringBuffer.append(TEXT_211); >+ stringBuffer.append(TEXT_219); > if (memberType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { >- stringBuffer.append(TEXT_212); >+ stringBuffer.append(TEXT_220); > } > if (!memberType.isObjectType() && !memberType.getQualifiedInstanceClassName().equals(genDataType.getQualifiedInstanceClassName())) { >- stringBuffer.append(TEXT_213); >+ stringBuffer.append(TEXT_221); > stringBuffer.append(memberType.getImportedWildcardObjectInstanceClassName()); >- stringBuffer.append(TEXT_214); >+ stringBuffer.append(TEXT_222); > } > stringBuffer.append(genClassifier.getSafeUncapName()); > if (memberType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { >- stringBuffer.append(TEXT_215); >+ stringBuffer.append(TEXT_223); > stringBuffer.append(memberType.getPrimitiveValueFunction()); >- stringBuffer.append(TEXT_216); >+ stringBuffer.append(TEXT_224); > } >- stringBuffer.append(TEXT_217); >+ stringBuffer.append(TEXT_225); > stringBuffer.append(context); >- stringBuffer.append(TEXT_218); >+ stringBuffer.append(TEXT_226); > } >- stringBuffer.append(TEXT_219); >+ stringBuffer.append(TEXT_227); > } > } >- stringBuffer.append(TEXT_220); >+ stringBuffer.append(TEXT_228); > } else if (constraint.equals("Pattern") && !genDataType.getPatterns().isEmpty()) { >- stringBuffer.append(TEXT_221); >+ stringBuffer.append(TEXT_229); > stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >- stringBuffer.append(TEXT_222); >+ stringBuffer.append(TEXT_230); > if (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { >- stringBuffer.append(TEXT_223); >+ stringBuffer.append(TEXT_231); > stringBuffer.append(genDataType.getObjectInstanceClassName()); >- stringBuffer.append(TEXT_224); >+ stringBuffer.append(TEXT_232); > } > stringBuffer.append(genDataType.getSafeUncapName()); > if (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { >- stringBuffer.append(TEXT_225); >+ stringBuffer.append(TEXT_233); > } >- stringBuffer.append(TEXT_226); >+ stringBuffer.append(TEXT_234); > stringBuffer.append(constant); >- stringBuffer.append(TEXT_227); >+ stringBuffer.append(TEXT_235); > stringBuffer.append(diagnostics); >- stringBuffer.append(TEXT_228); >+ stringBuffer.append(TEXT_236); > stringBuffer.append(context); >- stringBuffer.append(TEXT_229); >+ stringBuffer.append(TEXT_237); > } else if (constraint.equals("Enumeration") && !genDataType.getEnumerationLiterals().isEmpty()) { String variable = genDataType.getSafeUncapName(); > if (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { variable = variable + "Object"; >- stringBuffer.append(TEXT_230); >- stringBuffer.append(genDataType.getObjectInstanceClassName()); >- stringBuffer.append(TEXT_231); >- stringBuffer.append(variable); >- stringBuffer.append(TEXT_232); >- stringBuffer.append(genDataType.getObjectInstanceClassName()); >- stringBuffer.append(TEXT_233); >- stringBuffer.append(genDataType.getSafeUncapName()); >- stringBuffer.append(TEXT_234); >- } >- stringBuffer.append(TEXT_235); >- stringBuffer.append(result); >- stringBuffer.append(TEXT_236); >- stringBuffer.append(constant); >- stringBuffer.append(TEXT_237); >- stringBuffer.append(variable); > stringBuffer.append(TEXT_238); >- stringBuffer.append(result); >+ stringBuffer.append(genDataType.getObjectInstanceClassName()); > stringBuffer.append(TEXT_239); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(variable); > stringBuffer.append(TEXT_240); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(genDataType.getObjectInstanceClassName()); > stringBuffer.append(TEXT_241); >- stringBuffer.append(variable); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_242); >- stringBuffer.append(constant); >+ } > stringBuffer.append(TEXT_243); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_244); >- stringBuffer.append(context); >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_245); >- stringBuffer.append(result); >+ stringBuffer.append(variable); > stringBuffer.append(TEXT_246); >- } else if (constraint.equals("Min") && genDataType.getMinLiteral() != null) { >- if (genDataType.isPrimitiveType()) { >- stringBuffer.append(TEXT_247); > stringBuffer.append(result); >+ stringBuffer.append(TEXT_247); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_248); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_249); >- stringBuffer.append(genDataType.isMinInclusive() ? ">=" : ">"); >+ stringBuffer.append(variable); > stringBuffer.append(TEXT_250); > stringBuffer.append(constant); > stringBuffer.append(TEXT_251); >- stringBuffer.append(result); >- stringBuffer.append(TEXT_252); > stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_252); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_253); >- if (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { >+ stringBuffer.append(result); > stringBuffer.append(TEXT_254); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ } else if (constraint.equals("Min") && genDataType.getMinLiteral() != null) { >+ if (genDataType.isPrimitiveType()) { > stringBuffer.append(TEXT_255); >- stringBuffer.append(genDataType.getObjectInstanceClassName()); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_256); > stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_257); >- stringBuffer.append(genDataType.getObjectInstanceClassName()); >+ stringBuffer.append(genDataType.isMinInclusive() ? ">=" : ">"); > stringBuffer.append(TEXT_258); > stringBuffer.append(constant); > stringBuffer.append(TEXT_259); >- stringBuffer.append(genDataType.isMinInclusive() ? "true" : "false"); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_260); > stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_261); >- stringBuffer.append(context); >+ if (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { > stringBuffer.append(TEXT_262); >- } else { >- stringBuffer.append(TEXT_263); > stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(TEXT_263); >+ stringBuffer.append(genDataType.getObjectInstanceClassName()); > stringBuffer.append(TEXT_264); > stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_265); >- stringBuffer.append(constant); >+ stringBuffer.append(genDataType.getObjectInstanceClassName()); > stringBuffer.append(TEXT_266); >- stringBuffer.append(genDataType.isMinInclusive() ? "true" : "false"); >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_267); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(genDataType.isMinInclusive() ? "true" : "false"); > stringBuffer.append(TEXT_268); >- stringBuffer.append(context); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_269); >- } >+ stringBuffer.append(context); > stringBuffer.append(TEXT_270); >- stringBuffer.append(result); >+ } else { > stringBuffer.append(TEXT_271); >- } else { String comparison = "comparison".equals(genClassifier.getSafeUncapName()) ? "theComparison" : "comparison"; >- if (genDataType.isXMLCalendar()) { >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_272); >- stringBuffer.append(comparison); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_273); >- stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.xml.type.util.XMLTypeUtil")); >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_274); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(genDataType.isMinInclusive() ? "true" : "false"); > stringBuffer.append(TEXT_275); >- stringBuffer.append(constant); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_276); >- stringBuffer.append(result); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_277); >- if (genDataType.isMinInclusive()) { >- stringBuffer.append(comparison); >- stringBuffer.append(TEXT_278); > } >- stringBuffer.append(comparison); >+ stringBuffer.append(TEXT_278); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_279); >- } else if (genDataType.isXMLDuration()) { >+ } else { String comparison = "comparison".equals(genClassifier.getSafeUncapName()) ? "theComparison" : "comparison"; >+ if (genDataType.isXMLCalendar()) { > stringBuffer.append(TEXT_280); > stringBuffer.append(comparison); > stringBuffer.append(TEXT_281); >@@ -1242,108 +1329,108 @@ > } > stringBuffer.append(comparison); > stringBuffer.append(TEXT_287); >- } else { >+ } else if (genDataType.isXMLDuration()) { > stringBuffer.append(TEXT_288); >- stringBuffer.append(result); >+ stringBuffer.append(comparison); > stringBuffer.append(TEXT_289); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.xml.type.util.XMLTypeUtil")); > stringBuffer.append(TEXT_290); >- stringBuffer.append(constant); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_291); >- stringBuffer.append(genDataType.isMinInclusive() ? ">=" : ">"); >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_292); >- } >- stringBuffer.append(TEXT_293); > stringBuffer.append(result); >+ stringBuffer.append(TEXT_293); >+ if (genDataType.isMinInclusive()) { >+ stringBuffer.append(comparison); > stringBuffer.append(TEXT_294); >- stringBuffer.append(diagnostics); >+ } >+ stringBuffer.append(comparison); > stringBuffer.append(TEXT_295); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ } else { > stringBuffer.append(TEXT_296); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_297); >- stringBuffer.append(constant); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_298); >- stringBuffer.append(genDataType.isMinInclusive() ? "true" : "false"); >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_299); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(genDataType.isMinInclusive() ? ">=" : ">"); > stringBuffer.append(TEXT_300); >- stringBuffer.append(context); >+ } > stringBuffer.append(TEXT_301); > stringBuffer.append(result); > stringBuffer.append(TEXT_302); >- } >- } else if (constraint.equals("Max") && genDataType.getMaxLiteral() != null) { >- if (genDataType.isPrimitiveType()) { >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_303); >- stringBuffer.append(result); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_304); > stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_305); >- stringBuffer.append(genDataType.isMaxInclusive() ? "<=" : "<"); >- stringBuffer.append(TEXT_306); > stringBuffer.append(constant); >+ stringBuffer.append(TEXT_306); >+ stringBuffer.append(genDataType.isMinInclusive() ? "true" : "false"); > stringBuffer.append(TEXT_307); >- stringBuffer.append(result); >- stringBuffer.append(TEXT_308); > stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_308); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_309); >- if (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { >+ stringBuffer.append(result); > stringBuffer.append(TEXT_310); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ } >+ } else if (constraint.equals("Max") && genDataType.getMaxLiteral() != null) { >+ if (genDataType.isPrimitiveType()) { > stringBuffer.append(TEXT_311); >- stringBuffer.append(genDataType.getObjectInstanceClassName()); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_312); > stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_313); >- stringBuffer.append(genDataType.getObjectInstanceClassName()); >+ stringBuffer.append(genDataType.isMaxInclusive() ? "<=" : "<"); > stringBuffer.append(TEXT_314); > stringBuffer.append(constant); > stringBuffer.append(TEXT_315); >- stringBuffer.append(genDataType.isMaxInclusive() ? "true" : "false"); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_316); > stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_317); >- stringBuffer.append(context); >+ if (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { > stringBuffer.append(TEXT_318); >- } else { >- stringBuffer.append(TEXT_319); > stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(TEXT_319); >+ stringBuffer.append(genDataType.getObjectInstanceClassName()); > stringBuffer.append(TEXT_320); > stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_321); >- stringBuffer.append(constant); >+ stringBuffer.append(genDataType.getObjectInstanceClassName()); > stringBuffer.append(TEXT_322); >- stringBuffer.append(genDataType.isMaxInclusive() ? "true" : "false"); >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_323); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(genDataType.isMaxInclusive() ? "true" : "false"); > stringBuffer.append(TEXT_324); >- stringBuffer.append(context); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_325); >- } >+ stringBuffer.append(context); > stringBuffer.append(TEXT_326); >- stringBuffer.append(result); >+ } else { > stringBuffer.append(TEXT_327); >- } else { String comparison = "comparison".equals(genClassifier.getSafeUncapName()) ? "theComparison" : "comparison"; >- if (genDataType.isXMLCalendar()) { >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_328); >- stringBuffer.append(comparison); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_329); >- stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.xml.type.util.XMLTypeUtil")); >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_330); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(genDataType.isMaxInclusive() ? "true" : "false"); > stringBuffer.append(TEXT_331); >- stringBuffer.append(constant); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_332); >- stringBuffer.append(result); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_333); >- if (genDataType.isMaxInclusive()) { >- stringBuffer.append(comparison); >- stringBuffer.append(TEXT_334); > } >- stringBuffer.append(comparison); >+ stringBuffer.append(TEXT_334); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_335); >- } else if (genDataType.isXMLDuration()) { >+ } else { String comparison = "comparison".equals(genClassifier.getSafeUncapName()) ? "theComparison" : "comparison"; >+ if (genDataType.isXMLCalendar()) { > stringBuffer.append(TEXT_336); > stringBuffer.append(comparison); > stringBuffer.append(TEXT_337); >@@ -1361,451 +1448,633 @@ > } > stringBuffer.append(comparison); > stringBuffer.append(TEXT_343); >- } else { >+ } else if (genDataType.isXMLDuration()) { > stringBuffer.append(TEXT_344); >- stringBuffer.append(result); >+ stringBuffer.append(comparison); > stringBuffer.append(TEXT_345); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.xml.type.util.XMLTypeUtil")); > stringBuffer.append(TEXT_346); >- stringBuffer.append(constant); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_347); >- stringBuffer.append(genDataType.isMaxInclusive() ? "<=" : "<"); >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_348); >- } >- stringBuffer.append(TEXT_349); > stringBuffer.append(result); >+ stringBuffer.append(TEXT_349); >+ if (genDataType.isMaxInclusive()) { >+ stringBuffer.append(comparison); > stringBuffer.append(TEXT_350); >- stringBuffer.append(diagnostics); >+ } >+ stringBuffer.append(comparison); > stringBuffer.append(TEXT_351); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ } else { > stringBuffer.append(TEXT_352); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_353); >- stringBuffer.append(constant); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_354); >- stringBuffer.append(genDataType.isMaxInclusive() ? "true" : "false"); >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_355); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(genDataType.isMaxInclusive() ? "<=" : "<"); > stringBuffer.append(TEXT_356); >- stringBuffer.append(context); >+ } > stringBuffer.append(TEXT_357); > stringBuffer.append(result); > stringBuffer.append(TEXT_358); >- } >- } else if (constraint.equals("MinLength") && genDataType.getMinLength() != -1) { >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_359); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_360); >- stringBuffer.append(genDataType.getLengthAccessorFunction()); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_361); >- stringBuffer.append(result); >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_362); >- stringBuffer.append(genDataType.getMinLength()); >+ stringBuffer.append(genDataType.isMaxInclusive() ? "true" : "false"); > stringBuffer.append(TEXT_363); >- stringBuffer.append(result); >- stringBuffer.append(TEXT_364); > stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_364); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_365); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_366); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ } >+ } else if (constraint.equals("MinLength") && genDataType.getMinLength() != -1) { > stringBuffer.append(TEXT_367); >- stringBuffer.append(genDataType.getMinLength()); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_368); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(genDataType.getLengthAccessorFunction()); > stringBuffer.append(TEXT_369); >- stringBuffer.append(context); >- stringBuffer.append(TEXT_370); > stringBuffer.append(result); >+ stringBuffer.append(TEXT_370); >+ stringBuffer.append(genDataType.getMinLength()); > stringBuffer.append(TEXT_371); >- } else if (constraint.equals("MaxLength") && genDataType.getMaxLength() != -1) { >+ stringBuffer.append(result); > stringBuffer.append(TEXT_372); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_373); >- stringBuffer.append(genDataType.getLengthAccessorFunction()); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_374); >- stringBuffer.append(result); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_375); >- stringBuffer.append(genDataType.getMaxLength()); >+ stringBuffer.append(genDataType.getMinLength()); > stringBuffer.append(TEXT_376); >- stringBuffer.append(result); >- stringBuffer.append(TEXT_377); > stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_377); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_378); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_379); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ } else if (constraint.equals("MaxLength") && genDataType.getMaxLength() != -1) { > stringBuffer.append(TEXT_380); >- stringBuffer.append(genDataType.getMaxLength()); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_381); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(genDataType.getLengthAccessorFunction()); > stringBuffer.append(TEXT_382); >- stringBuffer.append(context); >- stringBuffer.append(TEXT_383); > stringBuffer.append(result); >+ stringBuffer.append(TEXT_383); >+ stringBuffer.append(genDataType.getMaxLength()); > stringBuffer.append(TEXT_384); >- } else if (constraint.equals("TotalDigits") && genDataType.getTotalDigits() != -1) { >- if (genDataType.isPrimitiveType()) { >- stringBuffer.append(TEXT_385); > stringBuffer.append(result); >+ stringBuffer.append(TEXT_385); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_386); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_387); >- stringBuffer.append(constant); >- stringBuffer.append(TEXT_388); > stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(TEXT_388); >+ stringBuffer.append(genDataType.getMaxLength()); > stringBuffer.append(TEXT_389); >- stringBuffer.append(constant); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_390); >- stringBuffer.append(result); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_391); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_392); >- if (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { >+ } else if (constraint.equals("TotalDigits") && genDataType.getTotalDigits() != -1) { >+ if (genDataType.isPrimitiveType()) { > stringBuffer.append(TEXT_393); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_394); >- stringBuffer.append(genDataType.getObjectInstanceClassName()); >- stringBuffer.append(TEXT_395); > stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(TEXT_395); >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_396); >- stringBuffer.append(genDataType.getTotalDigits()); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_397); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_398); >- stringBuffer.append(context); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_399); >- } else { >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_400); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ if (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) { > stringBuffer.append(TEXT_401); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_402); >- stringBuffer.append(genDataType.getTotalDigits()); >+ stringBuffer.append(genDataType.getObjectInstanceClassName()); > stringBuffer.append(TEXT_403); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_404); >- stringBuffer.append(context); >+ stringBuffer.append(genDataType.getTotalDigits()); > stringBuffer.append(TEXT_405); >- } >- } else if ("java.math.BigDecimal".equals(genDataType.getQualifiedInstanceClassName())) { >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_406); >- stringBuffer.append(result); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_407); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ } else { > stringBuffer.append(TEXT_408); >- stringBuffer.append(genDataType.getTotalDigits()); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_409); >- stringBuffer.append(result); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_410); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(genDataType.getTotalDigits()); > stringBuffer.append(TEXT_411); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_412); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_413); >- stringBuffer.append(genDataType.getTotalDigits()); >+ } >+ } else if ("java.math.BigDecimal".equals(genDataType.getQualifiedInstanceClassName())) { > stringBuffer.append(TEXT_414); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_415); >- stringBuffer.append(context); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_416); >- } else { >+ stringBuffer.append(genDataType.getTotalDigits()); > stringBuffer.append(TEXT_417); > stringBuffer.append(result); > stringBuffer.append(TEXT_418); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_419); >- stringBuffer.append(constant); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_420); > stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_421); >- stringBuffer.append(constant); >+ stringBuffer.append(genDataType.getTotalDigits()); > stringBuffer.append(TEXT_422); >- stringBuffer.append(result); >- stringBuffer.append(TEXT_423); > stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_423); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_424); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ } else { > stringBuffer.append(TEXT_425); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_426); >- stringBuffer.append(genDataType.getTotalDigits()); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_427); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_428); >- stringBuffer.append(context); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_429); >- } >+ stringBuffer.append(constant); > stringBuffer.append(TEXT_430); > stringBuffer.append(result); > stringBuffer.append(TEXT_431); >- } else if (constraint.equals("FractionDigits") && genDataType.getFractionDigits() != -1 && "java.math.BigDecimal".equals(genDataType.getQualifiedInstanceClassName())) { >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_432); >- stringBuffer.append(result); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_433); > stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_434); >- stringBuffer.append(genDataType.getFractionDigits()); >+ stringBuffer.append(genDataType.getTotalDigits()); > stringBuffer.append(TEXT_435); >- stringBuffer.append(result); >- stringBuffer.append(TEXT_436); > stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_436); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_437); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ } > stringBuffer.append(TEXT_438); >- stringBuffer.append(genDataType.getSafeUncapName()); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_439); >- stringBuffer.append(genDataType.getFractionDigits()); >+ } else if (constraint.equals("FractionDigits") && genDataType.getFractionDigits() != -1 && "java.math.BigDecimal".equals(genDataType.getQualifiedInstanceClassName())) { > stringBuffer.append(TEXT_440); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_441); >- stringBuffer.append(context); >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_442); >- stringBuffer.append(result); >+ stringBuffer.append(genDataType.getFractionDigits()); > stringBuffer.append(TEXT_443); >- } else if (constraintDelegate != null) { >+ stringBuffer.append(result); > stringBuffer.append(TEXT_444); > stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_445); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_446); >- if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE) { >+ stringBuffer.append(genDataType.getSafeUncapName()); > stringBuffer.append(TEXT_447); >- stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(genDataType.getFractionDigits()); > stringBuffer.append(TEXT_448); >- stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_449); >- stringBuffer.append(constraint); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_450); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(result); > stringBuffer.append(TEXT_451); >- stringBuffer.append(genClassifier.getSafeUncapName()); >+ } else if (constraintDelegate != null) { > stringBuffer.append(TEXT_452); >- stringBuffer.append(context); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_453); >- stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_454); >- stringBuffer.append(genClassifier.getSafeUncapName()); >+ if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE) { > stringBuffer.append(TEXT_455); >- } else { >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); > stringBuffer.append(TEXT_456); >- stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")); >+ stringBuffer.append(genModel.getNonNLS()); > stringBuffer.append(TEXT_457); >- stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(constraint); > stringBuffer.append(TEXT_458); >- stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_459); >- stringBuffer.append(constraint); >+ stringBuffer.append(genClassifier.getSafeUncapName()); > stringBuffer.append(TEXT_460); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_461); >- stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(genModel.getNonNLS()); > stringBuffer.append(TEXT_462); >- stringBuffer.append(context); >+ stringBuffer.append(genClassifier.getSafeUncapName()); > stringBuffer.append(TEXT_463); >- stringBuffer.append(genModel.getNonNLS()); >- stringBuffer.append(genModel.getNonNLS(2)); >+ } else { > stringBuffer.append(TEXT_464); >- stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")); > stringBuffer.append(TEXT_465); >- } >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); > stringBuffer.append(TEXT_466); >- stringBuffer.append(delegate); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")); > stringBuffer.append(TEXT_467); >- stringBuffer.append(constraintDelegate.getName()); >- stringBuffer.append(TEXT_468); > stringBuffer.append(constraint); >+ stringBuffer.append(TEXT_468); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_469); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(accessor); > stringBuffer.append(TEXT_470); >- stringBuffer.append(diagnostics); >- stringBuffer.append(TEXT_471); > stringBuffer.append(context); >+ stringBuffer.append(TEXT_471); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(genModel.getNonNLS(2)); > stringBuffer.append(TEXT_472); >- } else { >+ stringBuffer.append(genClassifier.getSafeUncapName()); > stringBuffer.append(TEXT_473); >- stringBuffer.append(diagnostics); >+ } > stringBuffer.append(TEXT_474); >- stringBuffer.append(diagnostics); >+ stringBuffer.append(delegate); > stringBuffer.append(TEXT_475); >- if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE) { >+ stringBuffer.append(constraintDelegate.getName()); > stringBuffer.append(TEXT_476); >- stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(constraint); > stringBuffer.append(TEXT_477); >- stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(accessor); > stringBuffer.append(TEXT_478); >- stringBuffer.append(constraint); >+ stringBuffer.append(diagnostics); > stringBuffer.append(TEXT_479); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_480); >- stringBuffer.append(genClassifier.getSafeUncapName()); >+ } else { >+ if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF26_VALUE && genClassifier.hasValidationExpression(constraint)) { > stringBuffer.append(TEXT_481); >- stringBuffer.append(context); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")); > stringBuffer.append(TEXT_482); >- stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(context); > stringBuffer.append(TEXT_483); >- stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")); > stringBuffer.append(TEXT_484); >- } else { >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.URI")); > stringBuffer.append(TEXT_485); >- stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")); >+ stringBuffer.append(genClassifier.getValidationDelegate(constraint)); > stringBuffer.append(TEXT_486); >- stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(genModel.getNonNLS()); > stringBuffer.append(TEXT_487); >- stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")); >+ stringBuffer.append(genClassifier.getClassifierID()); > stringBuffer.append(TEXT_488); >- stringBuffer.append(constraint); >+ stringBuffer.append(CodeGenUtil.upperName(constraint)); > stringBuffer.append(TEXT_489); >- stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(genClassifier.getQualifiedClassifierAccessor()); > stringBuffer.append(TEXT_490); > stringBuffer.append(genClassifier.getSafeUncapName()); > stringBuffer.append(TEXT_491); > stringBuffer.append(context); > stringBuffer.append(TEXT_492); >+ stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_493); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(TEXT_494); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_495); >+ stringBuffer.append(constraint); >+ stringBuffer.append(TEXT_496); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(TEXT_497); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_498); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_499); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_500); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_501); >+ stringBuffer.append(genModel.getImportedName("java.lang.Throwable")); >+ stringBuffer.append(TEXT_502); >+ stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_503); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(TEXT_504); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_505); >+ stringBuffer.append(constraint); >+ stringBuffer.append(TEXT_506); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(TEXT_507); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_508); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_509); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_510); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_511); >+ stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_512); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(TEXT_513); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_514); >+ stringBuffer.append(constraint); >+ stringBuffer.append(TEXT_515); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(TEXT_516); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_517); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_518); >+ stringBuffer.append(genClassifier.getValidationDelegate(constraint)); >+ stringBuffer.append(TEXT_519); > stringBuffer.append(genModel.getNonNLS()); > stringBuffer.append(genModel.getNonNLS(2)); >- stringBuffer.append(TEXT_493); >+ stringBuffer.append(TEXT_520); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_494); >+ stringBuffer.append(TEXT_521); >+ } else { >+ stringBuffer.append(TEXT_522); >+ stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_523); >+ stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_524); >+ if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE) { >+ stringBuffer.append(TEXT_525); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(TEXT_526); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_527); >+ stringBuffer.append(constraint); >+ stringBuffer.append(TEXT_528); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(TEXT_529); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_530); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_531); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_532); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_533); >+ } else { >+ stringBuffer.append(TEXT_534); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")); >+ stringBuffer.append(TEXT_535); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(TEXT_536); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")); >+ stringBuffer.append(TEXT_537); >+ stringBuffer.append(constraint); >+ stringBuffer.append(TEXT_538); >+ stringBuffer.append(genDataType.getQualifiedClassifierAccessor()); >+ stringBuffer.append(TEXT_539); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_540); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_541); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(genModel.getNonNLS(2)); >+ stringBuffer.append(TEXT_542); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_543); >+ } >+ stringBuffer.append(TEXT_544); > } >- stringBuffer.append(TEXT_495); > } > } else if (constraintDelegate != null) { >- stringBuffer.append(TEXT_496); >+ stringBuffer.append(TEXT_545); > stringBuffer.append(diagnostics); >- stringBuffer.append(TEXT_497); >+ stringBuffer.append(TEXT_546); > stringBuffer.append(diagnostics); >- stringBuffer.append(TEXT_498); >+ stringBuffer.append(TEXT_547); > if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE) { >- stringBuffer.append(TEXT_499); >+ stringBuffer.append(TEXT_548); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >- stringBuffer.append(TEXT_500); >+ stringBuffer.append(TEXT_549); > stringBuffer.append(genModel.getNonNLS()); >- stringBuffer.append(TEXT_501); >+ stringBuffer.append(TEXT_550); > stringBuffer.append(constraint); >- stringBuffer.append(TEXT_502); >+ stringBuffer.append(TEXT_551); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_503); >+ stringBuffer.append(TEXT_552); > stringBuffer.append(context); >- stringBuffer.append(TEXT_504); >+ stringBuffer.append(TEXT_553); > stringBuffer.append(genModel.getNonNLS()); >- stringBuffer.append(TEXT_505); >+ stringBuffer.append(TEXT_554); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_506); >+ stringBuffer.append(TEXT_555); > } else { >- stringBuffer.append(TEXT_507); >+ stringBuffer.append(TEXT_556); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")); >- stringBuffer.append(TEXT_508); >+ stringBuffer.append(TEXT_557); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >- stringBuffer.append(TEXT_509); >+ stringBuffer.append(TEXT_558); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")); >- stringBuffer.append(TEXT_510); >+ stringBuffer.append(TEXT_559); > stringBuffer.append(constraint); >- stringBuffer.append(TEXT_511); >+ stringBuffer.append(TEXT_560); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_512); >+ stringBuffer.append(TEXT_561); > stringBuffer.append(context); >- stringBuffer.append(TEXT_513); >+ stringBuffer.append(TEXT_562); > stringBuffer.append(genModel.getNonNLS()); > stringBuffer.append(genModel.getNonNLS(2)); >- stringBuffer.append(TEXT_514); >+ stringBuffer.append(TEXT_563); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_515); >+ stringBuffer.append(TEXT_564); > } >- stringBuffer.append(TEXT_516); >+ stringBuffer.append(TEXT_565); > stringBuffer.append(delegate); >- stringBuffer.append(TEXT_517); >+ stringBuffer.append(TEXT_566); > stringBuffer.append(constraintDelegate.getName()); >- stringBuffer.append(TEXT_518); >+ stringBuffer.append(TEXT_567); > stringBuffer.append(constraint); >- stringBuffer.append(TEXT_519); >+ stringBuffer.append(TEXT_568); > stringBuffer.append(cast); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_520); >+ stringBuffer.append(TEXT_569); > stringBuffer.append(diagnostics); >- stringBuffer.append(TEXT_521); >+ stringBuffer.append(TEXT_570); > stringBuffer.append(context); >- stringBuffer.append(TEXT_522); >+ stringBuffer.append(TEXT_571); > } else { GenOperation genOperation = ((GenClass)genClassifier).getInvariantOperation(constraint); if (genOperation != null) { >- stringBuffer.append(TEXT_523); >+ stringBuffer.append(TEXT_572); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_524); >+ stringBuffer.append(TEXT_573); > stringBuffer.append(constraint); >- stringBuffer.append(TEXT_525); >+ stringBuffer.append(TEXT_574); > stringBuffer.append(diagnostics); >- stringBuffer.append(TEXT_526); >+ stringBuffer.append(TEXT_575); > stringBuffer.append(context); >- stringBuffer.append(TEXT_527); >+ stringBuffer.append(TEXT_576); > } else { >- stringBuffer.append(TEXT_528); >+ if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF26_VALUE && genClassifier.hasValidationExpression(constraint)) { >+ stringBuffer.append(TEXT_577); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")); >+ stringBuffer.append(TEXT_578); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_579); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.EValidator.ValidationDelegate")); >+ stringBuffer.append(TEXT_580); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.URI")); >+ stringBuffer.append(TEXT_581); >+ stringBuffer.append(genClassifier.getValidationDelegate(constraint)); >+ stringBuffer.append(TEXT_582); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_583); >+ stringBuffer.append(genClassifier.getClassifierID()); >+ stringBuffer.append(TEXT_584); >+ stringBuffer.append(CodeGenUtil.upperName(constraint)); >+ stringBuffer.append(TEXT_585); >+ stringBuffer.append(genClassifier.getQualifiedClassifierAccessor()); >+ stringBuffer.append(TEXT_586); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_587); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_588); > stringBuffer.append(diagnostics); >- stringBuffer.append(TEXT_529); >+ stringBuffer.append(TEXT_589); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(TEXT_590); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_591); >+ stringBuffer.append(constraint); >+ stringBuffer.append(TEXT_592); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_593); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_594); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_595); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_596); >+ stringBuffer.append(genModel.getImportedName("java.lang.Throwable")); >+ stringBuffer.append(TEXT_597); > stringBuffer.append(diagnostics); >- stringBuffer.append(TEXT_530); >+ stringBuffer.append(TEXT_598); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(TEXT_599); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_600); >+ stringBuffer.append(constraint); >+ stringBuffer.append(TEXT_601); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_602); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_603); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_604); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_605); >+ stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_606); >+ stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >+ stringBuffer.append(TEXT_607); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(TEXT_608); >+ stringBuffer.append(constraint); >+ stringBuffer.append(TEXT_609); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_610); >+ stringBuffer.append(context); >+ stringBuffer.append(TEXT_611); >+ stringBuffer.append(genClassifier.getValidationDelegate(constraint)); >+ stringBuffer.append(TEXT_612); >+ stringBuffer.append(genModel.getNonNLS()); >+ stringBuffer.append(genModel.getNonNLS(2)); >+ stringBuffer.append(TEXT_613); >+ stringBuffer.append(genClassifier.getSafeUncapName()); >+ stringBuffer.append(TEXT_614); >+ } else { >+ stringBuffer.append(TEXT_615); >+ stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_616); >+ stringBuffer.append(diagnostics); >+ stringBuffer.append(TEXT_617); > if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE) { >- stringBuffer.append(TEXT_531); >+ stringBuffer.append(TEXT_618); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >- stringBuffer.append(TEXT_532); >+ stringBuffer.append(TEXT_619); > stringBuffer.append(genModel.getNonNLS()); >- stringBuffer.append(TEXT_533); >+ stringBuffer.append(TEXT_620); > stringBuffer.append(constraint); >- stringBuffer.append(TEXT_534); >+ stringBuffer.append(TEXT_621); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_535); >+ stringBuffer.append(TEXT_622); > stringBuffer.append(context); >- stringBuffer.append(TEXT_536); >+ stringBuffer.append(TEXT_623); > stringBuffer.append(genModel.getNonNLS()); >- stringBuffer.append(TEXT_537); >+ stringBuffer.append(TEXT_624); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_538); >+ stringBuffer.append(TEXT_625); > } else { >- stringBuffer.append(TEXT_539); >+ stringBuffer.append(TEXT_626); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.BasicDiagnostic")); >- stringBuffer.append(TEXT_540); >+ stringBuffer.append(TEXT_627); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.Diagnostic")); >- stringBuffer.append(TEXT_541); >+ stringBuffer.append(TEXT_628); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.ecore.plugin.EcorePlugin")); >- stringBuffer.append(TEXT_542); >+ stringBuffer.append(TEXT_629); > stringBuffer.append(constraint); >- stringBuffer.append(TEXT_543); >+ stringBuffer.append(TEXT_630); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_544); >+ stringBuffer.append(TEXT_631); > stringBuffer.append(context); >- stringBuffer.append(TEXT_545); >+ stringBuffer.append(TEXT_632); > stringBuffer.append(genModel.getNonNLS()); > stringBuffer.append(genModel.getNonNLS(2)); >- stringBuffer.append(TEXT_546); >+ stringBuffer.append(TEXT_633); > stringBuffer.append(genClassifier.getSafeUncapName()); >- stringBuffer.append(TEXT_547); >+ stringBuffer.append(TEXT_634); >+ } >+ stringBuffer.append(TEXT_635); > } >- stringBuffer.append(TEXT_548); > }} >- stringBuffer.append(TEXT_549); >+ stringBuffer.append(TEXT_636); > } > } > if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE) { >- stringBuffer.append(TEXT_550); >+ stringBuffer.append(TEXT_637); > if (genModel.useClassOverrideAnnotation()) { >- stringBuffer.append(TEXT_551); >+ stringBuffer.append(TEXT_638); > } >- stringBuffer.append(TEXT_552); >+ stringBuffer.append(TEXT_639); > stringBuffer.append(genModel.getImportedName("org.eclipse.emf.common.util.ResourceLocator")); >- stringBuffer.append(TEXT_553); >+ stringBuffer.append(TEXT_640); > if (genModel.hasModelPluginClass()) { >- stringBuffer.append(TEXT_554); >+ stringBuffer.append(TEXT_641); > stringBuffer.append(genModel.getImportedName(genModel.getQualifiedModelPluginClassName())); >- stringBuffer.append(TEXT_555); >+ stringBuffer.append(TEXT_642); > } else { >- stringBuffer.append(TEXT_556); >+ stringBuffer.append(TEXT_643); > } >- stringBuffer.append(TEXT_557); >+ stringBuffer.append(TEXT_644); > } >- stringBuffer.append(TEXT_558); >+ stringBuffer.append(TEXT_645); > stringBuffer.append(genPackage.getValidatorClassName()); > genModel.emitSortedImports(); >- stringBuffer.append(TEXT_559); >+ stringBuffer.append(TEXT_646); > return stringBuffer.toString(); > } > } >#P org.eclipse.emf.codegen.ecore.ui >Index: plugin.properties >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen.ecore.ui/plugin.properties,v >retrieving revision 1.76 >diff -u -r1.76 plugin.properties >--- plugin.properties 18 Apr 2009 11:38:07 -0000 1.76 >+++ plugin.properties 8 Sep 2009 17:31:24 -0000 >@@ -1,7 +1,7 @@ > # /** > # * <copyright> > # * >-# * Copyright (c) 2002-2008 IBM Corporation and others. >+# * Copyright (c) 2002-2009 IBM Corporation and others. > # * All rights reserved. This program and the accompanying materials > # * are made available under the terms of the Eclipse Public License v1.0 > # * which accompanies this distribution, and is available at >@@ -385,6 +385,7 @@ > _UI_GenRuntimeVersion_EMF23_literal = 2.3 > _UI_GenRuntimeVersion_EMF24_literal = 2.4 > _UI_GenRuntimeVersion_EMF25_literal = 2.5 >+_UI_GenRuntimeVersion_EMF26_literal = 2.6 > _UI_GenPackage_contentTypeIdentifier_feature = Content Type Identifier > _UI_GenPackage_contentTypeIdentifier_description = A content type identifier against which to register this model's resource factory > _UI_GenPackage_fileExtensions_feature = File Extensions >#P org.eclipse.emf.ecore >Index: src/org/eclipse/emf/ecore/util/Diagnostician.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.ecore/src/org/eclipse/emf/ecore/util/Diagnostician.java,v >retrieving revision 1.10 >diff -u -r1.10 Diagnostician.java >--- src/org/eclipse/emf/ecore/util/Diagnostician.java 20 Feb 2009 12:44:50 -0000 1.10 >+++ src/org/eclipse/emf/ecore/util/Diagnostician.java 8 Sep 2009 17:31:26 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2004-2006 IBM Corporation and others. >+ * Copyright (c) 2004-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -160,8 +160,7 @@ > } > } > boolean circular = context.get(EObjectValidator.ROOT_OBJECT) == eObject; >- @SuppressWarnings("null") >- boolean result = ((EValidator)eValidator).validate(eClass, eObject, diagnostics, context); >+ boolean result = ((EValidator)eValidator).validate(eObject.eClass(), eObject, diagnostics, context); > if ((result || diagnostics != null) && !circular) > { > result &= doValidateContents(eObject, diagnostics, context); >Index: src/org/eclipse/emf/ecore/util/EcoreUtil.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.ecore/src/org/eclipse/emf/ecore/util/EcoreUtil.java,v >retrieving revision 1.67 >diff -u -r1.67 EcoreUtil.java >--- src/org/eclipse/emf/ecore/util/EcoreUtil.java 3 Jul 2009 15:41:08 -0000 1.67 >+++ src/org/eclipse/emf/ecore/util/EcoreUtil.java 8 Sep 2009 17:31:31 -0000 >@@ -4087,6 +4087,34 @@ > } > } > >+ public static boolean isInvariant(EOperation eOperation) >+ { >+ return eOperation.getEType() == EcorePackage.Literals.EBOOLEAN >+ && eOperation.getEParameters().size() == 2 >+ && eOperation.getEParameters().get(0).getEType() == EcorePackage.Literals.EDIAGNOSTIC_CHAIN >+ && eOperation.getEParameters().get(1).getEType() == EcorePackage.Literals.EMAP; >+ } >+ >+ public static List<String> getValidationDelegates(EPackage ePackage) >+ { >+ EAnnotation eAnnotation = ePackage.getEAnnotation(EcorePackage.eNS_URI); >+ if (eAnnotation != null) >+ { >+ String validationDelegates = eAnnotation.getDetails().get("validationDelegates"); >+ if (validationDelegates != null) >+ { >+ List<String> result = new ArrayList<String>(); >+ for (StringTokenizer stringTokenizer = new StringTokenizer(validationDelegates); stringTokenizer.hasMoreTokens();) >+ { >+ String validationDelegate = stringTokenizer.nextToken(); >+ result.add(validationDelegate); >+ } >+ return result; >+ } >+ } >+ return Collections.emptyList(); >+ } >+ > /* > static > { >Index: src/org/eclipse/emf/ecore/util/EObjectValidator.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.ecore/src/org/eclipse/emf/ecore/util/EObjectValidator.java,v >retrieving revision 1.30 >diff -u -r1.30 EObjectValidator.java >--- src/org/eclipse/emf/ecore/util/EObjectValidator.java 20 Feb 2009 12:44:50 -0000 1.30 >+++ src/org/eclipse/emf/ecore/util/EObjectValidator.java 8 Sep 2009 17:31:27 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2004-2007 IBM Corporation and others. >+ * Copyright (c) 2004-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -34,17 +34,18 @@ > import org.eclipse.emf.common.util.DiagnosticChain; > import org.eclipse.emf.common.util.EMap; > import org.eclipse.emf.common.util.ResourceLocator; >- >-import org.eclipse.emf.ecore.EValidator; >+import org.eclipse.emf.common.util.URI; > > import org.eclipse.emf.ecore.EAttribute; >-import org.eclipse.emf.ecore.EObject; > import org.eclipse.emf.ecore.EClass; >-import org.eclipse.emf.ecore.EReference; >-import org.eclipse.emf.ecore.EcorePackage; > import org.eclipse.emf.ecore.EDataType; >+import org.eclipse.emf.ecore.EObject; >+import org.eclipse.emf.ecore.EOperation; > import org.eclipse.emf.ecore.EPackage; >+import org.eclipse.emf.ecore.EReference; > import org.eclipse.emf.ecore.EStructuralFeature; >+import org.eclipse.emf.ecore.EValidator; >+import org.eclipse.emf.ecore.EcorePackage; > import org.eclipse.emf.ecore.InternalEObject; > > import org.eclipse.emf.ecore.plugin.EcorePlugin; >@@ -165,6 +166,20 @@ > return Diagnostician.INSTANCE; > } > >+ protected EValidator.ValidationDelegate.Registry getValidationDelegateRegistry(Map<Object, Object> context) >+ { >+ if (context != null) >+ { >+ EValidator.ValidationDelegate.Registry result = (EValidator.ValidationDelegate.Registry)context.get(EValidator.ValidationDelegate.Registry.class); >+ if (result != null) >+ { >+ return result; >+ } >+ } >+ >+ return EValidator.ValidationDelegate.Registry.INSTANCE; >+ } >+ > /** > * Validates the object in the given context, optionally producing diagnostics. > * @param diagnostics a place to accumulate diagnostics; if it's <code>null</code>, no diagnostics should be produced. >@@ -184,11 +199,11 @@ > } > else > { >- List<EClass> eSuperTypes = eClass.getESuperTypes(); >- return >- eSuperTypes.isEmpty() ? >- validate_EveryDefaultConstraint(eObject, diagnostics, context) : >- validate(eSuperTypes.get(0), eObject, diagnostics, context); >+ return new DynamicEClassValidator() >+ { >+ // Ensure that the class loader for this class will be used downstream. >+ // >+ }.validate(eClass, eObject, diagnostics, context); > } > } > >@@ -836,14 +851,72 @@ > } > } > >- public boolean validate(EDataType eDataType, Object value, DiagnosticChain diagnostics, Map<Object, Object> context) >+ protected boolean validateDelegatedConstraints(EDataType eDataType, Object value, DiagnosticChain diagnostics, Map<Object, Object> context) > { > boolean result = true; >+ >+ EValidator.ValidationDelegate.Registry registry = getValidationDelegateRegistry(context); >+ List<String> validationDelegates = EcoreUtil.getValidationDelegates(eDataType.getEPackage()); >+ >+ if (!validationDelegates.isEmpty()) >+ { >+ constraints: for (String constraint : EcoreUtil.getConstraints(eDataType)) >+ { >+ for (String uri : validationDelegates) >+ { >+ String expression = EcoreUtil.getAnnotation(eDataType, uri, constraint); >+ if (expression != null) >+ { >+ EValidator.ValidationDelegate delegate = registry.getValidationDelegate(URI.createURI(uri)); >+ if (delegate != null) >+ { >+ try >+ { >+ if (!delegate.validate(expression, eDataType, value, context)) >+ { >+ result &= false; >+ if (diagnostics != null) >+ { >+ reportConstraintDelegateViolation(eDataType, value, diagnostics, context, constraint); >+ } >+ else >+ { >+ break constraints; >+ } >+ } >+ } >+ catch (Throwable throwable) >+ { >+ result &= false; >+ if (diagnostics != null) >+ { >+ reportConstraintDelegateException(eDataType, value, diagnostics, context, constraint, throwable); >+ } >+ else >+ { >+ break constraints; >+ } >+ } >+ } >+ break; >+ } >+ } >+ } >+ } >+ >+ return result; >+ } >+ >+ protected boolean validateSchemaConstraints(EDataType eDataType, Object value, DiagnosticChain diagnostics, Map<Object, Object> context) >+ { >+ boolean result = true; >+ > if (effectiveEnumeration != null) > { > if (!effectiveEnumeration.contains(value)) > { >- if (diagnostics != null) reportEnumerationViolation(eDataType, value, effectiveEnumeration, diagnostics, context); >+ if (diagnostics != null) >+ reportEnumerationViolation(eDataType, value, effectiveEnumeration, diagnostics, context); > result = false; > } > } >@@ -855,10 +928,9 @@ > > if (effectiveMin != null) > { >- @SuppressWarnings("unchecked") Comparable<Object> comparableObject = (Comparable<Object>)effectiveMin; >- if (effectiveMinIsInclusive ? >- comparableObject.compareTo(value) > 0: >- comparableObject.compareTo(value) >= 0) >+ @SuppressWarnings("unchecked") >+ Comparable<Object> comparableObject = (Comparable<Object>)effectiveMin; >+ if (effectiveMinIsInclusive ? comparableObject.compareTo(value) > 0 : comparableObject.compareTo(value) >= 0) > { > if (diagnostics != null) > { >@@ -877,10 +949,9 @@ > > if (effectiveMax != null) > { >- @SuppressWarnings("unchecked") Comparable<Object> comparableObject = (Comparable<Object>)effectiveMax; >- if (effectiveMaxIsInclusive ? >- comparableObject.compareTo(value) < 0: >- comparableObject.compareTo(value) <= 0) >+ @SuppressWarnings("unchecked") >+ Comparable<Object> comparableObject = (Comparable<Object>)effectiveMax; >+ if (effectiveMaxIsInclusive ? comparableObject.compareTo(value) < 0 : comparableObject.compareTo(value) <= 0) > { > if (diagnostics != null) > { >@@ -944,40 +1015,196 @@ > result = false; > } > } >+ >+ return result; >+ } >+ >+ public boolean validate(EDataType eDataType, Object value, DiagnosticChain diagnostics, Map<Object, Object> context) >+ { >+ boolean result = validateDelegatedConstraints(eDataType, value, diagnostics, context); > >- if (itemType != null) >+ if (result || diagnostics != null) > { >- EValidator rootValidator = getRootEValidator(context); >- for (Iterator<?> i = ((List<?>)value).iterator(); i.hasNext() && (result || diagnostics != null); ) >+ result &= validateSchemaConstraints(eDataType, value, diagnostics, context); >+ >+ if (itemType != null) > { >- result &= rootValidator.validate(itemType, i.next(), diagnostics, context); >+ EValidator rootValidator = getRootEValidator(context); >+ for (Iterator< ? > i = ((List< ? >)value).iterator(); i.hasNext() && (result || diagnostics != null);) >+ { >+ result &= rootValidator.validate(itemType, i.next(), diagnostics, context); >+ } >+ return result; >+ } >+ else if (!memberTypes.isEmpty()) >+ { >+ EValidator rootValidator = getRootEValidator(context); >+ >+ for (EDataType memberType : memberTypes) >+ { >+ if (rootValidator.validate(memberType, value, null, context)) >+ { >+ return true; >+ } >+ } >+ for (EDataType memberType : memberTypes) >+ { >+ if (memberType.isInstance(value)) >+ { >+ return rootValidator.validate(memberType, value, diagnostics, context); >+ } >+ } >+ return false; >+ } >+ else >+ { >+ return result; > } >- return result; > } >- else if (!memberTypes.isEmpty()) >+ >+ return result; >+ } >+ } >+ >+ public class DynamicEClassValidator >+ { >+ protected boolean validateDelegatedInvariants(EClass eClass, EObject eObject, DiagnosticChain diagnostics, Map<Object, Object> context) >+ { >+ boolean result = true; >+ >+ EValidator.ValidationDelegate.Registry registry = getValidationDelegateRegistry(context); >+ List<String> validationDelegates = EcoreUtil.getValidationDelegates(eClass.getEPackage()); >+ >+ if (!validationDelegates.isEmpty()) > { >- EValidator rootValidator = getRootEValidator(context); >- >- for (EDataType memberType : memberTypes) >+ invariants: for (EOperation eOperation : eClass.getEOperations()) > { >- if (rootValidator.validate(memberType, value, null, context)) >+ if (EcoreUtil.isInvariant(eOperation)) > { >- return true; >+ for (String uri : validationDelegates) >+ { >+ String expression = EcoreUtil.getAnnotation(eOperation, uri, "body"); >+ if (expression != null) >+ { >+ EValidator.ValidationDelegate delegate = registry.getValidationDelegate(URI.createURI(uri)); >+ if (delegate != null) >+ { >+ try >+ { >+ if (!delegate.validate(expression, eClass, eObject, context)) >+ { >+ result &= false; >+ if (diagnostics != null) >+ { >+ reportInvariantDelegateViolation(eClass, eObject, diagnostics, context, eOperation); >+ } >+ else >+ { >+ break invariants; >+ } >+ } >+ } >+ catch (Throwable throwable) >+ { >+ result &= false; >+ if (diagnostics != null) >+ { >+ reportInvariantDelegateException(eClass, eObject, diagnostics, context, eOperation, throwable); >+ } >+ else >+ { >+ break invariants; >+ } >+ } >+ } >+ break; >+ } >+ } > } > } >- for (EDataType memberType : memberTypes) >+ } >+ >+ return result; >+ } >+ >+ protected boolean validateDelegatedConstraints(EClass eClass, EObject eObject, DiagnosticChain diagnostics, Map<Object, Object> context) >+ { >+ boolean result = true; >+ >+ EValidator.ValidationDelegate.Registry registry = getValidationDelegateRegistry(context); >+ List<String> validationDelegates = EcoreUtil.getValidationDelegates(eClass.getEPackage()); >+ >+ if (!validationDelegates.isEmpty()) >+ { >+ constraints: for (String constraint : EcoreUtil.getConstraints(eClass)) > { >- if (memberType.isInstance(value)) >+ for (String uri : validationDelegates) > { >- return rootValidator.validate(memberType, value, diagnostics, context); >+ String expression = EcoreUtil.getAnnotation(eClass, uri, constraint); >+ if (expression != null) >+ { >+ EValidator.ValidationDelegate delegate = registry.getValidationDelegate(URI.createURI(uri)); >+ if (delegate != null) >+ { >+ try >+ { >+ if (!delegate.validate(expression, eClass, eObject, context)) >+ { >+ result &= false; >+ if (diagnostics != null) >+ { >+ reportConstraintDelegateViolation(eClass, eObject, diagnostics, context, constraint); >+ } >+ else >+ { >+ break constraints; >+ } >+ } >+ } >+ catch (Throwable throwable) >+ { >+ result &= false; >+ if (diagnostics != null) >+ { >+ reportConstraintDelegateException(eClass, eObject, diagnostics, context, constraint, throwable); >+ } >+ else >+ { >+ break constraints; >+ } >+ } >+ } >+ else >+ { >+ reportConstraintDelegateNotFound(eClass, eObject, diagnostics, context, constraint, uri); >+ } >+ break; >+ } > } > } >- return false; > } >- else >+ >+ return result; >+ } >+ >+ public boolean validate(EClass eClass, EObject eObject, DiagnosticChain diagnostics, Map<Object, Object> context) >+ { >+ boolean result = validateDelegatedInvariants(eClass, eObject, diagnostics, context); >+ >+ if (result || diagnostics != null) > { >- return result; >+ result &= validateDelegatedConstraints(eClass, eObject, diagnostics, context); >+ >+ if (result || diagnostics != null) >+ { >+ List<EClass> eSuperTypes = eClass.getESuperTypes(); >+ result &= eSuperTypes.isEmpty() ? >+ validate_EveryDefaultConstraint(eObject, diagnostics, context) : >+ validate(eSuperTypes.get(0), eObject, diagnostics, context); >+ } > } >+ >+ return result; > } > } > >@@ -1202,6 +1429,123 @@ > context)); > } > >+ protected void reportConstraintDelegateViolation(EDataType eDataType, Object value, DiagnosticChain diagnostics, Map<Object, Object> context, String constraint) >+ { >+ diagnostics.add >+ (createDiagnostic >+ (Diagnostic.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_GenericConstraint_diagnostic", >+ new Object []{ constraint, getValueLabel(eDataType, value, context) }, >+ new Object []{ value }, >+ context)); >+ } >+ >+ protected void reportConstraintDelegateException(EDataType eDataType, Object value, DiagnosticChain diagnostics, Map<Object, Object> context, String constraint, Throwable throwable) >+ { >+ diagnostics.add >+ (createDiagnostic >+ (Diagnostic.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_ConstraintDelegateException_diagnostic", >+ new Object []{ constraint, getValueLabel(eDataType, value, context), throwable.getLocalizedMessage() }, >+ new Object []{ value }, >+ context)); >+ } >+ >+ protected void reportConstraintDelegateNotFound(EDataType eDataType, Object value, DiagnosticChain diagnostics, Map<Object, Object> context, String constraint, String uri) >+ { >+ diagnostics.add >+ (createDiagnostic >+ (Diagnostic.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_ConstraintDelegateNotFound_diagnostic", >+ new Object []{ constraint, getValueLabel(eDataType, value, context), uri }, >+ new Object []{ value }, >+ context)); >+ } >+ >+ protected void reportConstraintDelegateViolation(EClass eClass, EObject eObject, DiagnosticChain diagnostics, Map<Object, Object> context, String constraint) >+ { >+ diagnostics.add >+ (createDiagnostic >+ (Diagnostic.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_GenericConstraint_diagnostic", >+ new Object []{ constraint, getObjectLabel(eObject, context) }, >+ new Object []{ eObject }, >+ context)); >+ } >+ >+ protected void reportConstraintDelegateException(EClass eClass, EObject eObject, DiagnosticChain diagnostics, Map<Object, Object> context, String constraint, Throwable throwable) >+ { >+ diagnostics.add >+ (createDiagnostic >+ (Diagnostic.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_ConstraintDelegateException_diagnostic", >+ new Object []{ constraint, getObjectLabel(eObject, context), throwable.getLocalizedMessage() }, >+ new Object []{ eObject }, >+ context)); >+ } >+ >+ protected void reportConstraintDelegateNotFound(EClass eClass, EObject eObject, DiagnosticChain diagnostics, Map<Object, Object> context, String constraint, String uri) >+ { >+ diagnostics.add >+ (createDiagnostic >+ (Diagnostic.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_ConstraintDelegateNotFound_diagnostic", >+ new Object []{ constraint, getObjectLabel(eObject, context), uri }, >+ new Object []{ eObject }, >+ context)); >+ } >+ >+ protected void reportInvariantDelegateViolation(EClass eClass, EObject eObject, DiagnosticChain diagnostics, Map<Object, Object> context, EOperation invariant) >+ { >+ diagnostics.add >+ (createDiagnostic >+ (Diagnostic.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_GenericInvariant_diagnostic", >+ new Object []{ invariant.getName(), getObjectLabel(eObject, context) }, >+ new Object []{ eObject }, >+ context)); >+ } >+ >+ protected void reportInvariantDelegateException(EClass eClass, EObject eObject, DiagnosticChain diagnostics, Map<Object, Object> context, EOperation invariant, Throwable throwable) >+ { >+ diagnostics.add >+ (createDiagnostic >+ (Diagnostic.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_InvariantDelegateException_diagnostic", >+ new Object []{ invariant.getName(), getObjectLabel(eObject, context), throwable.getLocalizedMessage() }, >+ new Object []{ eObject }, >+ context)); >+ } >+ >+ protected void reportInvariantDelegateNotFound(EClass eClass, EObject eObject, DiagnosticChain diagnostics, Map<Object, Object> context, EOperation invariant, String uri) >+ { >+ diagnostics.add >+ (createDiagnostic >+ (Diagnostic.ERROR, >+ DIAGNOSTIC_SOURCE, >+ 0, >+ "_UI_InvariantDelegateNotFound_diagnostic", >+ new Object []{ invariant.getName(), getObjectLabel(eObject, context), uri }, >+ new Object []{ eObject }, >+ context)); >+ } >+ > protected static Collection<Object> wrapEnumerationValues(Object [] values) > { > return java.util.Arrays.asList(values); >@@ -1470,6 +1814,13 @@ > return EcorePlugin.INSTANCE; > } > >+ protected boolean isEcoreString(String key) >+ { >+ return "_UI_GenericConstraint_diagnostic".equals(key) || "_UI_GenericInvariant_diagnostic".equals(key) >+ || "_UI_ConstraintDelegateException_diagnostic".equals(key) || "_UI_InvariantDelegateException_diagnostic".equals(key) >+ || "_UI_ConstraintDelegateNotFound_diagnostic".equals(key) || "_UI_InvariantDelegateNotFound_diagnostic".equals(key); >+ } >+ > /** > * Returns a translated message with the given substitutions. > * The {@link #getResourceLocator() resource locator} is used. >@@ -1480,7 +1831,7 @@ > */ > protected String getString(String key, Object [] substitutions) > { >- return getString("_UI_GenericConstraint_diagnostic".equals(key) ? getEcoreResourceLocator() : getResourceLocator(), key, substitutions); >+ return getString(isEcoreString(key) ? getEcoreResourceLocator() : getResourceLocator(), key, substitutions); > } > > /** >Index: plugin.xml >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.ecore/plugin.xml,v >retrieving revision 1.23 >diff -u -r1.23 plugin.xml >--- plugin.xml 17 Mar 2009 13:09:13 -0000 1.23 >+++ plugin.xml 8 Sep 2009 17:31:25 -0000 >@@ -10,6 +10,7 @@ > <extension-point id="content_handler" name="%_UI_ContentHandlerRegistry_extensionpoint" schema="schema/content_handler.exsd"/> > <extension-point id="uri_mapping" name="%_UI_URIMappingRegistry_extensionpoint" schema="schema/uri_mapping.exsd"/> > <extension-point id="package_registry_implementation" name="%_UI_PackageRegistryImplementation_extensionpoint" schema="schema/package_registry_implementation.exsd"/> >+ <extension-point id="validation_delegate" name="%_UI_ValidationDelegateRegistry_extensionpoint" schema="schema/validation_delegate.exsd"/> > > <extension point="org.eclipse.emf.ecore.generated_package"> > <package >Index: plugin.properties >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.ecore/plugin.properties,v >retrieving revision 1.35 >diff -u -r1.35 plugin.properties >--- plugin.properties 7 Apr 2009 18:58:12 -0000 1.35 >+++ plugin.properties 8 Sep 2009 17:31:25 -0000 >@@ -1,7 +1,7 @@ > # /** > # * <copyright> > # * >-# * Copyright (c) 2002-2008 IBM Corporation and others. >+# * Copyright (c) 2002-2009 IBM Corporation and others. > # * All rights reserved. This program and the accompanying materials > # * are made available under the terms of the Eclipse Public License v1.0 > # * which accompanies this distribution, and is available at >@@ -194,5 +194,11 @@ > _UI_EClassifierInstanceTypeNameExpectedSpace_diagnostic = Expecting '' '' at index {0} > _UI_EClassifierInstanceTypeNameUnexpectedSpace_diagnostic = Unexpected '' '' at index {0} > >+_UI_InvariantDelegateException_diagnostic = An exception occurred while delegating evaluation of the ''{0}'' invariant on ''{1}'': {2} >+_UI_InvariantDelegateNotFound_diagnostic = Unable to find delegate to evaluate the ''{0}'' invariant on ''{1}'': {2} >+ >+_UI_ConstraintDelegateException_diagnostic = An exception occurred while delegating evaluation of the ''{0}'' constraint on ''{1}'': {2} >+_UI_ConstraintDelegateNotFound_diagnostic = Unable to find delegate to evaluate the ''{0}'' constraint on ''{1}'': {2} >+ > # This is in org.eclipse.emf.ecore.xmi > #_UI_Ecore_content_type = Ecore File >Index: src/org/eclipse/emf/ecore/plugin/EcorePlugin.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.ecore/src/org/eclipse/emf/ecore/plugin/EcorePlugin.java,v >retrieving revision 1.23 >diff -u -r1.23 EcorePlugin.java >--- src/org/eclipse/emf/ecore/plugin/EcorePlugin.java 2 Aug 2008 13:40:51 -0000 1.23 >+++ src/org/eclipse/emf/ecore/plugin/EcorePlugin.java 8 Sep 2009 17:31:26 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2002-2006 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -575,6 +575,7 @@ > new ContentParserRegistryReader().readRegistry(); > new ContentHandlerRegistryReader().readRegistry(); > new URIMappingRegistryReader().readRegistry(); >+ new ValidationDelegateRegistryReader().readRegistry(); > } > } > >@@ -631,4 +632,5 @@ > public static final String SCHEME_PARSER_PPID = "scheme_parser"; > public static final String URI_MAPPING_PPID = "uri_mapping"; > public static final String PACKAGE_REGISTRY_IMPLEMENTATION_PPID = "package_registry_implementation"; >+ public static final String VALIDATION_DELEGATE_PPID = "validation_delegate"; > } >\ No newline at end of file >Index: src/org/eclipse/emf/ecore/EValidator.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.ecore/src/org/eclipse/emf/ecore/EValidator.java,v >retrieving revision 1.8 >diff -u -r1.8 EValidator.java >--- src/org/eclipse/emf/ecore/EValidator.java 14 Jun 2007 18:32:46 -0000 1.8 >+++ src/org/eclipse/emf/ecore/EValidator.java 8 Sep 2009 17:31:25 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2004-2006 IBM Corporation and others. >+ * Copyright (c) 2004-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -20,6 +20,7 @@ > import java.util.Map; > > import org.eclipse.emf.common.util.DiagnosticChain; >+import org.eclipse.emf.common.util.URI; > > > /** >@@ -117,6 +118,55 @@ > } > > /** >+ * An interface for delegating validation expression evaluation. >+ * @since 2.6 >+ */ >+ interface ValidationDelegate >+ { >+ /** >+ * A <code>ValidationDelegate</code> wrapper that is used by the {@link ValidationDelegate.Registry}. >+ */ >+ public interface Descriptor >+ { >+ /** >+ * Returns the validation delegate. >+ * @return the validation delegate. >+ */ >+ ValidationDelegate getValidationDelegate(); >+ } >+ >+ /** >+ * A map from {@link org.eclipse.emf.common.util.URI URI} to {@link ValidationDelegate}. >+ */ >+ interface Registry extends Map<URI, Object> >+ { >+ /** >+ * Looks up the validation delegate in the map. >+ */ >+ ValidationDelegate getValidationDelegate(URI uri); >+ >+ /** >+ * The global instance of a validation delegate registry. >+ */ >+ Registry INSTANCE = new org.eclipse.emf.ecore.impl.ValidationDelegateRegistryImpl(); >+ } >+ >+ /** >+ * Evaluates the given validation expression against the object in the given context. >+ * @param context a place to cache information, if it's <code>null</code>, no cache is supported. >+ * @return the result of the expression evaluation. >+ */ >+ boolean validate(String expression, EClass eClass, EObject eObject, Map<Object, Object> context); >+ >+ /** >+ * Evaluates the expression against the value in the given context. >+ * @param context a place to cache information, if it's <code>null</code>, no cache is supported. >+ * @return the result of the expression evaluation. >+ */ >+ boolean validate(String expression, EDataType eDataType, Object value, Map<Object, Object> context); >+ } >+ >+ /** > * Validates the object in the given context, optionally producing diagnostics. > * @param diagnostics a place to accumulate diagnostics; if it's <code>null</code>, no diagnostics should be produced. > * @param context a place to cache information, if it's <code>null</code>, no cache is supported. >Index: src/org/eclipse/emf/ecore/plugin/ValidationDelegateRegistryReader.java >=================================================================== >RCS file: src/org/eclipse/emf/ecore/plugin/ValidationDelegateRegistryReader.java >diff -N src/org/eclipse/emf/ecore/plugin/ValidationDelegateRegistryReader.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/emf/ecore/plugin/ValidationDelegateRegistryReader.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,94 @@ >+/** >+ * <copyright> >+ * >+ * Copyright (c) 2009 Kenn Hussey and others. >+ * All rights reserved. This program and the accompanying materials >+ * are made available under the terms of the Eclipse Public License v1.0 >+ * which accompanies this distribution, and is available at >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * Kenn Hussey - Initial API and implementation >+ * >+ * </copyright> >+ * >+ * $Id$ >+ */ >+package org.eclipse.emf.ecore.plugin; >+ >+import org.eclipse.core.runtime.IConfigurationElement; >+import org.eclipse.core.runtime.Platform; >+ >+import org.eclipse.emf.common.util.URI; >+import org.eclipse.emf.ecore.EValidator; >+ >+ >+/** >+ * A plugin extension reader that populates the >+ * {@link org.eclipse.emf.ecore.EValidator.ValidationDelegate.Registry#INSTANCE global} validation delegate registry. >+ * Clients are not expected to use this class directly. >+ */ >+class ValidationDelegateRegistryReader extends RegistryReader >+{ >+ static class ValidationDelegateDescriptor extends PluginClassDescriptor implements EValidator.ValidationDelegate.Descriptor >+ { >+ protected EValidator.ValidationDelegate validationDelegate; >+ >+ public ValidationDelegateDescriptor(IConfigurationElement e, String attrName) >+ { >+ super(e, attrName); >+ } >+ >+ public EValidator.ValidationDelegate getValidationDelegate() >+ { >+ if (validationDelegate == null) >+ { >+ validationDelegate = (EValidator.ValidationDelegate)createInstance(); >+ } >+ return validationDelegate; >+ } >+ } >+ >+ static final String TAG_DELEGATE = "delegate"; >+ static final String ATT_URI = "uri"; >+ static final String ATT_CLASS = "class"; >+ >+ public ValidationDelegateRegistryReader() >+ { >+ super(Platform.getExtensionRegistry(), EcorePlugin.getPlugin().getBundle().getSymbolicName(), EcorePlugin.VALIDATION_DELEGATE_PPID); >+ } >+ >+ @Override >+ protected boolean readElement(IConfigurationElement element, boolean add) >+ { >+ if (element.getName().equals(TAG_DELEGATE)) >+ { >+ String uri = element.getAttribute(ATT_URI); >+ if (uri == null) >+ { >+ logMissingAttribute(element, ATT_URI); >+ } >+ else if (element.getAttribute(ATT_CLASS) == null) >+ { >+ logMissingAttribute(element, ATT_CLASS); >+ } >+ else if (add) >+ { >+ Object previous = EValidator.ValidationDelegate.Registry.INSTANCE.put(URI.createURI(uri), new ValidationDelegateDescriptor(element, ATT_CLASS)); >+ if (previous instanceof ValidationDelegateDescriptor) >+ { >+ ValidationDelegateDescriptor descriptor = (ValidationDelegateDescriptor)previous; >+ EcorePlugin.INSTANCE.log("Both '" + descriptor.element.getContributor().getName() + "' and '" + element.getContributor().getName() + "' register a validation delegate for '" + uri + "'"); >+ } >+ return true; >+ } >+ else >+ { >+ EValidator.ValidationDelegate.Registry.INSTANCE.remove(uri); >+ return true; >+ } >+ } >+ >+ return false; >+ } >+} >Index: src/org/eclipse/emf/ecore/impl/ValidationDelegateRegistryImpl.java >=================================================================== >RCS file: src/org/eclipse/emf/ecore/impl/ValidationDelegateRegistryImpl.java >diff -N src/org/eclipse/emf/ecore/impl/ValidationDelegateRegistryImpl.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/emf/ecore/impl/ValidationDelegateRegistryImpl.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,85 @@ >+/** >+ * <copyright> >+ * >+ * Copyright (c) 2009 Kenn Hussey and others. >+ * All rights reserved. This program and the accompanying materials >+ * are made available under the terms of the Eclipse Public License v1.0 >+ * which accompanies this distribution, and is available at >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * Kenn Hussey - Initial API and implementation >+ * >+ * </copyright> >+ * >+ * $Ids$ >+ */ >+package org.eclipse.emf.ecore.impl; >+ >+import java.util.HashMap; >+ >+import org.eclipse.emf.common.util.URI; >+import org.eclipse.emf.ecore.EValidator; >+ >+ >+/** >+ * An implementation of a validation delegate registry. >+ */ >+public class ValidationDelegateRegistryImpl extends HashMap<URI, Object> implements EValidator.ValidationDelegate.Registry >+{ >+ private static final long serialVersionUID = 1L; >+ >+ protected EValidator.ValidationDelegate.Registry delegateRegistry; >+ >+ public ValidationDelegateRegistryImpl() >+ { >+ super(); >+ } >+ >+ public ValidationDelegateRegistryImpl(EValidator.ValidationDelegate.Registry delegateRegistry) >+ { >+ this.delegateRegistry = delegateRegistry; >+ } >+ >+ @Override >+ public Object get(Object key) >+ { >+ Object validationDelegate = super.get(key); >+ if (validationDelegate instanceof EValidator.ValidationDelegate.Descriptor) >+ { >+ EValidator.ValidationDelegate.Descriptor validationDelegateDescriptor = (EValidator.ValidationDelegate.Descriptor)validationDelegate; >+ validationDelegate = validationDelegateDescriptor.getValidationDelegate(); >+ put((URI)key, validationDelegate); >+ return validationDelegate; >+ } >+ else if (validationDelegate != null) >+ { >+ return validationDelegate; >+ } >+ else >+ { >+ return delegatedGet(key); >+ } >+ } >+ >+ public EValidator.ValidationDelegate getValidationDelegate(URI uri) >+ { >+ return (EValidator.ValidationDelegate)get(uri); >+ } >+ >+ protected Object delegatedGet(Object key) >+ { >+ if (delegateRegistry != null) >+ { >+ return delegateRegistry.get(key); >+ } >+ >+ return null; >+ } >+ >+ @Override >+ public boolean containsKey(Object key) >+ { >+ return super.containsKey(key) || delegateRegistry != null && delegateRegistry.containsKey(key); >+ } >+} >Index: schema/validation_delegate.exsd >=================================================================== >RCS file: schema/validation_delegate.exsd >diff -N schema/validation_delegate.exsd >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ schema/validation_delegate.exsd 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,124 @@ >+<?xml version='1.0' encoding='UTF-8'?> >+<!-- Schema file written by PDE --> >+<schema targetNamespace="org.eclipse.emf.ecore" xmlns="http://www.w3.org/2001/XMLSchema"> >+<annotation> >+ <appInfo> >+ <meta.schema plugin="org.eclipse.emf.ecore" id="validation_delegate" name="Validation Delegate Registry"/> >+ </appInfo> >+ <documentation> >+ This extension point is used to define a validation delegate that evaluates expressions whose type is identified by a URI. The global EMF validation delegate registry, <samp>EValidator.ValidationDelegate.Factory.Registry.INSTANCE</samp>, is used to record the registration. >+ </documentation> >+ </annotation> >+ >+ <element name="extension"> >+ <annotation> >+ <appInfo> >+ <meta.element /> >+ </appInfo> >+ </annotation> >+ <complexType> >+ <sequence> >+ <element ref="delegate" minOccurs="1" maxOccurs="unbounded"/> >+ </sequence> >+ <attribute name="point" type="string" use="required"> >+ <annotation> >+ <documentation> >+ A fully qualified identifier of the target extension point. >+ </documentation> >+ </annotation> >+ </attribute> >+ <attribute name="id" type="string"> >+ <annotation> >+ <documentation> >+ An optional identifier of the extension instance. >+ </documentation> >+ </annotation> >+ </attribute> >+ <attribute name="name" type="string"> >+ <annotation> >+ <documentation> >+ An optional name of the extension instance. >+ </documentation> >+ </annotation> >+ </attribute> >+ </complexType> >+ </element> >+ >+ <element name="delegate"> >+ <annotation> >+ <appInfo> >+ <meta.element labelAttribute="uri"/> >+ </appInfo> >+ </annotation> >+ <complexType> >+ <attribute name="uri" type="string" use="required"> >+ <annotation> >+ <documentation> >+ A URI identifying the type of expressions that can be evaluated by the validation delegate. >+ </documentation> >+ </annotation> >+ </attribute> >+ <attribute name="class" type="string" use="required"> >+ <annotation> >+ <documentation> >+ The fully qualified name of a Java class implementing <samp>org.eclipse.emf.ecore.EValidator.ValidationDelegate</samp>. >+ </documentation> >+ <appInfo> >+ <meta.attribute kind="java" basedOn="org.eclipse.emf.ecore.EValidator.ValidationDelegate"/> >+ </appInfo> >+ </annotation> >+ </attribute> >+ </complexType> >+ </element> >+ >+ <annotation> >+ <appInfo> >+ <meta.section type="since"/> >+ </appInfo> >+ <documentation> >+ 2.6.0 >+ </documentation> >+ </annotation> >+ >+ <annotation> >+ <appInfo> >+ <meta.section type="examples"/> >+ </appInfo> >+ <documentation> >+ Following is an example of how a validation delegate can be registered: >+<pre> >+ <extension point="org.eclipse.emf.ecore.validation_delegate" > >+ <delegate uri="http://www.eclipse.org/ocl/3.0/OCL" class="org.eclipse.ocl.OCLValidationDelegate"/> >+ </extension> >+</pre> >+ </documentation> >+ </annotation> >+ >+ <annotation> >+ <appInfo> >+ <meta.section type="apiInfo"/> >+ </appInfo> >+ <documentation> >+ The value of the class attribute must represent a class that implements <samp>org.eclipse.emf.ecore.EValidator.ValidationDelegate</samp> and has a no argument contructor. >+<p> >+A validation delegate can be also registered from the source code with the <samp>EValidator.ValidationDelegate.Registry.INSTANCE</samp> as follows: >+</p> >+<pre> >+ EValidator.ValidationDelegate.Registry.INSTANCE.put(URI.createURI("http://www.eclipse.org/ocl/3.0/OCL"), new OCLValidationDelegate()); >+</pre> >+ </documentation> >+ </annotation> >+ >+ >+ <annotation> >+ <appInfo> >+ <meta.section type="copyright"/> >+ </appInfo> >+ <documentation> >+ Copyright (c) 2009 Kenn Hussey and others.<br> >+All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at <a >+href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a> >+ </documentation> >+ </annotation> >+ >+</schema> >#P org.eclipse.emf.codegen >Index: src/org/eclipse/emf/codegen/util/CodeGenUtil.java >=================================================================== >RCS file: /cvsroot/modeling/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.codegen/src/org/eclipse/emf/codegen/util/CodeGenUtil.java,v >retrieving revision 1.33 >diff -u -r1.33 CodeGenUtil.java >--- src/org/eclipse/emf/codegen/util/CodeGenUtil.java 21 Apr 2009 19:23:00 -0000 1.33 >+++ src/org/eclipse/emf/codegen/util/CodeGenUtil.java 8 Sep 2009 17:31:32 -0000 >@@ -1,7 +1,7 @@ > /** > * <copyright> > * >- * Copyright (c) 2002-2007 IBM Corporation and others. >+ * Copyright (c) 2002-2009 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -477,6 +477,22 @@ > } > > /** >+ * @since 2.6 >+ */ >+ public static String upperName(String name, Locale locale) >+ { >+ return format(name, '_', null, false, true).toUpperCase(locale); >+ } >+ >+ /** >+ * @since 2.6 >+ */ >+ public static String upperName(String name) >+ { >+ return upperName(name, Locale.getDefault()); >+ } >+ >+ /** > * @deprecated In 2.2. Please use {@link #format(String, char, String, boolean, boolean)} instead. > */ > @Deprecated
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 255786
:
118244
|
118245
|
118338
|
123880
|
123881
|
123883
|
123885
|
126724
|
126725
|
126726
|
126727
|
126729
|
146761
|
146762
|
146778
|
146787
|
147341
|
147449
|
147455
|
147479