Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEike Stepper2010-02-05 05:41:53 -0500
committerEike Stepper2010-02-05 05:41:53 -0500
commit9945444baa1a2cb3c7a49859b9845567d527a1fd (patch)
treece4f3db07c43b86e19b55a5ca245638b42a5a46d /plugins/org.eclipse.emf.cdo.tests.model2
parent89bdb56d4cf31e285c34f0f76654760e5b2c105c (diff)
downloadcdo-9945444baa1a2cb3c7a49859b9845567d527a1fd.tar.gz
cdo-9945444baa1a2cb3c7a49859b9845567d527a1fd.tar.xz
cdo-9945444baa1a2cb3c7a49859b9845567d527a1fd.zip
fixed warnings
Diffstat (limited to 'plugins/org.eclipse.emf.cdo.tests.model2')
-rw-r--r--plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Model2PackageImpl.java28
-rw-r--r--plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/PersistentContainmentImpl.java6
-rw-r--r--plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/SpecialPurchaseOrderImpl.java16
-rw-r--r--plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/TaskImpl.java24
-rw-r--r--plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/TransientContainerImpl.java24
-rw-r--r--plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Unsettable1Impl.java90
-rw-r--r--plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Unsettable2WithDefaultImpl.java90
-rw-r--r--plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/util/Model2Switch.java18
-rw-r--r--plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/model2/impl/Model2PackageImpl.java28
-rw-r--r--plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/model2/util/Model2Switch.java18
10 files changed, 314 insertions, 28 deletions
diff --git a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Model2PackageImpl.java b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Model2PackageImpl.java
index d9504db2ae..1331a2f517 100644
--- a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Model2PackageImpl.java
+++ b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Model2PackageImpl.java
@@ -123,7 +123,9 @@ public class Model2PackageImpl extends EPackageImpl implements Model2Package
public static Model2Package init()
{
if (isInited)
+ {
return (Model2Package)EPackage.Registry.INSTANCE.getEPackage(Model2Package.eNS_URI);
+ }
// Obtain or create and register package
Model2PackageImpl theModel2Package = (Model2PackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof Model2PackageImpl ? EPackage.Registry.INSTANCE
@@ -585,7 +587,9 @@ public class Model2PackageImpl extends EPackageImpl implements Model2Package
public void createPackageContents()
{
if (isCreated)
+ {
return;
+ }
isCreated = true;
// Create classes and their features
@@ -654,7 +658,9 @@ public class Model2PackageImpl extends EPackageImpl implements Model2Package
public void initializePackageContents()
{
if (isInitialized)
+ {
return;
+ }
isInitialized = true;
// Initialize package
@@ -684,14 +690,14 @@ public class Model2PackageImpl extends EPackageImpl implements Model2Package
initEClass(taskContainerEClass, TaskContainer.class, "TaskContainer", !IS_ABSTRACT, !IS_INTERFACE,
IS_GENERATED_INSTANCE_CLASS);
- initEReference(getTaskContainer_Tasks(), this.getTask(), this.getTask_TaskContainer(), "tasks", null, 0, -1,
+ initEReference(getTaskContainer_Tasks(), getTask(), getTask_TaskContainer(), "tasks", null, 0, -1,
TaskContainer.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES,
!IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(taskEClass, Task.class, "Task", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEReference(getTask_TaskContainer(), this.getTaskContainer(), this.getTaskContainer_Tasks(), "taskContainer",
- null, 0, 1, Task.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES,
- !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getTask_TaskContainer(), getTaskContainer(), getTaskContainer_Tasks(), "taskContainer", null, 0, 1,
+ Task.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE,
+ IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getTask_Description(), ecorePackage.getEString(), "description", null, 0, 1, Task.class,
!IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getTask_Done(), ecorePackage.getEBoolean(), "done", null, 0, 1, Task.class, !IS_TRANSIENT,
@@ -774,10 +780,9 @@ public class Model2PackageImpl extends EPackageImpl implements Model2Package
initEAttribute(getPersistentContainment_AttrBefore(), ecorePackage.getEString(), "attrBefore", null, 0, 1,
PersistentContainment.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
!IS_DERIVED, IS_ORDERED);
- initEReference(getPersistentContainment_Children(), this.getTransientContainer(), this
- .getTransientContainer_Parent(), "children", null, 0, -1, PersistentContainment.class, !IS_TRANSIENT,
- !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED,
- !IS_ORDERED);
+ initEReference(getPersistentContainment_Children(), getTransientContainer(), getTransientContainer_Parent(),
+ "children", null, 0, -1, PersistentContainment.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE,
+ !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED);
initEAttribute(getPersistentContainment_AttrAfter(), ecorePackage.getEString(), "attrAfter", null, 0, 1,
PersistentContainment.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
!IS_DERIVED, IS_ORDERED);
@@ -787,10 +792,9 @@ public class Model2PackageImpl extends EPackageImpl implements Model2Package
initEAttribute(getTransientContainer_AttrBefore(), ecorePackage.getEString(), "attrBefore", null, 0, 1,
TransientContainer.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
!IS_DERIVED, IS_ORDERED);
- initEReference(getTransientContainer_Parent(), this.getPersistentContainment(), this
- .getPersistentContainment_Children(), "parent", null, 0, 1, TransientContainer.class, IS_TRANSIENT,
- !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED,
- IS_ORDERED);
+ initEReference(getTransientContainer_Parent(), getPersistentContainment(), getPersistentContainment_Children(),
+ "parent", null, 0, 1, TransientContainer.class, IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE,
+ !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getTransientContainer_AttrAfter(), ecorePackage.getEString(), "attrAfter", null, 0, 1,
TransientContainer.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
!IS_DERIVED, IS_ORDERED);
diff --git a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/PersistentContainmentImpl.java b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/PersistentContainmentImpl.java
index 9af57bfba1..6505b90b65 100644
--- a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/PersistentContainmentImpl.java
+++ b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/PersistentContainmentImpl.java
@@ -134,8 +134,10 @@ public class PersistentContainmentImpl extends EObjectImpl implements Persistent
String oldAttrBefore = attrBefore;
attrBefore = newAttrBefore;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.PERSISTENT_CONTAINMENT__ATTR_BEFORE,
oldAttrBefore, attrBefore));
+ }
}
/**
@@ -173,8 +175,10 @@ public class PersistentContainmentImpl extends EObjectImpl implements Persistent
String oldAttrAfter = attrAfter;
attrAfter = newAttrAfter;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.PERSISTENT_CONTAINMENT__ATTR_AFTER,
oldAttrAfter, attrAfter));
+ }
}
/**
@@ -307,7 +311,9 @@ public class PersistentContainmentImpl extends EObjectImpl implements Persistent
public String toString()
{
if (eIsProxy())
+ {
return super.toString();
+ }
StringBuffer result = new StringBuffer(super.toString());
result.append(" (attrBefore: ");
diff --git a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/SpecialPurchaseOrderImpl.java b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/SpecialPurchaseOrderImpl.java
index 9d1b910200..dc465615f5 100644
--- a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/SpecialPurchaseOrderImpl.java
+++ b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/SpecialPurchaseOrderImpl.java
@@ -109,8 +109,10 @@ public class SpecialPurchaseOrderImpl extends PurchaseOrderImpl implements Speci
String oldDiscountCode = discountCode;
discountCode = newDiscountCode;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.SPECIAL_PURCHASE_ORDER__DISCOUNT_CODE,
oldDiscountCode, discountCode));
+ }
}
/**
@@ -137,9 +139,13 @@ public class SpecialPurchaseOrderImpl extends PurchaseOrderImpl implements Speci
ENotificationImpl notification = new ENotificationImpl(this, Notification.SET,
Model2Package.SPECIAL_PURCHASE_ORDER__SHIPPING_ADDRESS, oldShippingAddress, newShippingAddress);
if (msgs == null)
+ {
msgs = notification;
+ }
else
+ {
msgs.add(notification);
+ }
}
return msgs;
}
@@ -155,18 +161,26 @@ public class SpecialPurchaseOrderImpl extends PurchaseOrderImpl implements Speci
{
NotificationChain msgs = null;
if (shippingAddress != null)
+ {
msgs = ((InternalEObject)shippingAddress).eInverseRemove(this, EOPPOSITE_FEATURE_BASE
- Model2Package.SPECIAL_PURCHASE_ORDER__SHIPPING_ADDRESS, null, msgs);
+ }
if (newShippingAddress != null)
+ {
msgs = ((InternalEObject)newShippingAddress).eInverseAdd(this, EOPPOSITE_FEATURE_BASE
- Model2Package.SPECIAL_PURCHASE_ORDER__SHIPPING_ADDRESS, null, msgs);
+ }
msgs = basicSetShippingAddress(newShippingAddress, msgs);
if (msgs != null)
+ {
msgs.dispatch();
+ }
}
else if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.SPECIAL_PURCHASE_ORDER__SHIPPING_ADDRESS,
newShippingAddress, newShippingAddress));
+ }
}
/**
@@ -270,7 +284,9 @@ public class SpecialPurchaseOrderImpl extends PurchaseOrderImpl implements Speci
public String toString()
{
if (eIsProxy())
+ {
return super.toString();
+ }
StringBuffer result = new StringBuffer(super.toString());
result.append(" (discountCode: ");
diff --git a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/TaskImpl.java b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/TaskImpl.java
index a1ce01f1c1..a2d7942935 100644
--- a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/TaskImpl.java
+++ b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/TaskImpl.java
@@ -104,7 +104,9 @@ public class TaskImpl extends EObjectImpl implements Task
public TaskContainer getTaskContainer()
{
if (eContainerFeatureID() != Model2Package.TASK__TASK_CONTAINER)
+ {
return null;
+ }
return (TaskContainer)eContainer();
}
@@ -126,24 +128,34 @@ public class TaskImpl extends EObjectImpl implements Task
*/
public void setTaskContainer(TaskContainer newTaskContainer)
{
- if (newTaskContainer != eInternalContainer()
- || (eContainerFeatureID() != Model2Package.TASK__TASK_CONTAINER && newTaskContainer != null))
+ if (newTaskContainer != eInternalContainer() || eContainerFeatureID() != Model2Package.TASK__TASK_CONTAINER
+ && newTaskContainer != null)
{
if (EcoreUtil.isAncestor(this, newTaskContainer))
+ {
throw new IllegalArgumentException("Recursive containment not allowed for " + toString());
+ }
NotificationChain msgs = null;
if (eInternalContainer() != null)
+ {
msgs = eBasicRemoveFromContainer(msgs);
+ }
if (newTaskContainer != null)
+ {
msgs = ((InternalEObject)newTaskContainer).eInverseAdd(this, Model2Package.TASK_CONTAINER__TASKS,
TaskContainer.class, msgs);
+ }
msgs = basicSetTaskContainer(newTaskContainer, msgs);
if (msgs != null)
+ {
msgs.dispatch();
+ }
}
else if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.TASK__TASK_CONTAINER, newTaskContainer,
newTaskContainer));
+ }
}
/**
@@ -166,8 +178,10 @@ public class TaskImpl extends EObjectImpl implements Task
String oldDescription = description;
description = newDescription;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.TASK__DESCRIPTION, oldDescription,
description));
+ }
}
/**
@@ -190,7 +204,9 @@ public class TaskImpl extends EObjectImpl implements Task
boolean oldDone = done;
done = newDone;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.TASK__DONE, oldDone, done));
+ }
}
/**
@@ -205,7 +221,9 @@ public class TaskImpl extends EObjectImpl implements Task
{
case Model2Package.TASK__TASK_CONTAINER:
if (eInternalContainer() != null)
+ {
msgs = eBasicRemoveFromContainer(msgs);
+ }
return basicSetTaskContainer((TaskContainer)otherEnd, msgs);
}
return super.eInverseAdd(otherEnd, featureID, msgs);
@@ -338,7 +356,9 @@ public class TaskImpl extends EObjectImpl implements Task
public String toString()
{
if (eIsProxy())
+ {
return super.toString();
+ }
StringBuffer result = new StringBuffer(super.toString());
result.append(" (description: ");
diff --git a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/TransientContainerImpl.java b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/TransientContainerImpl.java
index 2ad3c528fc..6c74a01b5a 100644
--- a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/TransientContainerImpl.java
+++ b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/TransientContainerImpl.java
@@ -119,8 +119,10 @@ public class TransientContainerImpl extends EObjectImpl implements TransientCont
String oldAttrBefore = attrBefore;
attrBefore = newAttrBefore;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.TRANSIENT_CONTAINER__ATTR_BEFORE,
oldAttrBefore, attrBefore));
+ }
}
/**
@@ -131,7 +133,9 @@ public class TransientContainerImpl extends EObjectImpl implements TransientCont
public PersistentContainment getParent()
{
if (eContainerFeatureID() != Model2Package.TRANSIENT_CONTAINER__PARENT)
+ {
return null;
+ }
return (PersistentContainment)eContainer();
}
@@ -153,24 +157,34 @@ public class TransientContainerImpl extends EObjectImpl implements TransientCont
*/
public void setParent(PersistentContainment newParent)
{
- if (newParent != eInternalContainer()
- || (eContainerFeatureID() != Model2Package.TRANSIENT_CONTAINER__PARENT && newParent != null))
+ if (newParent != eInternalContainer() || eContainerFeatureID() != Model2Package.TRANSIENT_CONTAINER__PARENT
+ && newParent != null)
{
if (EcoreUtil.isAncestor(this, newParent))
+ {
throw new IllegalArgumentException("Recursive containment not allowed for " + toString());
+ }
NotificationChain msgs = null;
if (eInternalContainer() != null)
+ {
msgs = eBasicRemoveFromContainer(msgs);
+ }
if (newParent != null)
+ {
msgs = ((InternalEObject)newParent).eInverseAdd(this, Model2Package.PERSISTENT_CONTAINMENT__CHILDREN,
PersistentContainment.class, msgs);
+ }
msgs = basicSetParent(newParent, msgs);
if (msgs != null)
+ {
msgs.dispatch();
+ }
}
else if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.TRANSIENT_CONTAINER__PARENT, newParent,
newParent));
+ }
}
/**
@@ -193,8 +207,10 @@ public class TransientContainerImpl extends EObjectImpl implements TransientCont
String oldAttrAfter = attrAfter;
attrAfter = newAttrAfter;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.TRANSIENT_CONTAINER__ATTR_AFTER,
oldAttrAfter, attrAfter));
+ }
}
/**
@@ -209,7 +225,9 @@ public class TransientContainerImpl extends EObjectImpl implements TransientCont
{
case Model2Package.TRANSIENT_CONTAINER__PARENT:
if (eInternalContainer() != null)
+ {
msgs = eBasicRemoveFromContainer(msgs);
+ }
return basicSetParent((PersistentContainment)otherEnd, msgs);
}
return super.eInverseAdd(otherEnd, featureID, msgs);
@@ -343,7 +361,9 @@ public class TransientContainerImpl extends EObjectImpl implements TransientCont
public String toString()
{
if (eIsProxy())
+ {
return super.toString();
+ }
StringBuffer result = new StringBuffer(super.toString());
result.append(" (attrBefore: ");
diff --git a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Unsettable1Impl.java b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Unsettable1Impl.java
index 373595c203..66f01bef36 100644
--- a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Unsettable1Impl.java
+++ b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Unsettable1Impl.java
@@ -400,8 +400,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
boolean oldUnsettableBooleanESet = unsettableBooleanESet;
unsettableBooleanESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE1__UNSETTABLE_BOOLEAN,
oldUnsettableBoolean, unsettableBoolean, !oldUnsettableBooleanESet));
+ }
}
/**
@@ -416,8 +418,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
unsettableBoolean = UNSETTABLE_BOOLEAN_EDEFAULT;
unsettableBooleanESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE1__UNSETTABLE_BOOLEAN,
oldUnsettableBoolean, UNSETTABLE_BOOLEAN_EDEFAULT, oldUnsettableBooleanESet));
+ }
}
/**
@@ -452,8 +456,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
boolean oldUnsettableByteESet = unsettableByteESet;
unsettableByteESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE1__UNSETTABLE_BYTE,
oldUnsettableByte, unsettableByte, !oldUnsettableByteESet));
+ }
}
/**
@@ -468,8 +474,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
unsettableByte = UNSETTABLE_BYTE_EDEFAULT;
unsettableByteESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE1__UNSETTABLE_BYTE,
oldUnsettableByte, UNSETTABLE_BYTE_EDEFAULT, oldUnsettableByteESet));
+ }
}
/**
@@ -504,8 +512,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
boolean oldUnsettableCharESet = unsettableCharESet;
unsettableCharESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE1__UNSETTABLE_CHAR,
oldUnsettableChar, unsettableChar, !oldUnsettableCharESet));
+ }
}
/**
@@ -520,8 +530,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
unsettableChar = UNSETTABLE_CHAR_EDEFAULT;
unsettableCharESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE1__UNSETTABLE_CHAR,
oldUnsettableChar, UNSETTABLE_CHAR_EDEFAULT, oldUnsettableCharESet));
+ }
}
/**
@@ -556,8 +568,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
boolean oldUnsettableDateESet = unsettableDateESet;
unsettableDateESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE1__UNSETTABLE_DATE,
oldUnsettableDate, unsettableDate, !oldUnsettableDateESet));
+ }
}
/**
@@ -572,8 +586,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
unsettableDate = UNSETTABLE_DATE_EDEFAULT;
unsettableDateESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE1__UNSETTABLE_DATE,
oldUnsettableDate, UNSETTABLE_DATE_EDEFAULT, oldUnsettableDateESet));
+ }
}
/**
@@ -608,8 +624,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
boolean oldUnsettableDoubleESet = unsettableDoubleESet;
unsettableDoubleESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE1__UNSETTABLE_DOUBLE,
oldUnsettableDouble, unsettableDouble, !oldUnsettableDoubleESet));
+ }
}
/**
@@ -624,8 +642,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
unsettableDouble = UNSETTABLE_DOUBLE_EDEFAULT;
unsettableDoubleESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE1__UNSETTABLE_DOUBLE,
oldUnsettableDouble, UNSETTABLE_DOUBLE_EDEFAULT, oldUnsettableDoubleESet));
+ }
}
/**
@@ -660,8 +680,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
boolean oldUnsettableFloatESet = unsettableFloatESet;
unsettableFloatESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE1__UNSETTABLE_FLOAT,
oldUnsettableFloat, unsettableFloat, !oldUnsettableFloatESet));
+ }
}
/**
@@ -676,8 +698,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
unsettableFloat = UNSETTABLE_FLOAT_EDEFAULT;
unsettableFloatESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE1__UNSETTABLE_FLOAT,
oldUnsettableFloat, UNSETTABLE_FLOAT_EDEFAULT, oldUnsettableFloatESet));
+ }
}
/**
@@ -712,8 +736,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
boolean oldUnsettableIntESet = unsettableIntESet;
unsettableIntESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE1__UNSETTABLE_INT,
oldUnsettableInt, unsettableInt, !oldUnsettableIntESet));
+ }
}
/**
@@ -728,8 +754,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
unsettableInt = UNSETTABLE_INT_EDEFAULT;
unsettableIntESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE1__UNSETTABLE_INT,
oldUnsettableInt, UNSETTABLE_INT_EDEFAULT, oldUnsettableIntESet));
+ }
}
/**
@@ -764,8 +792,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
boolean oldUnsettableLongESet = unsettableLongESet;
unsettableLongESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE1__UNSETTABLE_LONG,
oldUnsettableLong, unsettableLong, !oldUnsettableLongESet));
+ }
}
/**
@@ -780,8 +810,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
unsettableLong = UNSETTABLE_LONG_EDEFAULT;
unsettableLongESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE1__UNSETTABLE_LONG,
oldUnsettableLong, UNSETTABLE_LONG_EDEFAULT, oldUnsettableLongESet));
+ }
}
/**
@@ -816,8 +848,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
boolean oldUnsettableShortESet = unsettableShortESet;
unsettableShortESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE1__UNSETTABLE_SHORT,
oldUnsettableShort, unsettableShort, !oldUnsettableShortESet));
+ }
}
/**
@@ -832,8 +866,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
unsettableShort = UNSETTABLE_SHORT_EDEFAULT;
unsettableShortESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE1__UNSETTABLE_SHORT,
oldUnsettableShort, UNSETTABLE_SHORT_EDEFAULT, oldUnsettableShortESet));
+ }
}
/**
@@ -868,8 +904,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
boolean oldUnsettableStringESet = unsettableStringESet;
unsettableStringESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE1__UNSETTABLE_STRING,
oldUnsettableString, unsettableString, !oldUnsettableStringESet));
+ }
}
/**
@@ -884,8 +922,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
unsettableString = UNSETTABLE_STRING_EDEFAULT;
unsettableStringESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE1__UNSETTABLE_STRING,
oldUnsettableString, UNSETTABLE_STRING_EDEFAULT, oldUnsettableStringESet));
+ }
}
/**
@@ -920,8 +960,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
boolean oldUnsettableVATESet = unsettableVATESet;
unsettableVATESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE1__UNSETTABLE_VAT,
oldUnsettableVAT, unsettableVAT, !oldUnsettableVATESet));
+ }
}
/**
@@ -936,8 +978,10 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
unsettableVAT = UNSETTABLE_VAT_EDEFAULT;
unsettableVATESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE1__UNSETTABLE_VAT,
oldUnsettableVAT, UNSETTABLE_VAT_EDEFAULT, oldUnsettableVATESet));
+ }
}
/**
@@ -1125,64 +1169,110 @@ public class Unsettable1Impl extends EObjectImpl implements Unsettable1
public String toString()
{
if (eIsProxy())
+ {
return super.toString();
+ }
StringBuffer result = new StringBuffer(super.toString());
result.append(" (unsettableBoolean: ");
if (unsettableBooleanESet)
+ {
result.append(unsettableBoolean);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableByte: ");
if (unsettableByteESet)
+ {
result.append(unsettableByte);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableChar: ");
if (unsettableCharESet)
+ {
result.append(unsettableChar);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableDate: ");
if (unsettableDateESet)
+ {
result.append(unsettableDate);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableDouble: ");
if (unsettableDoubleESet)
+ {
result.append(unsettableDouble);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableFloat: ");
if (unsettableFloatESet)
+ {
result.append(unsettableFloat);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableInt: ");
if (unsettableIntESet)
+ {
result.append(unsettableInt);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableLong: ");
if (unsettableLongESet)
+ {
result.append(unsettableLong);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableShort: ");
if (unsettableShortESet)
+ {
result.append(unsettableShort);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableString: ");
if (unsettableStringESet)
+ {
result.append(unsettableString);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableVAT: ");
if (unsettableVATESet)
+ {
result.append(unsettableVAT);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(')');
return result.toString();
}
diff --git a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Unsettable2WithDefaultImpl.java b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Unsettable2WithDefaultImpl.java
index 4cd54c9bad..b82f85a71a 100644
--- a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Unsettable2WithDefaultImpl.java
+++ b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/impl/Unsettable2WithDefaultImpl.java
@@ -410,8 +410,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
boolean oldUnsettableBooleanESet = unsettableBooleanESet;
unsettableBooleanESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_BOOLEAN,
oldUnsettableBoolean, unsettableBoolean, !oldUnsettableBooleanESet));
+ }
}
/**
@@ -426,9 +428,11 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
unsettableBoolean = UNSETTABLE_BOOLEAN_EDEFAULT;
unsettableBooleanESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET,
Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_BOOLEAN, oldUnsettableBoolean,
UNSETTABLE_BOOLEAN_EDEFAULT, oldUnsettableBooleanESet));
+ }
}
/**
@@ -463,8 +467,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
boolean oldUnsettableByteESet = unsettableByteESet;
unsettableByteESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_BYTE,
oldUnsettableByte, unsettableByte, !oldUnsettableByteESet));
+ }
}
/**
@@ -479,8 +485,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
unsettableByte = UNSETTABLE_BYTE_EDEFAULT;
unsettableByteESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_BYTE,
oldUnsettableByte, UNSETTABLE_BYTE_EDEFAULT, oldUnsettableByteESet));
+ }
}
/**
@@ -515,8 +523,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
boolean oldUnsettableCharESet = unsettableCharESet;
unsettableCharESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_CHAR,
oldUnsettableChar, unsettableChar, !oldUnsettableCharESet));
+ }
}
/**
@@ -531,8 +541,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
unsettableChar = UNSETTABLE_CHAR_EDEFAULT;
unsettableCharESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_CHAR,
oldUnsettableChar, UNSETTABLE_CHAR_EDEFAULT, oldUnsettableCharESet));
+ }
}
/**
@@ -567,8 +579,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
boolean oldUnsettableDateESet = unsettableDateESet;
unsettableDateESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_DATE,
oldUnsettableDate, unsettableDate, !oldUnsettableDateESet));
+ }
}
/**
@@ -583,8 +597,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
unsettableDate = UNSETTABLE_DATE_EDEFAULT;
unsettableDateESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_DATE,
oldUnsettableDate, UNSETTABLE_DATE_EDEFAULT, oldUnsettableDateESet));
+ }
}
/**
@@ -619,8 +635,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
boolean oldUnsettableDoubleESet = unsettableDoubleESet;
unsettableDoubleESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_DOUBLE,
oldUnsettableDouble, unsettableDouble, !oldUnsettableDoubleESet));
+ }
}
/**
@@ -635,9 +653,11 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
unsettableDouble = UNSETTABLE_DOUBLE_EDEFAULT;
unsettableDoubleESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET,
Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_DOUBLE, oldUnsettableDouble, UNSETTABLE_DOUBLE_EDEFAULT,
oldUnsettableDoubleESet));
+ }
}
/**
@@ -672,8 +692,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
boolean oldUnsettableFloatESet = unsettableFloatESet;
unsettableFloatESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_FLOAT,
oldUnsettableFloat, unsettableFloat, !oldUnsettableFloatESet));
+ }
}
/**
@@ -688,8 +710,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
unsettableFloat = UNSETTABLE_FLOAT_EDEFAULT;
unsettableFloatESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_FLOAT,
oldUnsettableFloat, UNSETTABLE_FLOAT_EDEFAULT, oldUnsettableFloatESet));
+ }
}
/**
@@ -724,8 +748,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
boolean oldUnsettableIntESet = unsettableIntESet;
unsettableIntESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_INT,
oldUnsettableInt, unsettableInt, !oldUnsettableIntESet));
+ }
}
/**
@@ -740,8 +766,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
unsettableInt = UNSETTABLE_INT_EDEFAULT;
unsettableIntESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_INT,
oldUnsettableInt, UNSETTABLE_INT_EDEFAULT, oldUnsettableIntESet));
+ }
}
/**
@@ -776,8 +804,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
boolean oldUnsettableLongESet = unsettableLongESet;
unsettableLongESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_LONG,
oldUnsettableLong, unsettableLong, !oldUnsettableLongESet));
+ }
}
/**
@@ -792,8 +822,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
unsettableLong = UNSETTABLE_LONG_EDEFAULT;
unsettableLongESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_LONG,
oldUnsettableLong, UNSETTABLE_LONG_EDEFAULT, oldUnsettableLongESet));
+ }
}
/**
@@ -828,8 +860,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
boolean oldUnsettableShortESet = unsettableShortESet;
unsettableShortESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_SHORT,
oldUnsettableShort, unsettableShort, !oldUnsettableShortESet));
+ }
}
/**
@@ -844,8 +878,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
unsettableShort = UNSETTABLE_SHORT_EDEFAULT;
unsettableShortESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_SHORT,
oldUnsettableShort, UNSETTABLE_SHORT_EDEFAULT, oldUnsettableShortESet));
+ }
}
/**
@@ -880,8 +916,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
boolean oldUnsettableStringESet = unsettableStringESet;
unsettableStringESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_STRING,
oldUnsettableString, unsettableString, !oldUnsettableStringESet));
+ }
}
/**
@@ -896,9 +934,11 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
unsettableString = UNSETTABLE_STRING_EDEFAULT;
unsettableStringESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET,
Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_STRING, oldUnsettableString, UNSETTABLE_STRING_EDEFAULT,
oldUnsettableStringESet));
+ }
}
/**
@@ -933,8 +973,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
boolean oldUnsettableVATESet = unsettableVATESet;
unsettableVATESet = true;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.SET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_VAT,
oldUnsettableVAT, unsettableVAT, !oldUnsettableVATESet));
+ }
}
/**
@@ -949,8 +991,10 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
unsettableVAT = UNSETTABLE_VAT_EDEFAULT;
unsettableVATESet = false;
if (eNotificationRequired())
+ {
eNotify(new ENotificationImpl(this, Notification.UNSET, Model2Package.UNSETTABLE2_WITH_DEFAULT__UNSETTABLE_VAT,
oldUnsettableVAT, UNSETTABLE_VAT_EDEFAULT, oldUnsettableVATESet));
+ }
}
/**
@@ -1138,64 +1182,110 @@ public class Unsettable2WithDefaultImpl extends EObjectImpl implements Unsettabl
public String toString()
{
if (eIsProxy())
+ {
return super.toString();
+ }
StringBuffer result = new StringBuffer(super.toString());
result.append(" (unsettableBoolean: ");
if (unsettableBooleanESet)
+ {
result.append(unsettableBoolean);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableByte: ");
if (unsettableByteESet)
+ {
result.append(unsettableByte);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableChar: ");
if (unsettableCharESet)
+ {
result.append(unsettableChar);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableDate: ");
if (unsettableDateESet)
+ {
result.append(unsettableDate);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableDouble: ");
if (unsettableDoubleESet)
+ {
result.append(unsettableDouble);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableFloat: ");
if (unsettableFloatESet)
+ {
result.append(unsettableFloat);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableInt: ");
if (unsettableIntESet)
+ {
result.append(unsettableInt);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableLong: ");
if (unsettableLongESet)
+ {
result.append(unsettableLong);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableShort: ");
if (unsettableShortESet)
+ {
result.append(unsettableShort);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableString: ");
if (unsettableStringESet)
+ {
result.append(unsettableString);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(", unsettableVAT: ");
if (unsettableVATESet)
+ {
result.append(unsettableVAT);
+ }
else
+ {
result.append("<unset>");
+ }
result.append(')');
return result.toString();
}
diff --git a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/util/Model2Switch.java b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/util/Model2Switch.java
index 1e7f9ef13b..7a6f6002a3 100644
--- a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/util/Model2Switch.java
+++ b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/legacy/model2/util/Model2Switch.java
@@ -105,11 +105,17 @@ public class Model2Switch<T>
SpecialPurchaseOrder specialPurchaseOrder = (SpecialPurchaseOrder)theEObject;
T result = caseSpecialPurchaseOrder(specialPurchaseOrder);
if (result == null)
+ {
result = casePurchaseOrder(specialPurchaseOrder);
+ }
if (result == null)
+ {
result = caseOrder(specialPurchaseOrder);
+ }
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
case Model2Package.TASK_CONTAINER:
@@ -117,7 +123,9 @@ public class Model2Switch<T>
TaskContainer taskContainer = (TaskContainer)theEObject;
T result = caseTaskContainer(taskContainer);
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
case Model2Package.TASK:
@@ -125,7 +133,9 @@ public class Model2Switch<T>
Task task = (Task)theEObject;
T result = caseTask(task);
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
case Model2Package.UNSETTABLE1:
@@ -133,7 +143,9 @@ public class Model2Switch<T>
Unsettable1 unsettable1 = (Unsettable1)theEObject;
T result = caseUnsettable1(unsettable1);
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
case Model2Package.UNSETTABLE2_WITH_DEFAULT:
@@ -141,7 +153,9 @@ public class Model2Switch<T>
Unsettable2WithDefault unsettable2WithDefault = (Unsettable2WithDefault)theEObject;
T result = caseUnsettable2WithDefault(unsettable2WithDefault);
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
case Model2Package.PERSISTENT_CONTAINMENT:
@@ -149,7 +163,9 @@ public class Model2Switch<T>
PersistentContainment persistentContainment = (PersistentContainment)theEObject;
T result = casePersistentContainment(persistentContainment);
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
case Model2Package.TRANSIENT_CONTAINER:
@@ -157,7 +173,9 @@ public class Model2Switch<T>
TransientContainer transientContainer = (TransientContainer)theEObject;
T result = caseTransientContainer(transientContainer);
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
default:
diff --git a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/model2/impl/Model2PackageImpl.java b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/model2/impl/Model2PackageImpl.java
index 720462f2ef..2df7a87c14 100644
--- a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/model2/impl/Model2PackageImpl.java
+++ b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/model2/impl/Model2PackageImpl.java
@@ -123,7 +123,9 @@ public class Model2PackageImpl extends EPackageImpl implements Model2Package
public static Model2Package init()
{
if (isInited)
+ {
return (Model2Package)EPackage.Registry.INSTANCE.getEPackage(Model2Package.eNS_URI);
+ }
// Obtain or create and register package
Model2PackageImpl theModel2Package = (Model2PackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof Model2PackageImpl ? EPackage.Registry.INSTANCE
@@ -585,7 +587,9 @@ public class Model2PackageImpl extends EPackageImpl implements Model2Package
public void createPackageContents()
{
if (isCreated)
+ {
return;
+ }
isCreated = true;
// Create classes and their features
@@ -654,7 +658,9 @@ public class Model2PackageImpl extends EPackageImpl implements Model2Package
public void initializePackageContents()
{
if (isInitialized)
+ {
return;
+ }
isInitialized = true;
// Initialize package
@@ -684,14 +690,14 @@ public class Model2PackageImpl extends EPackageImpl implements Model2Package
initEClass(taskContainerEClass, TaskContainer.class, "TaskContainer", !IS_ABSTRACT, !IS_INTERFACE,
IS_GENERATED_INSTANCE_CLASS);
- initEReference(getTaskContainer_Tasks(), this.getTask(), this.getTask_TaskContainer(), "tasks", null, 0, -1,
+ initEReference(getTaskContainer_Tasks(), getTask(), getTask_TaskContainer(), "tasks", null, 0, -1,
TaskContainer.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES,
!IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(taskEClass, Task.class, "Task", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEReference(getTask_TaskContainer(), this.getTaskContainer(), this.getTaskContainer_Tasks(), "taskContainer",
- null, 0, 1, Task.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES,
- !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getTask_TaskContainer(), getTaskContainer(), getTaskContainer_Tasks(), "taskContainer", null, 0, 1,
+ Task.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE,
+ IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getTask_Description(), ecorePackage.getEString(), "description", null, 0, 1, Task.class,
!IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getTask_Done(), ecorePackage.getEBoolean(), "done", null, 0, 1, Task.class, !IS_TRANSIENT,
@@ -774,10 +780,9 @@ public class Model2PackageImpl extends EPackageImpl implements Model2Package
initEAttribute(getPersistentContainment_AttrBefore(), ecorePackage.getEString(), "attrBefore", null, 0, 1,
PersistentContainment.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
!IS_DERIVED, IS_ORDERED);
- initEReference(getPersistentContainment_Children(), this.getTransientContainer(), this
- .getTransientContainer_Parent(), "children", null, 0, -1, PersistentContainment.class, !IS_TRANSIENT,
- !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED,
- !IS_ORDERED);
+ initEReference(getPersistentContainment_Children(), getTransientContainer(), getTransientContainer_Parent(),
+ "children", null, 0, -1, PersistentContainment.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE,
+ !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED);
initEAttribute(getPersistentContainment_AttrAfter(), ecorePackage.getEString(), "attrAfter", null, 0, 1,
PersistentContainment.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
!IS_DERIVED, IS_ORDERED);
@@ -787,10 +792,9 @@ public class Model2PackageImpl extends EPackageImpl implements Model2Package
initEAttribute(getTransientContainer_AttrBefore(), ecorePackage.getEString(), "attrBefore", null, 0, 1,
TransientContainer.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
!IS_DERIVED, IS_ORDERED);
- initEReference(getTransientContainer_Parent(), this.getPersistentContainment(), this
- .getPersistentContainment_Children(), "parent", null, 0, 1, TransientContainer.class, IS_TRANSIENT,
- !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED,
- IS_ORDERED);
+ initEReference(getTransientContainer_Parent(), getPersistentContainment(), getPersistentContainment_Children(),
+ "parent", null, 0, 1, TransientContainer.class, IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE,
+ !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getTransientContainer_AttrAfter(), ecorePackage.getEString(), "attrAfter", null, 0, 1,
TransientContainer.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
!IS_DERIVED, IS_ORDERED);
diff --git a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/model2/util/Model2Switch.java b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/model2/util/Model2Switch.java
index 82a577d16f..9c92695916 100644
--- a/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/model2/util/Model2Switch.java
+++ b/plugins/org.eclipse.emf.cdo.tests.model2/src/org/eclipse/emf/cdo/tests/model2/util/Model2Switch.java
@@ -105,11 +105,17 @@ public class Model2Switch<T>
SpecialPurchaseOrder specialPurchaseOrder = (SpecialPurchaseOrder)theEObject;
T result = caseSpecialPurchaseOrder(specialPurchaseOrder);
if (result == null)
+ {
result = casePurchaseOrder(specialPurchaseOrder);
+ }
if (result == null)
+ {
result = caseOrder(specialPurchaseOrder);
+ }
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
case Model2Package.TASK_CONTAINER:
@@ -117,7 +123,9 @@ public class Model2Switch<T>
TaskContainer taskContainer = (TaskContainer)theEObject;
T result = caseTaskContainer(taskContainer);
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
case Model2Package.TASK:
@@ -125,7 +133,9 @@ public class Model2Switch<T>
Task task = (Task)theEObject;
T result = caseTask(task);
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
case Model2Package.UNSETTABLE1:
@@ -133,7 +143,9 @@ public class Model2Switch<T>
Unsettable1 unsettable1 = (Unsettable1)theEObject;
T result = caseUnsettable1(unsettable1);
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
case Model2Package.UNSETTABLE2_WITH_DEFAULT:
@@ -141,7 +153,9 @@ public class Model2Switch<T>
Unsettable2WithDefault unsettable2WithDefault = (Unsettable2WithDefault)theEObject;
T result = caseUnsettable2WithDefault(unsettable2WithDefault);
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
case Model2Package.PERSISTENT_CONTAINMENT:
@@ -149,7 +163,9 @@ public class Model2Switch<T>
PersistentContainment persistentContainment = (PersistentContainment)theEObject;
T result = casePersistentContainment(persistentContainment);
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
case Model2Package.TRANSIENT_CONTAINER:
@@ -157,7 +173,9 @@ public class Model2Switch<T>
TransientContainer transientContainer = (TransientContainer)theEObject;
T result = caseTransientContainer(transientContainer);
if (result == null)
+ {
result = defaultCase(theEObject);
+ }
return result;
}
default:

Back to the top