| /** |
| * |
| * Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) |
| * |
| * 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: |
| * Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation |
| * |
| */ |
| package org.eclipse.osbp.ecview.extension.model.impl; |
| |
| import org.eclipse.emf.common.notify.Notification; |
| import org.eclipse.emf.ecore.EClass; |
| import org.eclipse.emf.ecore.InternalEObject; |
| import org.eclipse.emf.ecore.impl.ENotificationImpl; |
| import org.eclipse.osbp.ecview.core.common.model.core.YBeanSlot; |
| import org.eclipse.osbp.ecview.extension.model.YECviewPackage; |
| import org.eclipse.osbp.ecview.extension.model.YSubTypeSuspect; |
| |
| /** |
| * <!-- begin-user-doc --> |
| * An implementation of the model object '<em><b>YSub Type Suspect</b></em>'. |
| * <!-- end-user-doc --> |
| * <p> |
| * The following features are implemented: |
| * <ul> |
| * <li>{@link org.eclipse.osbp.ecview.extension.model.impl.YSubTypeSuspectImpl#getBeanSlot <em>Bean Slot</em>}</li> |
| * </ul> |
| * </p> |
| * |
| * @generated |
| */ |
| public class YSubTypeSuspectImpl extends YTypedCompoundSuspectImpl implements YSubTypeSuspect { |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| public static final String copyright = "All rights reserved by Loetz GmbH und CoKG Heidelberg 2015.\n\nContributors:\n Florian Pirchner - initial API and implementation"; |
| |
| /** |
| * The cached value of the '{@link #getBeanSlot() <em>Bean Slot</em>}' reference. |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @see #getBeanSlot() |
| * @generated |
| * @ordered |
| */ |
| protected YBeanSlot beanSlot; |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| protected YSubTypeSuspectImpl() { |
| super(); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| protected EClass eStaticClass() { |
| return YECviewPackage.Literals.YSUB_TYPE_SUSPECT; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| public YBeanSlot getBeanSlot() { |
| if (beanSlot != null && beanSlot.eIsProxy()) { |
| InternalEObject oldBeanSlot = (InternalEObject)beanSlot; |
| beanSlot = (YBeanSlot)eResolveProxy(oldBeanSlot); |
| if (beanSlot != oldBeanSlot) { |
| if (eNotificationRequired()) |
| eNotify(new ENotificationImpl(this, Notification.RESOLVE, YECviewPackage.YSUB_TYPE_SUSPECT__BEAN_SLOT, oldBeanSlot, beanSlot)); |
| } |
| } |
| return beanSlot; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| public YBeanSlot basicGetBeanSlot() { |
| return beanSlot; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| public void setBeanSlot(YBeanSlot newBeanSlot) { |
| YBeanSlot oldBeanSlot = beanSlot; |
| beanSlot = newBeanSlot; |
| if (eNotificationRequired()) |
| eNotify(new ENotificationImpl(this, Notification.SET, YECviewPackage.YSUB_TYPE_SUSPECT__BEAN_SLOT, oldBeanSlot, beanSlot)); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| public Object eGet(int featureID, boolean resolve, boolean coreType) { |
| switch (featureID) { |
| case YECviewPackage.YSUB_TYPE_SUSPECT__BEAN_SLOT: |
| if (resolve) return getBeanSlot(); |
| return basicGetBeanSlot(); |
| } |
| return super.eGet(featureID, resolve, coreType); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| public void eSet(int featureID, Object newValue) { |
| switch (featureID) { |
| case YECviewPackage.YSUB_TYPE_SUSPECT__BEAN_SLOT: |
| setBeanSlot((YBeanSlot)newValue); |
| return; |
| } |
| super.eSet(featureID, newValue); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| public void eUnset(int featureID) { |
| switch (featureID) { |
| case YECviewPackage.YSUB_TYPE_SUSPECT__BEAN_SLOT: |
| setBeanSlot((YBeanSlot)null); |
| return; |
| } |
| super.eUnset(featureID); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| public boolean eIsSet(int featureID) { |
| switch (featureID) { |
| case YECviewPackage.YSUB_TYPE_SUSPECT__BEAN_SLOT: |
| return beanSlot != null; |
| } |
| return super.eIsSet(featureID); |
| } |
| |
| } //YSubTypeSuspectImpl |