Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/infra/core/org.eclipse.papyrus.infra.core.sasheditor.di/src/org/eclipse/papyrus/infra/core/sashwindows/di/impl/WindowImpl.java')
-rw-r--r--plugins/infra/core/org.eclipse.papyrus.infra.core.sasheditor.di/src/org/eclipse/papyrus/infra/core/sashwindows/di/impl/WindowImpl.java280
1 files changed, 280 insertions, 0 deletions
diff --git a/plugins/infra/core/org.eclipse.papyrus.infra.core.sasheditor.di/src/org/eclipse/papyrus/infra/core/sashwindows/di/impl/WindowImpl.java b/plugins/infra/core/org.eclipse.papyrus.infra.core.sasheditor.di/src/org/eclipse/papyrus/infra/core/sashwindows/di/impl/WindowImpl.java
new file mode 100644
index 00000000000..8a419aff6f3
--- /dev/null
+++ b/plugins/infra/core/org.eclipse.papyrus.infra.core.sasheditor.di/src/org/eclipse/papyrus/infra/core/sashwindows/di/impl/WindowImpl.java
@@ -0,0 +1,280 @@
+/**
+ * <copyright>
+ * </copyright>
+ *
+ * $Id$
+ */
+package org.eclipse.papyrus.infra.core.sashwindows.di.impl;
+
+import org.eclipse.emf.common.notify.Notification;
+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;
+import org.eclipse.papyrus.infra.core.sashwindows.di.AbstractPanel;
+import org.eclipse.papyrus.infra.core.sashwindows.di.DiPackage;
+import org.eclipse.papyrus.infra.core.sashwindows.di.Position;
+import org.eclipse.papyrus.infra.core.sashwindows.di.Size;
+import org.eclipse.papyrus.infra.core.sashwindows.di.Window;
+
+/**
+ * <!-- begin-user-doc --> An implementation of the model object ' <em><b>Window</b></em>'. <!-- end-user-doc -->
+ * <p>
+ * The following features are implemented:
+ * <ul>
+ * <li>{@link org.eclipse.papyrus.infra.core.sashwindows.di.impl.WindowImpl#getPosition
+ * <em>Position</em>}</li>
+ * <li>{@link org.eclipse.papyrus.infra.core.sashwindows.di.impl.WindowImpl#getSize <em> Size</em>}</li>
+ * <li>{@link org.eclipse.papyrus.infra.core.sashwindows.di.impl.WindowImpl#getPanel <em> Panel</em>}</li>
+ * </ul>
+ * </p>
+ *
+ * @generated
+ */
+public class WindowImpl extends PanelParentImpl implements Window {
+
+ /**
+ * The cached value of the '{@link #getPosition() <em>Position</em>}'
+ * reference. <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @see #getPosition()
+ * @generated
+ * @ordered
+ */
+ protected Position position;
+
+ /**
+ * The cached value of the '{@link #getSize() <em>Size</em>}' reference.
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @see #getSize()
+ * @generated
+ * @ordered
+ */
+ protected Size size;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ protected WindowImpl() {
+ super();
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ @Override
+ protected EClass eStaticClass() {
+ return DiPackage.Literals.WINDOW;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public Position getPosition() {
+ if(position != null && position.eIsProxy()) {
+ InternalEObject oldPosition = (InternalEObject)position;
+ position = (Position)eResolveProxy(oldPosition);
+ if(position != oldPosition) {
+ if(eNotificationRequired())
+ eNotify(new ENotificationImpl(this, Notification.RESOLVE, DiPackage.WINDOW__POSITION, oldPosition, position));
+ }
+ }
+ return position;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public Position basicGetPosition() {
+ return position;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public void setPosition(Position newPosition) {
+ Position oldPosition = position;
+ position = newPosition;
+ if(eNotificationRequired())
+ eNotify(new ENotificationImpl(this, Notification.SET, DiPackage.WINDOW__POSITION, oldPosition, position));
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public Size getSize() {
+ if(size != null && size.eIsProxy()) {
+ InternalEObject oldSize = (InternalEObject)size;
+ size = (Size)eResolveProxy(oldSize);
+ if(size != oldSize) {
+ if(eNotificationRequired())
+ eNotify(new ENotificationImpl(this, Notification.RESOLVE, DiPackage.WINDOW__SIZE, oldSize, size));
+ }
+ }
+ return size;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public Size basicGetSize() {
+ return size;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public void setSize(Size newSize) {
+ Size oldSize = size;
+ size = newSize;
+ if(eNotificationRequired())
+ eNotify(new ENotificationImpl(this, Notification.SET, DiPackage.WINDOW__SIZE, oldSize, size));
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public AbstractPanel getPanel() {
+ AbstractPanel panel = basicGetPanel();
+ return panel != null && panel.eIsProxy() ? (AbstractPanel)eResolveProxy((InternalEObject)panel) : panel;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated NOT
+ */
+ public AbstractPanel basicGetPanel() {
+ EList<AbstractPanel> list = getChildren();
+ if(list.size() > 0)
+ return list.get(0);
+ else
+ return null;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated NOT
+ */
+ public void setPanel(AbstractPanel newPanel) {
+ EList<AbstractPanel> list = getChildren();
+ if(list.size() > 0)
+ list.set(0, newPanel);
+ else
+ list.add(newPanel);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ @Override
+ public Object eGet(int featureID, boolean resolve, boolean coreType) {
+ switch(featureID) {
+ case DiPackage.WINDOW__POSITION:
+ if(resolve)
+ return getPosition();
+ return basicGetPosition();
+ case DiPackage.WINDOW__SIZE:
+ if(resolve)
+ return getSize();
+ return basicGetSize();
+ case DiPackage.WINDOW__PANEL:
+ if(resolve)
+ return getPanel();
+ return basicGetPanel();
+ }
+ return super.eGet(featureID, resolve, coreType);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ @Override
+ public void eSet(int featureID, Object newValue) {
+ switch(featureID) {
+ case DiPackage.WINDOW__POSITION:
+ setPosition((Position)newValue);
+ return;
+ case DiPackage.WINDOW__SIZE:
+ setSize((Size)newValue);
+ return;
+ case DiPackage.WINDOW__PANEL:
+ setPanel((AbstractPanel)newValue);
+ return;
+ }
+ super.eSet(featureID, newValue);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ @Override
+ public void eUnset(int featureID) {
+ switch(featureID) {
+ case DiPackage.WINDOW__POSITION:
+ setPosition((Position)null);
+ return;
+ case DiPackage.WINDOW__SIZE:
+ setSize((Size)null);
+ return;
+ case DiPackage.WINDOW__PANEL:
+ setPanel((AbstractPanel)null);
+ return;
+ }
+ super.eUnset(featureID);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ @Override
+ public boolean eIsSet(int featureID) {
+ switch(featureID) {
+ case DiPackage.WINDOW__POSITION:
+ return position != null;
+ case DiPackage.WINDOW__SIZE:
+ return size != null;
+ case DiPackage.WINDOW__PANEL:
+ return basicGetPanel() != null;
+ }
+ return super.eIsSet(featureID);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated NOT
+ */
+ public void replaceChild(AbstractPanel oldChild, AbstractPanel newChild) {
+ setPanel(newChild);
+ }
+
+} // WindowImpl

Back to the top