blob: c3f6f54fb4c01899f57018e9e33ddc5051d3b496 [file] [log] [blame]
/*******************************************************************************
* Copyright (c) 2014 Xored Software Inc 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:
* Xored Software Inc - initial API and implementation and/or initial documentation
*******************************************************************************/
package org.eclipse.rcptt.ecl.platform.ui.commands.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.rcptt.ecl.core.impl.CommandImpl;
import org.eclipse.rcptt.ecl.platform.ui.commands.CommandsPackage;
import org.eclipse.rcptt.ecl.platform.ui.commands.DeleteWorkingSet;
import org.eclipse.rcptt.ecl.platform.ui.objects.WorkingSet;
/**
* <!-- begin-user-doc -->
* An implementation of the model object '<em><b>Delete Working Set</b></em>'.
* <!-- end-user-doc -->
* <p>
* The following features are implemented:
* <ul>
* <li>{@link org.eclipse.rcptt.ecl.platform.ui.commands.impl.DeleteWorkingSetImpl#getInput <em>Input</em>}</li>
* </ul>
* </p>
*
* @generated
*/
public class DeleteWorkingSetImpl extends CommandImpl implements DeleteWorkingSet {
/**
* The cached value of the '{@link #getInput() <em>Input</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getInput()
* @generated
* @ordered
*/
protected WorkingSet input;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected DeleteWorkingSetImpl() {
super();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
protected EClass eStaticClass() {
return CommandsPackage.Literals.DELETE_WORKING_SET;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public WorkingSet getInput() {
if (input != null && input.eIsProxy()) {
InternalEObject oldInput = (InternalEObject)input;
input = (WorkingSet)eResolveProxy(oldInput);
if (input != oldInput) {
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.RESOLVE, CommandsPackage.DELETE_WORKING_SET__INPUT, oldInput, input));
}
}
return input;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public WorkingSet basicGetInput() {
return input;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public void setInput(WorkingSet newInput) {
WorkingSet oldInput = input;
input = newInput;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, CommandsPackage.DELETE_WORKING_SET__INPUT, oldInput, input));
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
case CommandsPackage.DELETE_WORKING_SET__INPUT:
if (resolve) return getInput();
return basicGetInput();
}
return super.eGet(featureID, resolve, coreType);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
case CommandsPackage.DELETE_WORKING_SET__INPUT:
setInput((WorkingSet)newValue);
return;
}
super.eSet(featureID, newValue);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
case CommandsPackage.DELETE_WORKING_SET__INPUT:
setInput((WorkingSet)null);
return;
}
super.eUnset(featureID);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
case CommandsPackage.DELETE_WORKING_SET__INPUT:
return input != null;
}
return super.eIsSet(featureID);
}
} //DeleteWorkingSetImpl