Bug 442765 - Improve mechanism for DMR resolvement https://bugs.eclipse.org/bugs/show_bug.cgi?id=442765
diff --git a/bundles/org.eclipse.emf.ecp.view.label.model.edit/META-INF/MANIFEST.MF b/bundles/org.eclipse.emf.ecp.view.label.model.edit/META-INF/MANIFEST.MF index f3fe016..b81c55a 100644 --- a/bundles/org.eclipse.emf.ecp.view.label.model.edit/META-INF/MANIFEST.MF +++ b/bundles/org.eclipse.emf.ecp.view.label.model.edit/META-INF/MANIFEST.MF
@@ -8,8 +8,7 @@ Bundle-Vendor: %providerName Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -Export-Package: org.eclipse.emf.ecp.view.spi.label.model.provider;vers - ion="1.5.0" +Export-Package: org.eclipse.emf.ecp.view.spi.label.model.provider;version="1.5.0" Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.7.0,4.0.0)", org.eclipse.emf.edit;bundle-version="[2.8.0,3.0.0)";visibility:=reexport, org.eclipse.emf.ecore;bundle-version="[2.7.0,3.0.0)";visibility:=reexport,
diff --git a/bundles/org.eclipse.emf.ecp.view.label.model/META-INF/MANIFEST.MF b/bundles/org.eclipse.emf.ecp.view.label.model/META-INF/MANIFEST.MF index 96bcd1a..4997fe4 100644 --- a/bundles/org.eclipse.emf.ecp.view.label.model/META-INF/MANIFEST.MF +++ b/bundles/org.eclipse.emf.ecp.view.label.model/META-INF/MANIFEST.MF
@@ -7,9 +7,9 @@ Bundle-Vendor: %providerName Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -Export-Package: org.eclipse.emf.ecp.view.spi.label.model;version="1.5. - 0",org.eclipse.emf.ecp.view.spi.label.model.impl;version="1.5.0",org. - eclipse.emf.ecp.view.spi.label.model.util;version="1.5.0" +Export-Package: org.eclipse.emf.ecp.view.spi.label.model;version="1.5.0", + org.eclipse.emf.ecp.view.spi.label.model.impl;version="1.5.0", + org.eclipse.emf.ecp.view.spi.label.model.util;version="1.5.0" Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.7.0,4.0.0)", org.eclipse.emf.ecore;bundle-version="[2.7.0,3.0.0)";visibility:=reexport, org.eclipse.emf.ecp.view.model;bundle-version="[1.4.0,2.0.0)";visibility:=reexport
diff --git a/bundles/org.eclipse.emf.ecp.view.label.model/model/label.ecore b/bundles/org.eclipse.emf.ecp.view.label.model/model/label.ecore index 820ae66..2100869 100644 --- a/bundles/org.eclipse.emf.ecp.view.label.model/model/label.ecore +++ b/bundles/org.eclipse.emf.ecp.view.label.model/model/label.ecore
@@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8"?> <ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="label" nsURI="http://org/eclipse/emf/ecp/view/label/model" nsPrefix="org.eclipse.emf.ecp.view.label.model"> - <eClassifiers xsi:type="ecore:EClass" name="Label" eSuperTypes="../../org.eclipse.emf.ecp.view.model/model/view.ecore#//ContainedElement"> + <eClassifiers xsi:type="ecore:EClass" name="Label" eSuperTypes="../../org.eclipse.emf.ecp.view.model/model/view.ecore#//ContainedElement ../../org.eclipse.emf.ecp.view.model/model/view.ecore#//Resolvable"> <eStructuralFeatures xsi:type="ecore:EAttribute" name="style" eType="#//VLabelStyle"/> <eStructuralFeatures xsi:type="ecore:EReference" name="domainModelReference" eType="ecore:EClass ../../org.eclipse.emf.ecp.view.model/model/view.ecore#//DomainModelReference" containment="true"/>
diff --git a/bundles/org.eclipse.emf.ecp.view.label.model/model/label.history b/bundles/org.eclipse.emf.ecp.view.label.model/model/label.history index c9bb42d..3e9c39f 100644 --- a/bundles/org.eclipse.emf.ecp.view.label.model/model/label.history +++ b/bundles/org.eclipse.emf.ecp.view.label.model/model/label.history
@@ -138,5 +138,8 @@ </changes> </changes> </releases> - <releases/> + <releases> + <changes xsi:type="history:Add" element="label.ecore#//Label" featureName="eSuperTypes" + referenceValue="../../org.eclipse.emf.ecp.view.model/model/view.ecore#//Resolvable"/> + </releases> </history:History>
diff --git a/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/VLabel.java b/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/VLabel.java index 2a2b13f..2ff0d49 100644 --- a/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/VLabel.java +++ b/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/VLabel.java
@@ -13,6 +13,7 @@ import org.eclipse.emf.ecp.view.spi.model.VContainedElement; import org.eclipse.emf.ecp.view.spi.model.VDomainModelReference; +import org.eclipse.emf.ecp.view.spi.model.VResolvable; /** * <!-- begin-user-doc --> @@ -31,7 +32,7 @@ * @model * @generated */ -public interface VLabel extends VContainedElement +public interface VLabel extends VContainedElement, VResolvable { /** * Returns the value of the '<em><b>Style</b></em>' attribute. @@ -75,13 +76,11 @@ * * @since 1.4 * <!-- end-user-doc --> - * * @return the value of the '<em>Domain Model Reference</em>' containment reference. * @see #setDomainModelReference(VDomainModelReference) * @see org.eclipse.emf.ecp.view.spi.label.model.VLabelPackage#getLabel_DomainModelReference() * @model containment="true" * @generated - * */ VDomainModelReference getDomainModelReference(); @@ -92,7 +91,6 @@ * * @since 1.4 * <!-- end-user-doc --> - * * @param value the new value of the '<em>Domain Model Reference</em>' containment reference. * @see #getDomainModelReference() * @generated
diff --git a/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/impl/VLabelImpl.java b/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/impl/VLabelImpl.java index e4ebc55..6b60b35 100644 --- a/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/impl/VLabelImpl.java +++ b/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/impl/VLabelImpl.java
@@ -13,6 +13,8 @@ import org.eclipse.emf.common.notify.Notification; import org.eclipse.emf.common.notify.NotificationChain; +import org.eclipse.emf.common.util.BasicEList; +import org.eclipse.emf.common.util.EList; import org.eclipse.emf.ecore.EClass; import org.eclipse.emf.ecore.InternalEObject; import org.eclipse.emf.ecore.impl.ENotificationImpl; @@ -68,7 +70,6 @@ * * @since 1.4 * <!-- end-user-doc --> - * * @see #getDomainModelReference() * @generated * @ordered @@ -131,7 +132,6 @@ * * @since 1.4 * <!-- end-user-doc --> - * * @generated */ @Override @@ -145,7 +145,6 @@ * * @since 1.4 * <!-- end-user-doc --> - * * @generated */ public NotificationChain basicSetDomainModelReference(VDomainModelReference newDomainModelReference, @@ -171,7 +170,6 @@ * * @since 1.4 * <!-- end-user-doc --> - * * @generated */ @Override @@ -201,6 +199,23 @@ /** * <!-- begin-user-doc --> + * + * @since 1.5 + * <!-- end-user-doc --> + * + * @generated NOT + * @return the {@link VDomainModelReference references} to resolve + */ + @Override + public EList<VDomainModelReference> getDomainModelReferencesToResolve() + { + final EList<VDomainModelReference> result = new BasicEList<VDomainModelReference>(); + result.add(getDomainModelReference()); + return result; + } + + /** + * <!-- begin-user-doc -->. * <!-- end-user-doc --> * * @generated
diff --git a/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/util/LabelAdapterFactory.java b/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/util/LabelAdapterFactory.java index ea854eb..285e1b4 100644 --- a/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/util/LabelAdapterFactory.java +++ b/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/util/LabelAdapterFactory.java
@@ -19,6 +19,7 @@ import org.eclipse.emf.ecp.view.spi.label.model.VLabelPackage; import org.eclipse.emf.ecp.view.spi.model.VContainedElement; import org.eclipse.emf.ecp.view.spi.model.VElement; +import org.eclipse.emf.ecp.view.spi.model.VResolvable; /** * <!-- begin-user-doc --> @@ -108,6 +109,12 @@ } @Override + public Adapter caseResolvable(VResolvable object) + { + return createResolvableAdapter(); + } + + @Override public Adapter defaultCase(EObject object) { return createEObjectAdapter(); @@ -181,6 +188,23 @@ } /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VResolvable + * <em>Resolvable</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * + * @return the new adapter. + * @see org.eclipse.emf.ecp.view.spi.model.VResolvable + * @generated + */ + public Adapter createResolvableAdapter() + { + return null; + } + + /** * Creates a new adapter for the default case. * <!-- begin-user-doc --> * This default implementation returns null.
diff --git a/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/util/LabelSwitch.java b/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/util/LabelSwitch.java index eecf497..6bab8a2 100644 --- a/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/util/LabelSwitch.java +++ b/bundles/org.eclipse.emf.ecp.view.label.model/src/org/eclipse/emf/ecp/view/spi/label/model/util/LabelSwitch.java
@@ -18,6 +18,7 @@ import org.eclipse.emf.ecp.view.spi.label.model.VLabelPackage; import org.eclipse.emf.ecp.view.spi.model.VContainedElement; import org.eclipse.emf.ecp.view.spi.model.VElement; +import org.eclipse.emf.ecp.view.spi.model.VResolvable; /** * <!-- begin-user-doc --> @@ -95,6 +96,9 @@ result = caseContainedElement(label); } if (result == null) { + result = caseResolvable(label); + } + if (result == null) { result = caseElement(label); } if (result == null) { @@ -159,6 +163,23 @@ } /** + * Returns the result of interpreting the object as an instance of '<em>Resolvable</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Resolvable</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseResolvable(VResolvable object) + { + return null; + } + + /** * Returns the result of interpreting the object as an instance of '<em>EObject</em>'. * <!-- begin-user-doc --> * This implementation returns null;
diff --git a/bundles/org.eclipse.emf.ecp.view.model.edit/META-INF/MANIFEST.MF b/bundles/org.eclipse.emf.ecp.view.model.edit/META-INF/MANIFEST.MF index ca3e43d..9211297 100644 --- a/bundles/org.eclipse.emf.ecp.view.model.edit/META-INF/MANIFEST.MF +++ b/bundles/org.eclipse.emf.ecp.view.model.edit/META-INF/MANIFEST.MF
@@ -8,8 +8,7 @@ Bundle-Vendor: %providerName Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -Export-Package: org.eclipse.emf.ecp.view.spi.model.provider;version="1 - .5.0" +Export-Package: org.eclipse.emf.ecp.view.spi.model.provider;version="1.5.0" Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.7.0,4.0.0)", org.eclipse.emf.ecp.view.model;bundle-version="[1.4.0,2.0.0)";visibility:=reexport, org.eclipse.emf.edit;bundle-version="[2.8.0,3.0.0)";visibility:=reexport,
diff --git a/bundles/org.eclipse.emf.ecp.view.model.edit/plugin.properties b/bundles/org.eclipse.emf.ecp.view.model.edit/plugin.properties index a0f7a7893..ce0b8bb 100644 --- a/bundles/org.eclipse.emf.ecp.view.model.edit/plugin.properties +++ b/bundles/org.eclipse.emf.ecp.view.model.edit/plugin.properties
@@ -154,3 +154,4 @@ _UI_DomainModelReference_changeListener_feature = Change Listener _UI_View_ecorePath_feature = Ecore Path _UI_ContainedContainer_type = Contained Container +_UI_Resolvable_type = Resolvable
diff --git a/bundles/org.eclipse.emf.ecp.view.model/.settings/.api_filters b/bundles/org.eclipse.emf.ecp.view.model/.settings/.api_filters index f1f8017..f19dffc 100644 --- a/bundles/org.eclipse.emf.ecp.view.model/.settings/.api_filters +++ b/bundles/org.eclipse.emf.ecp.view.model/.settings/.api_filters
@@ -55,6 +55,13 @@ <message_argument value="10"/> </message_arguments> </filter> + <filter id="388194388"> + <message_arguments> + <message_argument value="org.eclipse.emf.ecp.view.spi.model.VViewPackage"/> + <message_argument value="DOMAIN_MODEL_REFERENCE_CHANGE_LISTENER"/> + <message_argument value="11"/> + </message_arguments> + </filter> <filter comment="SPI change (1.3)" id="388194388"> <message_arguments> <message_argument value="org.eclipse.emf.ecp.view.spi.model.VViewPackage"/> @@ -83,6 +90,13 @@ <message_argument value="1"/> </message_arguments> </filter> + <filter id="388194388"> + <message_arguments> + <message_argument value="org.eclipse.emf.ecp.view.spi.model.VViewPackage"/> + <message_argument value="LABEL_ALIGNMENT"/> + <message_argument value="10"/> + </message_arguments> + </filter> <filter comment="SPI" id="388194388"> <message_arguments> <message_argument value="org.eclipse.emf.ecp.view.spi.model.VViewPackage"/> @@ -117,6 +131,12 @@ <message_argument value="DOMAIN_MODEL_REFERENCE__CHANGE_LISTENER"/> </message_arguments> </filter> + <filter id="403767336"> + <message_arguments> + <message_argument value="org.eclipse.emf.ecp.view.spi.model.VViewPackage.Literals"/> + <message_argument value="RESOLVABLE"/> + </message_arguments> + </filter> <filter comment="Internal Model Changes" id="403767336"> <message_arguments> <message_argument value="org.eclipse.emf.ecp.view.spi.model.VViewPackage.Literals"/>
diff --git a/bundles/org.eclipse.emf.ecp.view.model/model/view.ecore b/bundles/org.eclipse.emf.ecp.view.model/model/view.ecore index d7dcb16..eb909a4 100644 --- a/bundles/org.eclipse.emf.ecp.view.model/model/view.ecore +++ b/bundles/org.eclipse.emf.ecp.view.model/model/view.ecore
@@ -46,7 +46,7 @@ </eClassifiers> <eClassifiers xsi:type="ecore:EClass" name="ContainedContainer" abstract="true" eSuperTypes="#//ContainedElement #//Container"/> - <eClassifiers xsi:type="ecore:EClass" name="Control" eSuperTypes="#//ContainedElement"> + <eClassifiers xsi:type="ecore:EClass" name="Control" eSuperTypes="#//ContainedElement #//Resolvable"> <eStructuralFeatures xsi:type="ecore:EAttribute" name="labelAlignment" lowerBound="1" eType="#//LabelAlignment" defaultValueLiteral="Left"/> <eStructuralFeatures xsi:type="ecore:EReference" name="domainModelReference" lowerBound="1" @@ -58,4 +58,8 @@ </eClassifiers> <eClassifiers xsi:type="ecore:EDataType" name="DomainModelReferenceChangeListener" instanceClassName="org.eclipse.emf.ecp.view.spi.model.DomainModelReferenceChangeListener"/> + <eClassifiers xsi:type="ecore:EClass" name="Resolvable" abstract="true" interface="true"> + <eOperations name="getDomainModelReferencesToResolve" ordered="false" upperBound="-1" + eType="#//DomainModelReference"/> + </eClassifiers> </ecore:EPackage>
diff --git a/bundles/org.eclipse.emf.ecp.view.model/model/view.history b/bundles/org.eclipse.emf.ecp.view.model/model/view.history index 9674fa4..b05ef30 100644 --- a/bundles/org.eclipse.emf.ecp.view.model/model/view.history +++ b/bundles/org.eclipse.emf.ecp.view.model/model/view.history
@@ -283,5 +283,41 @@ </changes> </changes> </releases> - <releases/> + <releases> + <changes xsi:type="history:OperationChange"> + <changes xsi:type="history:Create" target="view.ecore#/" referenceName="eClassifiers" + element="view.ecore#//Resolvable"> + <changes xsi:type="history:Set" element="view.ecore#//Resolvable" featureName="name" + dataValue="Resolvable"/> + <changes xsi:type="history:Set" element="view.ecore#//Resolvable" featureName="abstract" + dataValue="true" oldDataValue="false"/> + </changes> + <operation name="newClass"> + <parameters name="ePackage"> + <referenceValue element="view.ecore#/"/> + </parameters> + <parameters name="name"> + <dataValue>Resolvable</dataValue> + </parameters> + <parameters name="superClasses"/> + <parameters name="abstr"> + <dataValue>true</dataValue> + </parameters> + </operation> + </changes> + <changes xsi:type="history:Create" target="view.ecore#//Resolvable" referenceName="eOperations" + element="view.ecore#//Resolvable/getDomainModelReferencesToResolve"/> + <changes xsi:type="history:Set" element="view.ecore#//Resolvable/getDomainModelReferencesToResolve" + featureName="eType" referenceValue="view.ecore#//DomainModelReference"/> + <changes xsi:type="history:Set" element="view.ecore#//Resolvable/getDomainModelReferencesToResolve" + featureName="upperBound" dataValue="-1" oldDataValue="1"/> + <changes xsi:type="history:Set" element="view.ecore#//Resolvable/getDomainModelReferencesToResolve" + featureName="name" dataValue="getDomainModelReferencesToResolve"/> + <changes xsi:type="history:Set" element="view.ecore#//Resolvable" featureName="interface" + dataValue="true" oldDataValue="false"/> + <changes xsi:type="history:Set" element="view.ecore#//Resolvable/getDomainModelReferencesToResolve" + featureName="ordered" dataValue="false" oldDataValue="true"/> + <changes xsi:type="history:Add" element="view.ecore#//Control" featureName="eSuperTypes" + referenceValue="view.ecore#//Resolvable"/> + </releases> </history:History>
diff --git a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/VControl.java b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/VControl.java index 1372b20f..fc152fd 100644 --- a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/VControl.java +++ b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/VControl.java
@@ -1,11 +1,11 @@ /** * Copyright (c) 2011-2013 EclipseSource Muenchen GmbH 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: * Eugen Neufeld - initial API and implementation */ @@ -19,8 +19,9 @@ /** * <!-- begin-user-doc --> * A representation of the model object '<em><b>Control</b></em>'. + * @since 1.2 * <!-- end-user-doc --> - * + * * <p> * The following features are supported: * <ul> @@ -28,13 +29,12 @@ * <li>{@link org.eclipse.emf.ecp.view.spi.model.VControl#getDomainModelReference <em>Domain Model Reference</em>}</li> * </ul> * </p> - * + * * @see org.eclipse.emf.ecp.view.spi.model.VViewPackage#getControl() * @model * @generated - * @since 1.2 */ -public interface VControl extends VContainedElement { +public interface VControl extends VContainedElement, VResolvable { /** * Returns the value of the '<em><b>Domain Model Reference</b></em>' containment reference. * <!-- begin-user-doc --> @@ -43,7 +43,7 @@ * more of a description here... * </p> * <!-- end-user-doc --> - * + * * @return the value of the '<em>Domain Model Reference</em>' containment reference. * @see #setDomainModelReference(VDomainModelReference) * @see org.eclipse.emf.ecp.view.spi.model.VViewPackage#getControl_DomainModelReference() @@ -57,7 +57,7 @@ * <em>Domain Model Reference</em>}' containment reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @param value the new value of the '<em>Domain Model Reference</em>' containment reference. * @see #getDomainModelReference() * @generated @@ -74,7 +74,7 @@ * description here... * </p> * <!-- end-user-doc --> - * + * * @return the value of the '<em>Label Alignment</em>' attribute. * @see org.eclipse.emf.ecp.view.spi.model.LabelAlignment * @see #setLabelAlignment(LabelAlignment) @@ -89,7 +89,7 @@ * <em>Label Alignment</em>}' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @param value the new value of the '<em>Label Alignment</em>' attribute. * @see org.eclipse.emf.ecp.view.spi.model.LabelAlignment * @see #getLabelAlignment() @@ -100,7 +100,7 @@ /** * Sets the {@link VDomainModelReference} based on the provided {@link EStructuralFeature}. Thus a * {@link VFeaturePathDomainModelReference} is created. - * + * * @param feature the {@link EStructuralFeature} to create the {@link VDomainModelReference} for */ void setDomainModelReference(EStructuralFeature feature); @@ -108,7 +108,7 @@ /** * Sets the {@link VDomainModelReference} based on the provided {@link EStructuralFeature} and the collection of * {@link EReference EReferences}. Thus a {@link VFeaturePathDomainModelReference} is created. - * + * * @param feature the {@link EStructuralFeature} to create the {@link VDomainModelReference} for * @param referencePath the {@link Collection} of {@link EReference EReferences} being the reference path */
diff --git a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/VResolvable.java b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/VResolvable.java new file mode 100644 index 0000000..e284603 --- /dev/null +++ b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/VResolvable.java
@@ -0,0 +1,40 @@ +/** + * Copyright (c) 2011-2013 EclipseSource Muenchen GmbH 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: + * Eugen Neufeld - initial API and implementation + */ +package org.eclipse.emf.ecp.view.spi.model; + +import org.eclipse.emf.common.util.EList; +import org.eclipse.emf.ecore.EObject; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Resolvable</b></em>'. + * + * @since 1.5 + * <!-- end-user-doc --> + * + * + * @see org.eclipse.emf.ecp.view.spi.model.VViewPackage#getResolvable() + * @model interface="true" abstract="true" + * @generated + */ +public interface VResolvable extends EObject +{ + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @model kind="operation" ordered="false" + * @generated + */ + EList<VDomainModelReference> getDomainModelReferencesToResolve(); + +} // VResolvable
diff --git a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/VViewPackage.java b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/VViewPackage.java index a08d57d..9327de8 100644 --- a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/VViewPackage.java +++ b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/VViewPackage.java
@@ -1,11 +1,11 @@ /** * Copyright (c) 2011-2013 EclipseSource Muenchen GmbH 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: * Eugen Neufeld - initial API and implementation */ @@ -28,20 +28,20 @@ * <li>each enum,</li> * <li>and each data type</li> * </ul> - * + * * @noimplement This interface is not intended to be implemented by clients. - * <!-- end-user-doc --> + * @since 1.2 + * <!-- end-user-doc --> * @see org.eclipse.emf.ecp.view.spi.model.VViewFactory * @model kind="package" * @generated - * @since 1.2 */ public interface VViewPackage extends EPackage { /** * The package name. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ String eNAME = "model"; //$NON-NLS-1$ @@ -50,7 +50,7 @@ * The package namespace URI. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ String eNS_URI = "http://org/eclipse/emf/ecp/view/model"; //$NON-NLS-1$ @@ -59,7 +59,7 @@ * The package namespace name. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ String eNS_PREFIX = "org.eclipse.emf.ecp.view.model"; //$NON-NLS-1$ @@ -68,7 +68,7 @@ * The singleton instance of the package. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ VViewPackage eINSTANCE = org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl.init(); @@ -77,7 +77,7 @@ * The meta object id for the '{@link org.eclipse.emf.ecp.view.spi.model.impl.VElementImpl <em>Element</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VElementImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getElement() * @generated @@ -89,7 +89,7 @@ * class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VDiagnosticImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getDiagnostic() * @generated @@ -100,7 +100,7 @@ * The feature id for the '<em><b>Diagnostics</b></em>' attribute list. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -110,7 +110,7 @@ * The number of structural features of the '<em>Diagnostic</em>' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -120,7 +120,7 @@ * The meta object id for the '{@link org.eclipse.emf.ecp.view.spi.model.impl.VViewImpl <em>View</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getView() * @generated @@ -131,7 +131,7 @@ * The meta object id for the '{@link org.eclipse.emf.ecp.view.spi.model.impl.VControlImpl <em>Control</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VControlImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getControl() * @generated @@ -143,7 +143,7 @@ * class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VAttachmentImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getAttachment() * @generated @@ -154,7 +154,7 @@ * The number of structural features of the '<em>Attachment</em>' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -165,7 +165,7 @@ * <em>Domain Model Reference</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.VDomainModelReference * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getDomainModelReference() * @generated @@ -175,7 +175,7 @@ /** * The feature id for the '<em><b>Change Listener</b></em>' attribute list. * <!-- begin-user-doc --> - * + * * @since 1.3 * <!-- end-user-doc --> * @generated @@ -187,7 +187,7 @@ * The number of structural features of the '<em>Domain Model Reference</em>' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -198,7 +198,7 @@ * <em>Feature Path Domain Model Reference</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VFeaturePathDomainModelReferenceImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getFeaturePathDomainModelReference() * @generated @@ -208,11 +208,12 @@ /** * The feature id for the '<em><b>Change Listener</b></em>' attribute list. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.3 + * <!-- end-user-doc --> + * * @generated * @ordered - * @since 1.3 */ int FEATURE_PATH_DOMAIN_MODEL_REFERENCE__CHANGE_LISTENER = DOMAIN_MODEL_REFERENCE__CHANGE_LISTENER; @@ -220,7 +221,7 @@ * The feature id for the '<em><b>Domain Model EFeature</b></em>' reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -230,7 +231,7 @@ * The feature id for the '<em><b>Domain Model EReference Path</b></em>' reference list. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -240,7 +241,7 @@ * The number of structural features of the '<em>Feature Path Domain Model Reference</em>' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -250,7 +251,7 @@ * The feature id for the '<em><b>Name</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -260,7 +261,7 @@ * The feature id for the '<em><b>Visible</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -270,7 +271,7 @@ * The feature id for the '<em><b>Enabled</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -280,7 +281,7 @@ * The feature id for the '<em><b>Readonly</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -290,7 +291,7 @@ * The feature id for the '<em><b>Diagnostic</b></em>' containment reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -300,7 +301,7 @@ * The feature id for the '<em><b>Attachments</b></em>' containment reference list. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -310,7 +311,7 @@ * The number of structural features of the '<em>Element</em>' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -320,7 +321,7 @@ * The feature id for the '<em><b>Name</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -330,7 +331,7 @@ * The feature id for the '<em><b>Visible</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -340,7 +341,7 @@ * The feature id for the '<em><b>Enabled</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -350,7 +351,7 @@ * The feature id for the '<em><b>Readonly</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -360,7 +361,7 @@ * The feature id for the '<em><b>Diagnostic</b></em>' containment reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -370,7 +371,7 @@ * The feature id for the '<em><b>Attachments</b></em>' containment reference list. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -380,7 +381,7 @@ * The feature id for the '<em><b>Root EClass</b></em>' reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -390,7 +391,7 @@ * The feature id for the '<em><b>Children</b></em>' containment reference list. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -399,7 +400,7 @@ /** * The feature id for the '<em><b>Ecore Path</b></em>' attribute. * <!-- begin-user-doc --> - * + * * @since 1.3 * <!-- end-user-doc --> * @generated @@ -410,7 +411,7 @@ /** * The number of structural features of the '<em>View</em>' class. * <!-- begin-user-doc --> - * + * * @since 1.3 * <!-- end-user-doc --> * @generated @@ -423,7 +424,7 @@ * <em>Contained Element</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VContainedElementImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getContainedElement() * @generated @@ -434,7 +435,7 @@ * The feature id for the '<em><b>Name</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -444,7 +445,7 @@ * The feature id for the '<em><b>Visible</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -454,7 +455,7 @@ * The feature id for the '<em><b>Enabled</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -464,7 +465,7 @@ * The feature id for the '<em><b>Readonly</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -474,7 +475,7 @@ * The feature id for the '<em><b>Diagnostic</b></em>' containment reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -484,7 +485,7 @@ * The feature id for the '<em><b>Attachments</b></em>' containment reference list. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -494,7 +495,7 @@ * The number of structural features of the '<em>Contained Element</em>' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -505,7 +506,7 @@ * class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VContainerImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getContainer() * @generated @@ -516,7 +517,7 @@ * The feature id for the '<em><b>Name</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -526,7 +527,7 @@ * The feature id for the '<em><b>Visible</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -536,7 +537,7 @@ * The feature id for the '<em><b>Enabled</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -546,7 +547,7 @@ * The feature id for the '<em><b>Readonly</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -556,7 +557,7 @@ * The feature id for the '<em><b>Diagnostic</b></em>' containment reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -566,7 +567,7 @@ * The feature id for the '<em><b>Attachments</b></em>' containment reference list. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -576,7 +577,7 @@ * The feature id for the '<em><b>Children</b></em>' containment reference list. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -586,7 +587,7 @@ * The number of structural features of the '<em>Container</em>' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -596,100 +597,109 @@ * The meta object id for the '{@link org.eclipse.emf.ecp.view.spi.model.impl.VContainedContainerImpl * <em>Contained Container</em>}' class. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.4 + * <!-- end-user-doc --> + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VContainedContainerImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getContainedContainer() * @generated - * @since 1.4 */ int CONTAINED_CONTAINER = 8; /** * The feature id for the '<em><b>Name</b></em>' attribute. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.4 + * <!-- end-user-doc --> + * * @generated * @ordered - * @since 1.4 */ int CONTAINED_CONTAINER__NAME = CONTAINED_ELEMENT__NAME; /** * The feature id for the '<em><b>Visible</b></em>' attribute. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.4 + * <!-- end-user-doc --> + * * @generated * @ordered - * @since 1.4 */ int CONTAINED_CONTAINER__VISIBLE = CONTAINED_ELEMENT__VISIBLE; /** * The feature id for the '<em><b>Enabled</b></em>' attribute. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.4 + * <!-- end-user-doc --> + * * @generated * @ordered - * @since 1.4 */ int CONTAINED_CONTAINER__ENABLED = CONTAINED_ELEMENT__ENABLED; /** * The feature id for the '<em><b>Readonly</b></em>' attribute. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.4 + * <!-- end-user-doc --> + * * @generated * @ordered - * @since 1.4 */ int CONTAINED_CONTAINER__READONLY = CONTAINED_ELEMENT__READONLY; /** * The feature id for the '<em><b>Diagnostic</b></em>' containment reference. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.4 + * <!-- end-user-doc --> + * * @generated * @ordered - * @since 1.4 */ int CONTAINED_CONTAINER__DIAGNOSTIC = CONTAINED_ELEMENT__DIAGNOSTIC; /** * The feature id for the '<em><b>Attachments</b></em>' containment reference list. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.4 + * <!-- end-user-doc --> + * * @generated * @ordered - * @since 1.4 */ int CONTAINED_CONTAINER__ATTACHMENTS = CONTAINED_ELEMENT__ATTACHMENTS; /** * The feature id for the '<em><b>Children</b></em>' containment reference list. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.4 + * <!-- end-user-doc --> + * * @generated * @ordered - * @since 1.4 */ int CONTAINED_CONTAINER__CHILDREN = CONTAINED_ELEMENT_FEATURE_COUNT + 0; /** * The number of structural features of the '<em>Contained Container</em>' class. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.4 + * <!-- end-user-doc --> + * * @generated * @ordered - * @since 1.4 */ int CONTAINED_CONTAINER_FEATURE_COUNT = CONTAINED_ELEMENT_FEATURE_COUNT + 1; @@ -697,7 +707,7 @@ * The feature id for the '<em><b>Name</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -707,7 +717,7 @@ * The feature id for the '<em><b>Visible</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -717,7 +727,7 @@ * The feature id for the '<em><b>Enabled</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -727,7 +737,7 @@ * The feature id for the '<em><b>Readonly</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -737,7 +747,7 @@ * The feature id for the '<em><b>Diagnostic</b></em>' containment reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -747,7 +757,7 @@ * The feature id for the '<em><b>Attachments</b></em>' containment reference list. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -757,7 +767,7 @@ * The feature id for the '<em><b>Label Alignment</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -767,7 +777,7 @@ * The feature id for the '<em><b>Domain Model Reference</b></em>' containment reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ @@ -777,41 +787,66 @@ * The number of structural features of the '<em>Control</em>' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated * @ordered */ int CONTROL_FEATURE_COUNT = CONTAINED_ELEMENT_FEATURE_COUNT + 2; /** + * The meta object id for the '{@link org.eclipse.emf.ecp.view.spi.model.VResolvable <em>Resolvable</em>}' class. + * <!-- begin-user-doc --> + * + * @since 1.5 + * <!-- end-user-doc --> + * + * @see org.eclipse.emf.ecp.view.spi.model.VResolvable + * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getResolvable() + * @generated + */ + int RESOLVABLE = 10; + + /** + * The number of structural features of the '<em>Resolvable</em>' class. + * <!-- begin-user-doc --> + * + * @since 1.5 + * <!-- end-user-doc --> + * + * @generated + * @ordered + */ + int RESOLVABLE_FEATURE_COUNT = 0; + + /** * The meta object id for the '{@link org.eclipse.emf.ecp.view.spi.model.LabelAlignment <em>Label Alignment</em>}' * enum. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.LabelAlignment * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getLabelAlignment() * @generated */ - int LABEL_ALIGNMENT = 10; + int LABEL_ALIGNMENT = 11; /** * The meta object id for the '<em>Domain Model Reference Change Listener</em>' data type. * <!-- begin-user-doc --> - * + * * @since 1.3 * <!-- end-user-doc --> * @see org.eclipse.emf.ecp.view.spi.model.DomainModelReferenceChangeListener * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getDomainModelReferenceChangeListener() * @generated */ - int DOMAIN_MODEL_REFERENCE_CHANGE_LISTENER = 11; + int DOMAIN_MODEL_REFERENCE_CHANGE_LISTENER = 12; /** * Returns the meta object for class '{@link org.eclipse.emf.ecp.view.spi.model.VElement <em>Element</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for class '<em>Element</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VElement * @generated @@ -823,7 +858,7 @@ * <em>Name</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the attribute '<em>Name</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VElement#getName() * @see #getElement() @@ -836,7 +871,7 @@ * <em>Visible</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the attribute '<em>Visible</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VElement#isVisible() * @see #getElement() @@ -849,7 +884,7 @@ * <em>Enabled</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the attribute '<em>Enabled</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VElement#isEnabled() * @see #getElement() @@ -862,7 +897,7 @@ * <em>Readonly</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the attribute '<em>Readonly</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VElement#isReadonly() * @see #getElement() @@ -875,7 +910,7 @@ * {@link org.eclipse.emf.ecp.view.spi.model.VElement#getDiagnostic <em>Diagnostic</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the containment reference '<em>Diagnostic</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VElement#getDiagnostic() * @see #getElement() @@ -888,7 +923,7 @@ * {@link org.eclipse.emf.ecp.view.spi.model.VElement#getAttachments <em>Attachments</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the containment reference list '<em>Attachments</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VElement#getAttachments() * @see #getElement() @@ -900,7 +935,7 @@ * Returns the meta object for class '{@link org.eclipse.emf.ecp.view.spi.model.VDiagnostic <em>Diagnostic</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for class '<em>Diagnostic</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VDiagnostic * @generated @@ -912,7 +947,7 @@ * {@link org.eclipse.emf.ecp.view.spi.model.VDiagnostic#getDiagnostics <em>Diagnostics</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the attribute list '<em>Diagnostics</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VDiagnostic#getDiagnostics() * @see #getDiagnostic() @@ -924,7 +959,7 @@ * Returns the meta object for class '{@link org.eclipse.emf.ecp.view.spi.model.VView <em>View</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for class '<em>View</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VView * @generated @@ -936,7 +971,7 @@ * <em>Root EClass</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the reference '<em>Root EClass</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VView#getRootEClass() * @see #getView() @@ -949,7 +984,7 @@ * {@link org.eclipse.emf.ecp.view.spi.model.VView#getChildren <em>Children</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the containment reference list '<em>Children</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VView#getChildren() * @see #getView() @@ -961,13 +996,14 @@ * Returns the meta object for the attribute '{@link org.eclipse.emf.ecp.view.spi.model.VView#getEcorePath * <em>Ecore Path</em>}'. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.3 + * <!-- end-user-doc --> + * * @return the meta object for the attribute '<em>Ecore Path</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VView#getEcorePath() * @see #getView() * @generated - * @since 1.3 */ EAttribute getView_EcorePath(); @@ -976,7 +1012,7 @@ * <em>Contained Element</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for class '<em>Contained Element</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VContainedElement * @generated @@ -987,7 +1023,7 @@ * Returns the meta object for class '{@link org.eclipse.emf.ecp.view.spi.model.VControl <em>Control</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for class '<em>Control</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VControl * @generated @@ -999,7 +1035,7 @@ * {@link org.eclipse.emf.ecp.view.spi.model.VControl#getDomainModelReference <em>Domain Model Reference</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the containment reference '<em>Domain Model Reference</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VControl#getDomainModelReference() * @see #getControl() @@ -1008,10 +1044,23 @@ EReference getControl_DomainModelReference(); /** + * Returns the meta object for class '{@link org.eclipse.emf.ecp.view.spi.model.VResolvable <em>Resolvable</em>}'. + * <!-- begin-user-doc --> + * + * @since 1.5 + * <!-- end-user-doc --> + * + * @return the meta object for class '<em>Resolvable</em>'. + * @see org.eclipse.emf.ecp.view.spi.model.VResolvable + * @generated + */ + EClass getResolvable(); + + /** * Returns the meta object for class '{@link org.eclipse.emf.ecp.view.spi.model.VContainer <em>Container</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for class '<em>Container</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VContainer * @generated @@ -1023,7 +1072,7 @@ * {@link org.eclipse.emf.ecp.view.spi.model.VContainer#getChildren <em>Children</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the containment reference list '<em>Children</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VContainer#getChildren() * @see #getContainer() @@ -1035,12 +1084,13 @@ * Returns the meta object for class '{@link org.eclipse.emf.ecp.view.spi.model.VContainedContainer * <em>Contained Container</em>}'. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.4 + * <!-- end-user-doc --> + * * @return the meta object for class '<em>Contained Container</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VContainedContainer * @generated - * @since 1.4 */ EClass getContainedContainer(); @@ -1049,7 +1099,7 @@ * <em>Label Alignment</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the attribute '<em>Label Alignment</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VControl#getLabelAlignment() * @see #getControl() @@ -1062,7 +1112,7 @@ * <em>Label Alignment</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for enum '<em>Label Alignment</em>'. * @see org.eclipse.emf.ecp.view.spi.model.LabelAlignment * @generated @@ -1074,7 +1124,7 @@ * {@link org.eclipse.emf.ecp.view.spi.model.DomainModelReferenceChangeListener * <em>Domain Model Reference Change Listener</em>}'. * <!-- begin-user-doc --> - * + * * @since 1.3 * <!-- end-user-doc --> * @return the meta object for data type '<em>Domain Model Reference Change Listener</em>'. @@ -1089,7 +1139,7 @@ * <em>Domain Model Reference</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for class '<em>Domain Model Reference</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VDomainModelReference * @generated @@ -1100,7 +1150,7 @@ * Returns the meta object for the attribute list ' * {@link org.eclipse.emf.ecp.view.spi.model.VDomainModelReference#getChangeListener <em>Change Listener</em>}'. * <!-- begin-user-doc --> - * + * * @since 1.3 * <!-- end-user-doc --> * @return the meta object for the attribute list '<em>Change Listener</em>'. @@ -1115,7 +1165,7 @@ * <em>Feature Path Domain Model Reference</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for class '<em>Feature Path Domain Model Reference</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VFeaturePathDomainModelReference * @generated @@ -1128,7 +1178,7 @@ * <em>Domain Model EFeature</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the reference '<em>Domain Model EFeature</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VFeaturePathDomainModelReference#getDomainModelEFeature() * @see #getFeaturePathDomainModelReference() @@ -1142,7 +1192,7 @@ * <em>Domain Model EReference Path</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for the reference list '<em>Domain Model EReference Path</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VFeaturePathDomainModelReference#getDomainModelEReferencePath() * @see #getFeaturePathDomainModelReference() @@ -1154,7 +1204,7 @@ * Returns the meta object for class '{@link org.eclipse.emf.ecp.view.spi.model.VAttachment <em>Attachment</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the meta object for class '<em>Attachment</em>'. * @see org.eclipse.emf.ecp.view.spi.model.VAttachment * @generated @@ -1165,7 +1215,7 @@ * Returns the factory that creates the instances of the model. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @return the factory that creates the instances of the model. * @generated */ @@ -1180,7 +1230,7 @@ * <li>each enum,</li> * <li>and each data type</li> * </ul> - * + * * @noimplement This interface is not intended to be implemented by clients. * <!-- end-user-doc --> * @generated @@ -1191,7 +1241,7 @@ * <em>Element</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VElementImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getElement() * @generated @@ -1202,7 +1252,7 @@ * The meta object literal for the '<em><b>Name</b></em>' attribute feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EAttribute ELEMENT__NAME = eINSTANCE.getElement_Name(); @@ -1211,7 +1261,7 @@ * The meta object literal for the '<em><b>Visible</b></em>' attribute feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EAttribute ELEMENT__VISIBLE = eINSTANCE.getElement_Visible(); @@ -1220,7 +1270,7 @@ * The meta object literal for the '<em><b>Enabled</b></em>' attribute feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EAttribute ELEMENT__ENABLED = eINSTANCE.getElement_Enabled(); @@ -1229,7 +1279,7 @@ * The meta object literal for the '<em><b>Readonly</b></em>' attribute feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EAttribute ELEMENT__READONLY = eINSTANCE.getElement_Readonly(); @@ -1238,7 +1288,7 @@ * The meta object literal for the '<em><b>Diagnostic</b></em>' containment reference feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EReference ELEMENT__DIAGNOSTIC = eINSTANCE.getElement_Diagnostic(); @@ -1247,7 +1297,7 @@ * The meta object literal for the '<em><b>Attachments</b></em>' containment reference list feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EReference ELEMENT__ATTACHMENTS = eINSTANCE.getElement_Attachments(); @@ -1257,7 +1307,7 @@ * <em>Diagnostic</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VDiagnosticImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getDiagnostic() * @generated @@ -1268,7 +1318,7 @@ * The meta object literal for the '<em><b>Diagnostics</b></em>' attribute list feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EAttribute DIAGNOSTIC__DIAGNOSTICS = eINSTANCE.getDiagnostic_Diagnostics(); @@ -1278,7 +1328,7 @@ * class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getView() * @generated @@ -1289,7 +1339,7 @@ * The meta object literal for the '<em><b>Root EClass</b></em>' reference feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EReference VIEW__ROOT_ECLASS = eINSTANCE.getView_RootEClass(); @@ -1298,7 +1348,7 @@ * The meta object literal for the '<em><b>Children</b></em>' containment reference list feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EReference VIEW__CHILDREN = eINSTANCE.getView_Children(); @@ -1306,7 +1356,7 @@ /** * The meta object literal for the '<em><b>Ecore Path</b></em>' attribute feature. * <!-- begin-user-doc --> - * + * * @since 1.3 * <!-- end-user-doc --> * @generated @@ -1318,7 +1368,7 @@ * <em>Contained Element</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VContainedElementImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getContainedElement() * @generated @@ -1330,7 +1380,7 @@ * <em>Control</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VControlImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getControl() * @generated @@ -1341,17 +1391,31 @@ * The meta object literal for the '<em><b>Domain Model Reference</b></em>' containment reference feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EReference CONTROL__DOMAIN_MODEL_REFERENCE = eINSTANCE.getControl_DomainModelReference(); /** + * The meta object literal for the '{@link org.eclipse.emf.ecp.view.spi.model.VResolvable <em>Resolvable</em>}' + * class. + * <!-- begin-user-doc --> + * + * @since 1.5 + * <!-- end-user-doc --> + * + * @see org.eclipse.emf.ecp.view.spi.model.VResolvable + * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getResolvable() + * @generated + */ + EClass RESOLVABLE = eINSTANCE.getResolvable(); + + /** * The meta object literal for the '{@link org.eclipse.emf.ecp.view.spi.model.impl.VContainerImpl * <em>Container</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VContainerImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getContainer() * @generated @@ -1362,7 +1426,7 @@ * The meta object literal for the '<em><b>Children</b></em>' containment reference list feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EReference CONTAINER__CHILDREN = eINSTANCE.getContainer_Children(); @@ -1371,12 +1435,13 @@ * The meta object literal for the '{@link org.eclipse.emf.ecp.view.spi.model.impl.VContainedContainerImpl * <em>Contained Container</em>}' class. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.4 + * <!-- end-user-doc --> + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VContainedContainerImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getContainedContainer() * @generated - * @since 1.4 */ EClass CONTAINED_CONTAINER = eINSTANCE.getContainedContainer(); @@ -1384,7 +1449,7 @@ * The meta object literal for the '<em><b>Label Alignment</b></em>' attribute feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EAttribute CONTROL__LABEL_ALIGNMENT = eINSTANCE.getControl_LabelAlignment(); @@ -1394,7 +1459,7 @@ * <em>Label Alignment</em>}' enum. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.LabelAlignment * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getLabelAlignment() * @generated @@ -1404,12 +1469,13 @@ /** * The meta object literal for the '<em>Domain Model Reference Change Listener</em>' data type. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * + * + * @since 1.3 + * <!-- end-user-doc --> + * * @see org.eclipse.emf.ecp.view.spi.model.DomainModelReferenceChangeListener * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getDomainModelReferenceChangeListener() * @generated - * @since 1.3 */ EDataType DOMAIN_MODEL_REFERENCE_CHANGE_LISTENER = eINSTANCE.getDomainModelReferenceChangeListener(); @@ -1418,7 +1484,7 @@ * <em>Domain Model Reference</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.VDomainModelReference * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getDomainModelReference() * @generated @@ -1428,7 +1494,7 @@ /** * The meta object literal for the '<em><b>Change Listener</b></em>' attribute list feature. * <!-- begin-user-doc --> - * + * * @since 1.3 * <!-- end-user-doc --> * @generated @@ -1441,7 +1507,7 @@ * <em>Feature Path Domain Model Reference</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VFeaturePathDomainModelReferenceImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getFeaturePathDomainModelReference() * @generated @@ -1452,7 +1518,7 @@ * The meta object literal for the '<em><b>Domain Model EFeature</b></em>' reference feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EReference FEATURE_PATH_DOMAIN_MODEL_REFERENCE__DOMAIN_MODEL_EFEATURE = eINSTANCE @@ -1462,7 +1528,7 @@ * The meta object literal for the '<em><b>Domain Model EReference Path</b></em>' reference list feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ EReference FEATURE_PATH_DOMAIN_MODEL_REFERENCE__DOMAIN_MODEL_EREFERENCE_PATH = eINSTANCE @@ -1473,7 +1539,7 @@ * <em>Attachment</em>}' class. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.impl.VAttachmentImpl * @see org.eclipse.emf.ecp.view.spi.model.impl.VViewPackageImpl#getAttachment() * @generated
diff --git a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/impl/VControlImpl.java b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/impl/VControlImpl.java index 847b42c..ba8de9c 100644 --- a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/impl/VControlImpl.java +++ b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/impl/VControlImpl.java
@@ -1,11 +1,11 @@ /** * Copyright (c) 2011-2013 EclipseSource Muenchen GmbH 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: * Eugen Neufeld - initial API and implementation */ @@ -15,6 +15,8 @@ import org.eclipse.emf.common.notify.Notification; import org.eclipse.emf.common.notify.NotificationChain; +import org.eclipse.emf.common.util.BasicEList; +import org.eclipse.emf.common.util.EList; import org.eclipse.emf.ecore.EClass; import org.eclipse.emf.ecore.EReference; import org.eclipse.emf.ecore.EStructuralFeature; @@ -29,25 +31,26 @@ /** * <!-- begin-user-doc --> * An implementation of the model object '<em><b>Control</b></em>'. - * <!-- end-user-doc --> - * <p> - * The following features are implemented: - * <ul> - * <li>{@link org.eclipse.emf.ecp.view.spi.model.impl.VControlImpl#getLabelAlignment <em>Label Alignment</em>}</li> - * <li>{@link org.eclipse.emf.ecp.view.spi.model.impl.VControlImpl#getDomainModelReference <em>Domain Model Reference - * </em>}</li> - * </ul> - * </p> - * - * @generated + * * @since 1.2 + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * <ul> + * <li>{@link org.eclipse.emf.ecp.view.spi.model.impl.VControlImpl#getLabelAlignment <em>Label Alignment</em>}</li> + * <li>{@link org.eclipse.emf.ecp.view.spi.model.impl.VControlImpl#getDomainModelReference <em>Domain Model + * Reference </em>}</li> + * </ul> + * </p> + * + * @generated */ public class VControlImpl extends VContainedElementImpl implements VControl { /** * The default value of the '{@link #getLabelAlignment() <em>Label Alignment</em>}' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see #getLabelAlignment() * @generated * @ordered @@ -58,7 +61,7 @@ * The cached value of the '{@link #getLabelAlignment() <em>Label Alignment</em>}' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see #getLabelAlignment() * @generated * @ordered @@ -70,7 +73,7 @@ * reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see #getDomainModelReference() * @generated * @ordered @@ -80,7 +83,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ protected VControlImpl() { @@ -90,7 +93,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -101,7 +104,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -113,7 +116,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ public NotificationChain basicSetDomainModelReference(VDomainModelReference newDomainModelReference, @@ -137,7 +140,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -167,8 +170,25 @@ /** * <!-- begin-user-doc --> + * + * @since 1.5 + * <!-- end-user-doc --> + * + * @generated NOT + * @return the {@link VDomainModelReference references} to resolve + */ + @Override + public EList<VDomainModelReference> getDomainModelReferencesToResolve() + { + final EList<VDomainModelReference> result = new BasicEList<VDomainModelReference>(); + result.add(getDomainModelReference()); + return result; + } + + /** + * <!-- begin-user-doc -->. * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -185,7 +205,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -197,7 +217,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -214,7 +234,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -232,7 +252,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -252,7 +272,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -272,7 +292,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -290,7 +310,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -308,7 +328,7 @@ /** * {@inheritDoc} - * + * * @see org.eclipse.emf.ecp.view.spi.model.VControl#setDomainModelReference(org.eclipse.emf.ecore.EStructuralFeature) */ @Override @@ -318,7 +338,7 @@ /** * {@inheritDoc} - * + * * @see org.eclipse.emf.ecp.view.spi.model.VControl#setDomainModelReference(org.eclipse.emf.ecore.EStructuralFeature, * java.util.Collection) */
diff --git a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/impl/VViewPackageImpl.java b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/impl/VViewPackageImpl.java index 0266100..aa0de3c 100644 --- a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/impl/VViewPackageImpl.java +++ b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/impl/VViewPackageImpl.java
@@ -1,11 +1,11 @@ /** * Copyright (c) 2011-2013 EclipseSource Muenchen GmbH 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: * Eugen Neufeld - initial API and implementation */ @@ -32,22 +32,23 @@ import org.eclipse.emf.ecp.view.spi.model.VDomainModelReference; import org.eclipse.emf.ecp.view.spi.model.VElement; import org.eclipse.emf.ecp.view.spi.model.VFeaturePathDomainModelReference; +import org.eclipse.emf.ecp.view.spi.model.VResolvable; import org.eclipse.emf.ecp.view.spi.model.VView; import org.eclipse.emf.ecp.view.spi.model.VViewFactory; import org.eclipse.emf.ecp.view.spi.model.VViewPackage; /** - * <!-- begin-user-doc --> An implementation of the model <b>Package</b>. <!-- + * <!-- begin-user-doc --> An implementation of the model <b>Package</b>. + * @since 1.2 <!-- * end-user-doc --> - * + * * @generated - * @since 1.2 */ public class VViewPackageImpl extends EPackageImpl implements VViewPackage { /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ private EClass elementEClass = null; @@ -55,14 +56,14 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ private EClass diagnosticEClass = null; /** * <!-- begin-user-doc --> <!-- end-user-doc --> - * + * * @generated */ private EClass viewEClass = null; @@ -70,14 +71,14 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ private EClass containedElementEClass = null; /** * <!-- begin-user-doc --> <!-- end-user-doc --> - * + * * @generated */ private EClass controlEClass = null; @@ -85,7 +86,15 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * + * @generated + */ + private EClass resolvableEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * * @generated */ private EClass containerEClass = null; @@ -93,7 +102,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ private EClass containedContainerEClass = null; @@ -101,7 +110,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ private EEnum labelAlignmentEEnum = null; @@ -109,7 +118,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ private EDataType domainModelReferenceChangeListenerEDataType = null; @@ -117,7 +126,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ private EClass domainModelReferenceEClass = null; @@ -125,7 +134,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ private EClass featurePathDomainModelReferenceEClass = null; @@ -133,7 +142,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ private EClass attachmentEClass = null; @@ -146,7 +155,7 @@ * Note: the correct way to create the package is via the static factory method {@link #init init()}, which also * performs initialization of the package, or returns the registered package, if one already exists. <!-- * begin-user-doc --> <!-- end-user-doc --> - * + * * @see org.eclipse.emf.ecore.EPackage.Registry * @see org.eclipse.emf.ecp.view.spi.model.VViewPackage#eNS_URI * @see #init() @@ -158,19 +167,19 @@ /** * <!-- begin-user-doc --> <!-- end-user-doc --> - * + * * @generated */ private static boolean isInited = false; /** * Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends. - * + * * <p> * This method is used to initialize {@link VViewPackage#eINSTANCE} when that field is accessed. Clients should not * invoke it directly. Instead, they should simply access that field to obtain the package. <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @see #eNS_URI * @see #createPackageContents() * @see #initializePackageContents() @@ -208,7 +217,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -220,7 +229,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -232,7 +241,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -244,7 +253,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -256,7 +265,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -268,7 +277,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -280,7 +289,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -292,7 +301,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -304,7 +313,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -315,7 +324,7 @@ /** * <!-- begin-user-doc --> <!-- end-user-doc --> - * + * * @generated */ @Override @@ -325,7 +334,7 @@ /** * <!-- begin-user-doc --> <!-- end-user-doc --> - * + * * @generated */ @Override @@ -336,7 +345,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -346,7 +355,7 @@ /** * <!-- begin-user-doc --> - * + * * @since 1.3 * <!-- end-user-doc --> * @generated @@ -360,7 +369,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -371,7 +380,7 @@ /** * <!-- begin-user-doc --> <!-- end-user-doc --> - * + * * @generated */ @Override @@ -382,7 +391,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -394,7 +403,19 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * + * @generated + */ + @Override + public EClass getResolvable() + { + return resolvableEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * * @generated */ @Override @@ -406,7 +427,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -417,10 +438,10 @@ /** * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated * @since 1.4 + * <!-- end-user-doc --> + * + * @generated */ @Override public EClass getContainedContainer() @@ -431,7 +452,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -442,10 +463,10 @@ /** * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated * @since 1.3 + * <!-- end-user-doc --> + * + * @generated */ @Override public EEnum getLabelAlignment() @@ -455,7 +476,7 @@ /** * <!-- begin-user-doc --> - * + * * @since 1.3 * <!-- end-user-doc --> * @generated @@ -469,7 +490,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -480,7 +501,7 @@ /** * <!-- begin-user-doc --> - * + * * @since 1.3 * <!-- end-user-doc --> * @generated @@ -494,7 +515,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -506,7 +527,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -518,7 +539,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -530,7 +551,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -542,7 +563,7 @@ /** * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ @Override @@ -552,7 +573,7 @@ /** * <!-- begin-user-doc --> <!-- end-user-doc --> - * + * * @generated */ private boolean isCreated = false; @@ -562,7 +583,7 @@ * guarded to have no affect on any invocation but its first. * <!-- begin-user-doc --> * <!-- end-user-doc --> - * + * * @generated */ public void createPackageContents() { @@ -610,6 +631,8 @@ createEAttribute(controlEClass, CONTROL__LABEL_ALIGNMENT); createEReference(controlEClass, CONTROL__DOMAIN_MODEL_REFERENCE); + resolvableEClass = createEClass(RESOLVABLE); + // Create enums labelAlignmentEEnum = createEEnum(LABEL_ALIGNMENT); @@ -619,7 +642,7 @@ /** * <!-- begin-user-doc --> <!-- end-user-doc --> - * + * * @generated */ private boolean isInitialized = false; @@ -628,7 +651,7 @@ * Complete the initialization of the package and its meta-model. This * method is guarded to have no affect on any invocation but its first. <!-- * begin-user-doc --> <!-- end-user-doc --> - * + * * @generated */ public void initializePackageContents() { @@ -658,6 +681,7 @@ containedContainerEClass.getESuperTypes().add(getContainedElement()); containedContainerEClass.getESuperTypes().add(getContainer()); controlEClass.getESuperTypes().add(getContainedElement()); + controlEClass.getESuperTypes().add(getResolvable()); // Initialize classes and features; add operations and parameters initEClass(diagnosticEClass, VDiagnostic.class, @@ -759,6 +783,12 @@ null, "domainModelReference", null, 1, 1, VControl.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEClass(resolvableEClass, VResolvable.class, + "Resolvable", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ + + addEOperation(resolvableEClass, getDomainModelReference(), + "getDomainModelReferencesToResolve", 0, -1, IS_UNIQUE, !IS_ORDERED); //$NON-NLS-1$ + // Initialize enums and add enum literals initEEnum(labelAlignmentEEnum, LabelAlignment.class, "LabelAlignment"); //$NON-NLS-1$ addEEnumLiteral(labelAlignmentEEnum, LabelAlignment.LEFT);
diff --git a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/reporting/DomainModelReferenceResolutionFailedReport.java b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/reporting/DomainModelReferenceResolutionFailedReport.java index 3a65642..fa636d0 100644 --- a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/reporting/DomainModelReferenceResolutionFailedReport.java +++ b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/reporting/DomainModelReferenceResolutionFailedReport.java
@@ -12,9 +12,8 @@ package org.eclipse.emf.ecp.view.spi.model.reporting; import org.eclipse.core.runtime.IStatus; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecp.view.spi.model.VControl; import org.eclipse.emf.ecp.view.spi.model.VDomainModelReference; +import org.eclipse.emf.ecp.view.spi.model.VResolvable; /** * Indicates that a {@link org.eclipse.emf.ecp.view.spi.model.VDomainModelReference VDomainModelReference} could not be @@ -31,27 +30,13 @@ * * @param domainModelReference * the domain model reference that could not be resolved - * @param element - * the element that should be resolved - */ - public DomainModelReferenceResolutionFailedReport( - VDomainModelReference domainModelReference, EObject element) { - super("Not resolved: " + domainModelReference //$NON-NLS-1$ - + " on label " + element, IStatus.WARNING); //$NON-NLS-1$ - } - - /** - * Constructor. - * - * @param domainModelReference - * the domain model reference that could not be resolved * @param control * the control holding the domain model reference */ public DomainModelReferenceResolutionFailedReport( - VDomainModelReference domainModelReference, VControl control) { + VDomainModelReference domainModelReference, VResolvable control) { super("Not resolved: " + domainModelReference //$NON-NLS-1$ - + " on control " + control, IStatus.WARNING); //$NON-NLS-1$ + + " on resolveable " + control, IStatus.WARNING); //$NON-NLS-1$ } }
diff --git a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/util/ViewAdapterFactory.java b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/util/ViewAdapterFactory.java index 92f644e..fcf69bb 100644 --- a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/util/ViewAdapterFactory.java +++ b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/util/ViewAdapterFactory.java
@@ -1,11 +1,11 @@ /** * Copyright (c) 2011-2013 EclipseSource Muenchen GmbH 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: * Eugen Neufeld - initial API and implementation */ @@ -24,23 +24,24 @@ import org.eclipse.emf.ecp.view.spi.model.VDomainModelReference; import org.eclipse.emf.ecp.view.spi.model.VElement; import org.eclipse.emf.ecp.view.spi.model.VFeaturePathDomainModelReference; +import org.eclipse.emf.ecp.view.spi.model.VResolvable; import org.eclipse.emf.ecp.view.spi.model.VView; import org.eclipse.emf.ecp.view.spi.model.VViewPackage; /** * <!-- begin-user-doc --> The <b>Adapter Factory</b> for the model. It provides - * an adapter <code>createXXX</code> method for each class of the model. <!-- + * an adapter <code>createXXX</code> method for each class of the model. + * @since 1.2 <!-- * end-user-doc --> - * + * * @see org.eclipse.emf.ecp.view.spi.model.VViewPackage * @generated - * @since 1.2 */ public class ViewAdapterFactory extends AdapterFactoryImpl { /** * The cached model package. * <!-- begin-user-doc --> <!-- end-user-doc --> - * + * * @generated */ protected static VViewPackage modelPackage; @@ -49,7 +50,7 @@ * Creates an instance of the adapter factory. * <!-- begin-user-doc --> <!-- * end-user-doc --> - * + * * @generated */ public ViewAdapterFactory() { @@ -64,7 +65,7 @@ * <!-- begin-user-doc --> This implementation returns <code>true</code> if * the object is either the model's package or is an instance object of the * model. <!-- end-user-doc --> - * + * * @return whether this factory is applicable for the type of the object. * @generated */ @@ -84,11 +85,11 @@ /** * The switch that delegates to the <code>createXXX</code> methods. <!-- * begin-user-doc --> <!-- end-user-doc --> - * + * * @generated */ protected ViewSwitch<Adapter> modelSwitch = new ViewSwitch<Adapter>() - { + { @Override public Adapter caseDiagnostic(VDiagnostic object) { @@ -150,206 +151,229 @@ } @Override + public Adapter caseResolvable(VResolvable object) + { + return createResolvableAdapter(); + } + + @Override public Adapter defaultCase(EObject object) { return createEObjectAdapter(); } - }; + }; - /** - * Creates an adapter for the <code>target</code>. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param target the object to adapt. - * @return the adapter for the <code>target</code>. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject) target); - } + /** + * Creates an adapter for the <code>target</code>. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @param target the object to adapt. + * @return the adapter for the <code>target</code>. + * @generated + */ + @Override + public Adapter createAdapter(Notifier target) { + return modelSwitch.doSwitch((EObject) target); + } - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VElement - * <em>Element</em>}'. - * <!-- begin-user-doc --> - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * <!-- end-user-doc --> - * - * @return the new adapter. - * @see org.eclipse.emf.ecp.view.spi.model.VElement - * @generated - */ - public Adapter createElementAdapter() - { - return null; - } + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VElement + * <em>Element</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * + * @return the new adapter. + * @see org.eclipse.emf.ecp.view.spi.model.VElement + * @generated + */ + public Adapter createElementAdapter() + { + return null; + } - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VDiagnostic - * <em>Diagnostic</em>}'. - * <!-- begin-user-doc --> - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * <!-- end-user-doc --> - * - * @return the new adapter. - * @see org.eclipse.emf.ecp.view.spi.model.VDiagnostic - * @generated - */ - public Adapter createDiagnosticAdapter() - { - return null; - } + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VDiagnostic + * <em>Diagnostic</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * + * @return the new adapter. + * @see org.eclipse.emf.ecp.view.spi.model.VDiagnostic + * @generated + */ + public Adapter createDiagnosticAdapter() + { + return null; + } - /** - * Creates a new adapter for an object of class ' {@link org.eclipse.emf.ecp.view.spi.model.VView <em>View</em>}'. - * <!-- - * begin-user-doc --> This default implementation returns null so that we - * can easily ignore cases; it's useful to ignore a case when inheritance - * will catch all the cases anyway. <!-- end-user-doc --> - * - * @return the new adapter. - * @see org.eclipse.emf.ecp.view.spi.model.VView - * @generated - */ - public Adapter createViewAdapter() { - return null; - } + /** + * Creates a new adapter for an object of class ' {@link org.eclipse.emf.ecp.view.spi.model.VView <em>View</em>}'. + * <!-- + * begin-user-doc --> This default implementation returns null so that we + * can easily ignore cases; it's useful to ignore a case when inheritance + * will catch all the cases anyway. <!-- end-user-doc --> + * + * @return the new adapter. + * @see org.eclipse.emf.ecp.view.spi.model.VView + * @generated + */ + public Adapter createViewAdapter() { + return null; + } - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VContainedElement - * <em>Contained Element</em>}'. - * <!-- begin-user-doc --> - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * <!-- end-user-doc --> - * - * @return the new adapter. - * @see org.eclipse.emf.ecp.view.spi.model.VContainedElement - * @generated - */ - public Adapter createContainedElementAdapter() - { - return null; - } + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VContainedElement + * <em>Contained Element</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * + * @return the new adapter. + * @see org.eclipse.emf.ecp.view.spi.model.VContainedElement + * @generated + */ + public Adapter createContainedElementAdapter() + { + return null; + } - /** - * Creates a new adapter for an object of class ' {@link org.eclipse.emf.ecp.view.spi.model.VControl - * <em>Control</em>}'. - * <!-- - * begin-user-doc --> This default implementation returns null so that we - * can easily ignore cases; it's useful to ignore a case when inheritance - * will catch all the cases anyway. <!-- end-user-doc --> - * - * @return the new adapter. - * @see org.eclipse.emf.ecp.view.spi.model.VControl - * @generated - */ - public Adapter createControlAdapter() { - return null; - } + /** + * Creates a new adapter for an object of class ' {@link org.eclipse.emf.ecp.view.spi.model.VControl + * <em>Control</em>}'. + * <!-- + * begin-user-doc --> This default implementation returns null so that we + * can easily ignore cases; it's useful to ignore a case when inheritance + * will catch all the cases anyway. <!-- end-user-doc --> + * + * @return the new adapter. + * @see org.eclipse.emf.ecp.view.spi.model.VControl + * @generated + */ + public Adapter createControlAdapter() { + return null; + } - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VContainer - * <em>Container</em>}'. - * <!-- begin-user-doc --> - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * <!-- end-user-doc --> - * - * @return the new adapter. - * @see org.eclipse.emf.ecp.view.spi.model.VContainer - * @generated - */ - public Adapter createContainerAdapter() - { - return null; - } + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VResolvable + * <em>Resolvable</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * + * @return the new adapter. + * @see org.eclipse.emf.ecp.view.spi.model.VResolvable + * @generated + */ + public Adapter createResolvableAdapter() + { + return null; + } - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VContainedContainer - * <em>Contained Container</em>}'. - * <!-- begin-user-doc --> - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * <!-- end-user-doc --> - * - * @return the new adapter. - * @see org.eclipse.emf.ecp.view.spi.model.VContainedContainer - * @generated - * @since 1.4 - */ - public Adapter createContainedContainerAdapter() - { - return null; - } + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VContainer + * <em>Container</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * + * @return the new adapter. + * @see org.eclipse.emf.ecp.view.spi.model.VContainer + * @generated + */ + public Adapter createContainerAdapter() + { + return null; + } - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VDomainModelReference - * <em>Domain Model Reference</em>}'. - * <!-- begin-user-doc --> - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * <!-- end-user-doc --> - * - * @return the new adapter. - * @see org.eclipse.emf.ecp.view.spi.model.VDomainModelReference - * @generated - */ - public Adapter createDomainModelReferenceAdapter() - { - return null; - } + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VContainedContainer + * <em>Contained Container</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * @since 1.4 + * <!-- end-user-doc --> + * + * @return the new adapter. + * @see org.eclipse.emf.ecp.view.spi.model.VContainedContainer + * @generated + */ + public Adapter createContainedContainerAdapter() + { + return null; + } - /** - * Creates a new adapter for an object of class ' - * {@link org.eclipse.emf.ecp.view.spi.model.VFeaturePathDomainModelReference - * <em>Feature Path Domain Model Reference</em>}'. - * <!-- begin-user-doc --> - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * <!-- end-user-doc --> - * - * @return the new adapter. - * @see org.eclipse.emf.ecp.view.spi.model.VFeaturePathDomainModelReference - * @generated - */ - public Adapter createFeaturePathDomainModelReferenceAdapter() - { - return null; - } + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VDomainModelReference + * <em>Domain Model Reference</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * + * @return the new adapter. + * @see org.eclipse.emf.ecp.view.spi.model.VDomainModelReference + * @generated + */ + public Adapter createDomainModelReferenceAdapter() + { + return null; + } - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VAttachment - * <em>Attachment</em>}'. - * <!-- begin-user-doc --> - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * <!-- end-user-doc --> - * - * @return the new adapter. - * @see org.eclipse.emf.ecp.view.spi.model.VAttachment - * @generated - */ - public Adapter createAttachmentAdapter() - { - return null; - } + /** + * Creates a new adapter for an object of class ' + * {@link org.eclipse.emf.ecp.view.spi.model.VFeaturePathDomainModelReference + * <em>Feature Path Domain Model Reference</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * + * @return the new adapter. + * @see org.eclipse.emf.ecp.view.spi.model.VFeaturePathDomainModelReference + * @generated + */ + public Adapter createFeaturePathDomainModelReferenceAdapter() + { + return null; + } - /** - * Creates a new adapter for the default case. - * <!-- begin-user-doc --> - * This default implementation returns null. - * <!-- end-user-doc --> - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VAttachment + * <em>Attachment</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * + * @return the new adapter. + * @see org.eclipse.emf.ecp.view.spi.model.VAttachment + * @generated + */ + public Adapter createAttachmentAdapter() + { + return null; + } + + /** + * Creates a new adapter for the default case. + * <!-- begin-user-doc --> + * This default implementation returns null. + * <!-- end-user-doc --> + * + * @return the new adapter. + * @generated + */ + public Adapter createEObjectAdapter() { + return null; + } } // ViewAdapterFactory
diff --git a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/util/ViewModelUtil.java b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/util/ViewModelUtil.java index 246d060..2fcf560 100644 --- a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/util/ViewModelUtil.java +++ b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/util/ViewModelUtil.java
@@ -14,9 +14,8 @@ import org.eclipse.core.runtime.Platform; import org.eclipse.emf.common.util.TreeIterator; import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecp.view.spi.model.VContainedElement; -import org.eclipse.emf.ecp.view.spi.model.VControl; import org.eclipse.emf.ecp.view.spi.model.VDomainModelReference; +import org.eclipse.emf.ecp.view.spi.model.VResolvable; import org.eclipse.emf.ecp.view.spi.model.impl.Activator; import org.eclipse.emf.ecp.view.spi.model.reporting.DomainModelReferenceResolutionFailedReport; @@ -58,40 +57,17 @@ } private static void checkAndResolve(EObject renderable, EObject domainModelRoot) { - if (VControl.class.isInstance(renderable)) { - final VControl control = (VControl) renderable; - if (control.getDomainModelReference() == null) { - return; - } - final boolean init = control.getDomainModelReference().init(domainModelRoot); - if (!init && ViewModelUtil.isDebugMode()) { - // report only in debug mode - Activator.getDefault() - .getReportService() - .report( - new DomainModelReferenceResolutionFailedReport( - control.getDomainModelReference(), - control)); - } - } - // XXX get rid of the following code as soon as possible! - else if (VContainedElement.class.isInstance(renderable)) { - final VContainedElement element = VContainedElement.class.cast(renderable); - if (!ORG_ECLIPSE_EMF_ECP_VIEW_SPI_LABEL_MODEL_V_LABEL.equals(element.eClass().getInstanceClassName())) { - return; - } - for (final EObject object : element.eContents()) { - if (VDomainModelReference.class.isInstance(object)) { - final boolean init = VDomainModelReference.class.cast(object).init(domainModelRoot); - if (!init && ViewModelUtil.isDebugMode()) { - // report only in debug mode - Activator.getDefault() - .getReportService() - .report( - new DomainModelReferenceResolutionFailedReport( - VDomainModelReference.class.cast(object), - element)); - } + if (VResolvable.class.isInstance(renderable)) { + final VResolvable resolvable = (VResolvable) renderable; + for (final VDomainModelReference dmr : resolvable.getDomainModelReferencesToResolve()) { + if (dmr == null) { + return; + } + final boolean init = dmr.init(domainModelRoot); + if (!init && ViewModelUtil.isDebugMode()) { + // report only in debug mode + Activator.getDefault().getReportService() + .report(new DomainModelReferenceResolutionFailedReport(dmr, resolvable)); } } }
diff --git a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/util/ViewSwitch.java b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/util/ViewSwitch.java index a7f78aa..1ca3984 100644 --- a/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/util/ViewSwitch.java +++ b/bundles/org.eclipse.emf.ecp.view.model/src/org/eclipse/emf/ecp/view/spi/model/util/ViewSwitch.java
@@ -1,11 +1,11 @@ /** * Copyright (c) 2011-2013 EclipseSource Muenchen GmbH 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: * Eugen Neufeld - initial API and implementation */ @@ -23,6 +23,7 @@ import org.eclipse.emf.ecp.view.spi.model.VDomainModelReference; import org.eclipse.emf.ecp.view.spi.model.VElement; import org.eclipse.emf.ecp.view.spi.model.VFeaturePathDomainModelReference; +import org.eclipse.emf.ecp.view.spi.model.VResolvable; import org.eclipse.emf.ecp.view.spi.model.VView; import org.eclipse.emf.ecp.view.spi.model.VViewPackage; @@ -32,17 +33,17 @@ * for each class of the model, * starting with the actual class of the object and proceeding up the * inheritance hierarchy until a non-null result is returned, which is the - * result of the switch. <!-- end-user-doc --> - * + * result of the switch. + * @since 1.2 <!-- end-user-doc --> + * * @see org.eclipse.emf.ecp.view.spi.model.VViewPackage * @generated - * @since 1.2 */ public class ViewSwitch<T> extends Switch<T> { /** * The cached model package * <!-- begin-user-doc --> <!-- end-user-doc --> - * + * * @generated */ protected static VViewPackage modelPackage; @@ -51,7 +52,7 @@ * Creates an instance of the switch. * <!-- begin-user-doc --> <!-- * end-user-doc --> - * + * * @generated */ public ViewSwitch() { @@ -64,7 +65,7 @@ /** * Checks whether this is a switch for the given package. <!-- * begin-user-doc --> <!-- end-user-doc --> - * + * * @parameter ePackage the package in question. * @return whether this is a switch for the given package. * @generated @@ -79,7 +80,7 @@ * result. * <!-- begin-user-doc --> <!-- * end-user-doc --> - * + * * @return the first non-null result returned by a <code>caseXXX</code> call. * @generated */ @@ -187,6 +188,9 @@ result = caseContainedElement(control); } if (result == null) { + result = caseResolvable(control); + } + if (result == null) { result = caseElement(control); } if (result == null) { @@ -194,6 +198,14 @@ } return result; } + case VViewPackage.RESOLVABLE: { + final VResolvable resolvable = (VResolvable) theEObject; + T result = caseResolvable(resolvable); + if (result == null) { + result = defaultCase(theEObject); + } + return result; + } default: return defaultCase(theEObject); } @@ -205,7 +217,7 @@ * This implementation returns null; * returning a non-null result will terminate the switch. * <!-- end-user-doc --> - * + * * @param object the target of the switch. * @return the result of interpreting the object as an instance of '<em>Element</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) @@ -222,7 +234,7 @@ * This implementation returns null; * returning a non-null result will terminate the switch. * <!-- end-user-doc --> - * + * * @param object the target of the switch. * @return the result of interpreting the object as an instance of '<em>Diagnostic</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) @@ -238,7 +250,7 @@ * implementation returns null; * returning a non-null result will terminate the switch. <!-- end-user-doc * --> - * + * * @param object * the target of the switch. * @return the result of interpreting the object as an instance of ' <em>View</em>'. @@ -255,7 +267,7 @@ * This implementation returns null; * returning a non-null result will terminate the switch. * <!-- end-user-doc --> - * + * * @param object the target of the switch. * @return the result of interpreting the object as an instance of '<em>Contained Element</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) @@ -272,7 +284,7 @@ * This implementation returns null; * returning a non-null result will terminate the switch. * <!-- end-user-doc --> - * + * * @param object the target of the switch. * @return the result of interpreting the object as an instance of '<em>Container</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) @@ -288,13 +300,13 @@ * <!-- begin-user-doc --> * This implementation returns null; * returning a non-null result will terminate the switch. + * @since 1.4 * <!-- end-user-doc --> - * + * * @param object the target of the switch. * @return the result of interpreting the object as an instance of '<em>Contained Container</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) * @generated - * @since 1.4 */ public T caseContainedContainer(VContainedContainer object) { @@ -307,7 +319,7 @@ * implementation returns * null; returning a non-null result will terminate the switch. <!-- * end-user-doc --> - * + * * @param object the target of the switch. * @return the result of interpreting the object as an instance of '<em>Control</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) @@ -318,12 +330,29 @@ } /** + * Returns the result of interpreting the object as an instance of '<em>Resolvable</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Resolvable</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseResolvable(VResolvable object) + { + return null; + } + + /** * Returns the result of interpreting the object as an instance of '<em>Domain Model Reference</em>'. * <!-- begin-user-doc --> * This implementation returns null; * returning a non-null result will terminate the switch. * <!-- end-user-doc --> - * + * * @param object the target of the switch. * @return the result of interpreting the object as an instance of '<em>Domain Model Reference</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) @@ -340,7 +369,7 @@ * This implementation returns null; * returning a non-null result will terminate the switch. * <!-- end-user-doc --> - * + * * @param object the target of the switch. * @return the result of interpreting the object as an instance of '<em>Feature Path Domain Model Reference</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) @@ -357,7 +386,7 @@ * This implementation returns null; * returning a non-null result will terminate the switch. * <!-- end-user-doc --> - * + * * @param object the target of the switch. * @return the result of interpreting the object as an instance of '<em>Attachment</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) @@ -374,7 +403,7 @@ * This implementation returns null; * returning a non-null result will terminate the switch, but this is the last case anyway. * <!-- end-user-doc --> - * + * * @param object the target of the switch. * @return the result of interpreting the object as an instance of '<em>EObject</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject)