blob: 88977199c53265f2ccf2adea30de161e92787bda [file] [log] [blame]
/**
* *******************************************************************************
* Copyright (c) 2018 Agence spatiale canadienne / Canadian Space Agency
* 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:
* Regent L'Archeveque - initial API and implementation
*
* SPDX-License-Identifier: EPL-1.0
* *******************************************************************************
*/
package org.eclipse.apogy.core.environment.earth.orbit.planner.impl;
import java.util.Collection;
import org.eclipse.apogy.core.environment.earth.orbit.VisibilityPass;
import org.eclipse.apogy.core.environment.earth.orbit.planner.AbstractStatefulCostFunction;
import org.eclipse.apogy.core.environment.earth.orbit.planner.ApogyCoreEnvironmentEarthOrbitPlannerPackage;
import org.eclipse.apogy.core.environment.earth.orbit.planner.CostFunctionState;
import org.eclipse.apogy.core.environment.earth.orbit.planner.ObservationAnalysisPlanner;
import org.eclipse.apogy.core.environment.earth.orbit.planner.ObservationAnalysisPlannerNode;
import org.eclipse.apogy.core.environment.earth.orbit.planner.ObservationAnalysisPlannerResult;
import org.eclipse.apogy.core.environment.earth.orbit.planner.StatefulCostFunctionMapEntryValue;
import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.common.notify.NotificationChain;
import org.eclipse.emf.common.util.EList;
import org.eclipse.emf.common.util.EMap;
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.EStructuralFeature;
import org.eclipse.emf.ecore.InternalEObject;
import org.eclipse.emf.ecore.impl.ENotificationImpl;
import org.eclipse.emf.ecore.impl.MinimalEObjectImpl;
import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList;
import org.eclipse.emf.ecore.util.EcoreEMap;
import org.eclipse.emf.ecore.util.EcoreUtil;
import org.eclipse.emf.ecore.util.InternalEList;
/**
* <!-- begin-user-doc -->
* An implementation of the model object '<em><b>Observation Analysis Planner Node</b></em>'.
* <!-- end-user-doc -->
* <p>
* The following features are implemented:
* </p>
* <ul>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getResult <em>Result</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getId <em>Id</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getPass <em>Pass</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getParent <em>Parent</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getChildren <em>Children</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#isRootNode <em>Root Node</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getPlannerRootNode <em>Planner Root Node</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getPlannerResult <em>Planner Result</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getPlanner <em>Planner</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getStatefulCostsMapEntries <em>Stateful Costs Map Entries</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getCost <em>Cost</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getCumulativeCost <em>Cumulative Cost</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getFirstLevelNode <em>First Level Node</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getLevel <em>Level</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getSolutionDuration <em>Solution Duration</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getPassDuration <em>Pass Duration</em>}</li>
* <li>{@link org.eclipse.apogy.core.environment.earth.orbit.planner.impl.ObservationAnalysisPlannerNodeImpl#getTotalPassesDuration <em>Total Passes Duration</em>}</li>
* </ul>
*
* @generated
*/
public abstract class ObservationAnalysisPlannerNodeImpl extends MinimalEObjectImpl.Container implements ObservationAnalysisPlannerNode {
/**
* The default value of the '{@link #getId() <em>Id</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getId()
* @generated
* @ordered
*/
protected static final String ID_EDEFAULT = null;
/**
* The cached value of the '{@link #getId() <em>Id</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getId()
* @generated
* @ordered
*/
protected String id = ID_EDEFAULT;
/**
* The cached value of the '{@link #getPass() <em>Pass</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getPass()
* @generated
* @ordered
*/
protected VisibilityPass pass;
/**
* The cached value of the '{@link #getChildren() <em>Children</em>}' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getChildren()
* @generated
* @ordered
*/
protected EList<ObservationAnalysisPlannerNode> children;
/**
* The default value of the '{@link #isRootNode() <em>Root Node</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #isRootNode()
* @generated
* @ordered
*/
protected static final boolean ROOT_NODE_EDEFAULT = false;
/**
* The cached value of the '{@link #getStatefulCostsMapEntries() <em>Stateful Costs Map Entries</em>}' map.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getStatefulCostsMapEntries()
* @generated
* @ordered
*/
protected EMap<AbstractStatefulCostFunction<CostFunctionState>, StatefulCostFunctionMapEntryValue> statefulCostsMapEntries;
/**
* The default value of the '{@link #getCost() <em>Cost</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getCost()
* @generated
* @ordered
*/
protected static final double COST_EDEFAULT = 0.0;
/**
* The default value of the '{@link #getCumulativeCost() <em>Cumulative Cost</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getCumulativeCost()
* @generated
* @ordered
*/
protected static final double CUMULATIVE_COST_EDEFAULT = 0.0;
/**
* The default value of the '{@link #getLevel() <em>Level</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getLevel()
* @generated
* @ordered
*/
protected static final int LEVEL_EDEFAULT = 0;
/**
* The default value of the '{@link #getSolutionDuration() <em>Solution Duration</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getSolutionDuration()
* @generated
* @ordered
*/
protected static final double SOLUTION_DURATION_EDEFAULT = 0.0;
/**
* The default value of the '{@link #getPassDuration() <em>Pass Duration</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getPassDuration()
* @generated
* @ordered
*/
protected static final double PASS_DURATION_EDEFAULT = 0.0;
/**
* The default value of the '{@link #getTotalPassesDuration() <em>Total Passes Duration</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getTotalPassesDuration()
* @generated
* @ordered
*/
protected static final double TOTAL_PASSES_DURATION_EDEFAULT = 0.0;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected ObservationAnalysisPlannerNodeImpl() {
super();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
protected EClass eStaticClass() {
return ApogyCoreEnvironmentEarthOrbitPlannerPackage.Literals.OBSERVATION_ANALYSIS_PLANNER_NODE;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public ObservationAnalysisPlannerResult getResult() {
if (eContainerFeatureID() != ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__RESULT) return null;
return (ObservationAnalysisPlannerResult)eContainer();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public ObservationAnalysisPlannerResult basicGetResult() {
if (eContainerFeatureID() != ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__RESULT) return null;
return (ObservationAnalysisPlannerResult)eInternalContainer();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public NotificationChain basicSetResult(ObservationAnalysisPlannerResult newResult, NotificationChain msgs) {
msgs = eBasicSetContainer((InternalEObject)newResult, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__RESULT, msgs);
return msgs;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public void setResult(ObservationAnalysisPlannerResult newResult) {
if (newResult != eInternalContainer() || (eContainerFeatureID() != ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__RESULT && newResult != null)) {
if (EcoreUtil.isAncestor(this, newResult))
throw new IllegalArgumentException("Recursive containment not allowed for " + toString());
NotificationChain msgs = null;
if (eInternalContainer() != null)
msgs = eBasicRemoveFromContainer(msgs);
if (newResult != null)
msgs = ((InternalEObject)newResult).eInverseAdd(this, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_RESULT__PLAN_ROOT_NODE, ObservationAnalysisPlannerResult.class, msgs);
msgs = basicSetResult(newResult, msgs);
if (msgs != null) msgs.dispatch();
}
else if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__RESULT, newResult, newResult));
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public String getId() {
return id;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public void setId(String newId) {
String oldId = id;
id = newId;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__ID, oldId, id));
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public VisibilityPass getPass() {
if (pass != null && pass.eIsProxy()) {
InternalEObject oldPass = (InternalEObject)pass;
pass = (VisibilityPass)eResolveProxy(oldPass);
if (pass != oldPass) {
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.RESOLVE, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PASS, oldPass, pass));
}
}
return pass;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public VisibilityPass basicGetPass() {
return pass;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public void setPass(VisibilityPass newPass) {
VisibilityPass oldPass = pass;
pass = newPass;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PASS, oldPass, pass));
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public ObservationAnalysisPlannerNode getParent() {
if (eContainerFeatureID() != ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PARENT) return null;
return (ObservationAnalysisPlannerNode)eContainer();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public ObservationAnalysisPlannerNode basicGetParent() {
if (eContainerFeatureID() != ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PARENT) return null;
return (ObservationAnalysisPlannerNode)eInternalContainer();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public NotificationChain basicSetParent(ObservationAnalysisPlannerNode newParent, NotificationChain msgs) {
msgs = eBasicSetContainer((InternalEObject)newParent, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PARENT, msgs);
return msgs;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public void setParent(ObservationAnalysisPlannerNode newParent) {
if (newParent != eInternalContainer() || (eContainerFeatureID() != ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__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, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__CHILDREN, ObservationAnalysisPlannerNode.class, msgs);
msgs = basicSetParent(newParent, msgs);
if (msgs != null) msgs.dispatch();
}
else if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PARENT, newParent, newParent));
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public EList<ObservationAnalysisPlannerNode> getChildren() {
if (children == null) {
children = new EObjectContainmentWithInverseEList<ObservationAnalysisPlannerNode>(ObservationAnalysisPlannerNode.class, this, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__CHILDREN, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PARENT);
}
return children;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public boolean isRootNode() {
ObservationAnalysisPlannerNode _parent = this.getParent();
return (_parent == null);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public ObservationAnalysisPlannerNode getPlannerRootNode() {
ObservationAnalysisPlannerNode _parent = this.getParent();
boolean _tripleEquals = (_parent == null);
if (_tripleEquals) {
return this;
}
else {
return this.getParent().getPlannerRootNode();
}
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public ObservationAnalysisPlannerResult getPlannerResult() {
ObservationAnalysisPlannerNode _plannerRootNode = this.getPlannerRootNode();
boolean _tripleEquals = (_plannerRootNode == null);
if (_tripleEquals) {
return null;
}
else {
return this.getPlannerRootNode().getResult();
}
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public ObservationAnalysisPlanner getPlanner() {
ObservationAnalysisPlannerResult _result = this.getPlannerRootNode().getResult();
boolean _tripleEquals = (_result == null);
if (_tripleEquals) {
return null;
}
else {
return this.getPlannerResult().getPlanner();
}
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public EMap<AbstractStatefulCostFunction<CostFunctionState>, StatefulCostFunctionMapEntryValue> getStatefulCostsMapEntries() {
if (statefulCostsMapEntries == null) {
statefulCostsMapEntries = new EcoreEMap<AbstractStatefulCostFunction<CostFunctionState>,StatefulCostFunctionMapEntryValue>(ApogyCoreEnvironmentEarthOrbitPlannerPackage.Literals.STATEFUL_COST_FUNCTION_MAP_ENTRY, StatefulCostFunctionMapEntryImpl.class, this, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__STATEFUL_COSTS_MAP_ENTRIES);
}
return statefulCostsMapEntries;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public double getCost() {
// TODO: implement this method to return the 'Cost' attribute
// Ensure that you remove @generated or mark it @generated NOT
throw new UnsupportedOperationException();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public double getCumulativeCost() {
// TODO: implement this method to return the 'Cumulative Cost' attribute
// Ensure that you remove @generated or mark it @generated NOT
throw new UnsupportedOperationException();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public ObservationAnalysisPlannerNode getFirstLevelNode() {
ObservationAnalysisPlannerNode firstLevelNode = basicGetFirstLevelNode();
return firstLevelNode != null && firstLevelNode.eIsProxy() ? (ObservationAnalysisPlannerNode)eResolveProxy((InternalEObject)firstLevelNode) : firstLevelNode;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public ObservationAnalysisPlannerNode basicGetFirstLevelNode() {
// TODO: implement this method to return the 'First Level Node' reference
// -> do not perform proxy resolution
// Ensure that you remove @generated or mark it @generated NOT
throw new UnsupportedOperationException();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public int getLevel() {
// TODO: implement this method to return the 'Level' attribute
// Ensure that you remove @generated or mark it @generated NOT
throw new UnsupportedOperationException();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public double getSolutionDuration() {
// TODO: implement this method to return the 'Solution Duration' attribute
// Ensure that you remove @generated or mark it @generated NOT
throw new UnsupportedOperationException();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public double getPassDuration() {
// TODO: implement this method to return the 'Pass Duration' attribute
// Ensure that you remove @generated or mark it @generated NOT
throw new UnsupportedOperationException();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public double getTotalPassesDuration() {
// TODO: implement this method to return the 'Total Passes Duration' attribute
// Ensure that you remove @generated or mark it @generated NOT
throw new UnsupportedOperationException();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__RESULT:
if (eInternalContainer() != null)
msgs = eBasicRemoveFromContainer(msgs);
return basicSetResult((ObservationAnalysisPlannerResult)otherEnd, msgs);
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PARENT:
if (eInternalContainer() != null)
msgs = eBasicRemoveFromContainer(msgs);
return basicSetParent((ObservationAnalysisPlannerNode)otherEnd, msgs);
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__CHILDREN:
return ((InternalEList<InternalEObject>)(InternalEList<?>)getChildren()).basicAdd(otherEnd, msgs);
}
return super.eInverseAdd(otherEnd, featureID, msgs);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__RESULT:
return basicSetResult(null, msgs);
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PARENT:
return basicSetParent(null, msgs);
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__CHILDREN:
return ((InternalEList<?>)getChildren()).basicRemove(otherEnd, msgs);
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__STATEFUL_COSTS_MAP_ENTRIES:
return ((InternalEList<?>)getStatefulCostsMapEntries()).basicRemove(otherEnd, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) {
switch (eContainerFeatureID()) {
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__RESULT:
return eInternalContainer().eInverseRemove(this, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_RESULT__PLAN_ROOT_NODE, ObservationAnalysisPlannerResult.class, msgs);
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PARENT:
return eInternalContainer().eInverseRemove(this, ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__CHILDREN, ObservationAnalysisPlannerNode.class, msgs);
}
return super.eBasicRemoveFromContainerFeature(msgs);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__RESULT:
if (resolve) return getResult();
return basicGetResult();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__ID:
return getId();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PASS:
if (resolve) return getPass();
return basicGetPass();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PARENT:
if (resolve) return getParent();
return basicGetParent();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__CHILDREN:
return getChildren();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__ROOT_NODE:
return isRootNode();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PLANNER_ROOT_NODE:
return getPlannerRootNode();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PLANNER_RESULT:
return getPlannerResult();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PLANNER:
return getPlanner();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__STATEFUL_COSTS_MAP_ENTRIES:
if (coreType) return getStatefulCostsMapEntries();
else return getStatefulCostsMapEntries().map();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__COST:
return getCost();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__CUMULATIVE_COST:
return getCumulativeCost();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__FIRST_LEVEL_NODE:
if (resolve) return getFirstLevelNode();
return basicGetFirstLevelNode();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__LEVEL:
return getLevel();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__SOLUTION_DURATION:
return getSolutionDuration();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PASS_DURATION:
return getPassDuration();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__TOTAL_PASSES_DURATION:
return getTotalPassesDuration();
}
return super.eGet(featureID, resolve, coreType);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__RESULT:
setResult((ObservationAnalysisPlannerResult)newValue);
return;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__ID:
setId((String)newValue);
return;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PASS:
setPass((VisibilityPass)newValue);
return;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PARENT:
setParent((ObservationAnalysisPlannerNode)newValue);
return;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__CHILDREN:
getChildren().clear();
getChildren().addAll((Collection<? extends ObservationAnalysisPlannerNode>)newValue);
return;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__STATEFUL_COSTS_MAP_ENTRIES:
((EStructuralFeature.Setting)getStatefulCostsMapEntries()).set(newValue);
return;
}
super.eSet(featureID, newValue);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__RESULT:
setResult((ObservationAnalysisPlannerResult)null);
return;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__ID:
setId(ID_EDEFAULT);
return;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PASS:
setPass((VisibilityPass)null);
return;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PARENT:
setParent((ObservationAnalysisPlannerNode)null);
return;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__CHILDREN:
getChildren().clear();
return;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__STATEFUL_COSTS_MAP_ENTRIES:
getStatefulCostsMapEntries().clear();
return;
}
super.eUnset(featureID);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__RESULT:
return basicGetResult() != null;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__ID:
return ID_EDEFAULT == null ? id != null : !ID_EDEFAULT.equals(id);
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PASS:
return pass != null;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PARENT:
return basicGetParent() != null;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__CHILDREN:
return children != null && !children.isEmpty();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__ROOT_NODE:
return isRootNode() != ROOT_NODE_EDEFAULT;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PLANNER_ROOT_NODE:
return getPlannerRootNode() != null;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PLANNER_RESULT:
return getPlannerResult() != null;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PLANNER:
return getPlanner() != null;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__STATEFUL_COSTS_MAP_ENTRIES:
return statefulCostsMapEntries != null && !statefulCostsMapEntries.isEmpty();
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__COST:
return getCost() != COST_EDEFAULT;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__CUMULATIVE_COST:
return getCumulativeCost() != CUMULATIVE_COST_EDEFAULT;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__FIRST_LEVEL_NODE:
return basicGetFirstLevelNode() != null;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__LEVEL:
return getLevel() != LEVEL_EDEFAULT;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__SOLUTION_DURATION:
return getSolutionDuration() != SOLUTION_DURATION_EDEFAULT;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__PASS_DURATION:
return getPassDuration() != PASS_DURATION_EDEFAULT;
case ApogyCoreEnvironmentEarthOrbitPlannerPackage.OBSERVATION_ANALYSIS_PLANNER_NODE__TOTAL_PASSES_DURATION:
return getTotalPassesDuration() != TOTAL_PASSES_DURATION_EDEFAULT;
}
return super.eIsSet(featureID);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public String toString() {
if (eIsProxy()) return super.toString();
StringBuilder result = new StringBuilder(super.toString());
result.append(" (id: ");
result.append(id);
result.append(')');
return result.toString();
}
} //ObservationAnalysisPlannerNodeImpl