| /** |
| * Copyright (c) 2013 CEA LIST. |
| * |
| * |
| * All rights reserved. This program and the accompanying materials |
| * are made available under the terms of the Eclipse Public License 2.0 |
| * which accompanies this distribution, and is available at |
| * https://www.eclipse.org/legal/epl-2.0/ |
| * |
| * SPDX-License-Identifier: EPL-2.0 |
| * |
| * Contributors: |
| * Vincent Lorenzo (CEA LIST) vincent.lorenzo@cea.fr - Initial API and implementation |
| */ |
| package org.eclipse.papyrus.infra.nattable.model.cdo.nattable.nattablewrapper.impl; |
| |
| import org.eclipse.emf.ecore.EClass; |
| import org.eclipse.papyrus.infra.nattable.model.cdo.nattable.nattablestyle.impl.StyledElementImpl; |
| import org.eclipse.papyrus.infra.nattable.model.nattable.nattablewrapper.IdWrapper; |
| import org.eclipse.papyrus.infra.nattable.model.nattable.nattablewrapper.NattablewrapperPackage; |
| |
| /** |
| * <!-- begin-user-doc --> |
| * An implementation of the model object '<em><b>Id Wrapper</b></em>'. |
| * <!-- end-user-doc --> |
| * <p> |
| * The following features are implemented: |
| * </p> |
| * <ul> |
| * <li>{@link org.eclipse.papyrus.infra.nattable.model.cdo.nattable.nattablewrapper.impl.IdWrapperImpl#getElement <em>Element</em>}</li> |
| * </ul> |
| * |
| * @generated |
| */ |
| public class IdWrapperImpl extends StyledElementImpl implements IdWrapper { |
| /** |
| * The default value of the '{@link #getElement() <em>Element</em>}' attribute. |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @see #getElement() |
| * @generated |
| * @ordered |
| */ |
| protected static final String ELEMENT_EDEFAULT = null; |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| protected IdWrapperImpl() { |
| super(); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| protected EClass eStaticClass() { |
| return NattablewrapperPackage.Literals.ID_WRAPPER; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| public String getElement() { |
| return (String)eDynamicGet(NattablewrapperPackage.ID_WRAPPER__ELEMENT - ESTATIC_FEATURE_COUNT, NattablewrapperPackage.Literals.ID_WRAPPER__ELEMENT, true, true); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| public void setElement(String newElement) { |
| eDynamicSet(NattablewrapperPackage.ID_WRAPPER__ELEMENT - ESTATIC_FEATURE_COUNT, NattablewrapperPackage.Literals.ID_WRAPPER__ELEMENT, newElement); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| public Object eGet(int featureID, boolean resolve, boolean coreType) { |
| switch (featureID) { |
| case NattablewrapperPackage.ID_WRAPPER__ELEMENT: |
| return getElement(); |
| } |
| return super.eGet(featureID, resolve, coreType); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| public void eSet(int featureID, Object newValue) { |
| switch (featureID) { |
| case NattablewrapperPackage.ID_WRAPPER__ELEMENT: |
| setElement((String)newValue); |
| return; |
| } |
| super.eSet(featureID, newValue); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| public void eUnset(int featureID) { |
| switch (featureID) { |
| case NattablewrapperPackage.ID_WRAPPER__ELEMENT: |
| setElement(ELEMENT_EDEFAULT); |
| return; |
| } |
| super.eUnset(featureID); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| public boolean eIsSet(int featureID) { |
| switch (featureID) { |
| case NattablewrapperPackage.ID_WRAPPER__ELEMENT: |
| return ELEMENT_EDEFAULT == null ? getElement() != null : !ELEMENT_EDEFAULT.equals(getElement()); |
| } |
| return super.eIsSet(featureID); |
| } |
| |
| } //IdWrapperImpl |