mirror of
http://172.16.200.102/MOISE/Pattern-Instanciation-On-System-Engineering-Model.git
synced 2025-11-26 06:37:58 +01:00
Initial commit.
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Basic Property</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getBasicProperty()
|
||||
* @model interface="true" abstract="true"
|
||||
* @generated
|
||||
*/
|
||||
public interface BasicProperty extends Property {
|
||||
} // BasicProperty
|
||||
@@ -0,0 +1,62 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Boolean Property</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
* <p>
|
||||
* The following features are supported:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.BooleanProperty#isValue <em>Value</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getBooleanProperty()
|
||||
* @model
|
||||
* @generated
|
||||
*/
|
||||
public interface BooleanProperty extends BasicProperty {
|
||||
/**
|
||||
* Returns the value of the '<em><b>Value</b></em>' attribute.
|
||||
* The default value is <code>"false"</code>.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of the '<em>Value</em>' attribute isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @return the value of the '<em>Value</em>' attribute.
|
||||
* @see #setValue(boolean)
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getBooleanProperty_Value()
|
||||
* @model default="false" required="true"
|
||||
* @generated
|
||||
*/
|
||||
boolean isValue();
|
||||
|
||||
/**
|
||||
* Sets the value of the '{@link com.irtsaintexupery.pseim.seim.BooleanProperty#isValue <em>Value</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param value the new value of the '<em>Value</em>' attribute.
|
||||
* @see #isValue()
|
||||
* @generated
|
||||
*/
|
||||
void setValue(boolean value);
|
||||
|
||||
} // BooleanProperty
|
||||
@@ -0,0 +1,29 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Border Element</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getBorderElement()
|
||||
* @model interface="true" abstract="true"
|
||||
* @generated
|
||||
*/
|
||||
public interface BorderElement extends Element {
|
||||
} // BorderElement
|
||||
@@ -0,0 +1,53 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
import org.eclipse.emf.common.util.EList;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Component</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
* <p>
|
||||
* The following features are supported:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.Component#getContent <em>Content</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getComponent()
|
||||
* @model
|
||||
* @generated
|
||||
*/
|
||||
public interface Component extends GraphElement {
|
||||
/**
|
||||
* Returns the value of the '<em><b>Content</b></em>' containment reference list.
|
||||
* The list contents are of type {@link com.irtsaintexupery.pseim.seim.Element}.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of the '<em>Content</em>' containment reference list isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @return the value of the '<em>Content</em>' containment reference list.
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getComponent_Content()
|
||||
* @model containment="true"
|
||||
* @generated
|
||||
*/
|
||||
EList<Element> getContent();
|
||||
|
||||
} // Component
|
||||
@@ -0,0 +1,29 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Element</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getElement()
|
||||
* @model interface="true" abstract="true"
|
||||
* @generated
|
||||
*/
|
||||
public interface Element extends PropertyHolder {
|
||||
} // Element
|
||||
@@ -0,0 +1,29 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Graph Element</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getGraphElement()
|
||||
* @model interface="true" abstract="true"
|
||||
* @generated
|
||||
*/
|
||||
public interface GraphElement extends Element {
|
||||
} // GraphElement
|
||||
@@ -0,0 +1,65 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
import org.eclipse.emf.ecore.EObject;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Identified Element</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
* <p>
|
||||
* The following features are supported:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.IdentifiedElement#getUid <em>Uid</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getIdentifiedElement()
|
||||
* @model interface="true" abstract="true"
|
||||
* annotation="http://www.eclipse.org/emf/2002/Ecore constraints='uidNotEmpty'"
|
||||
* annotation="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot uidNotEmpty='uid <> \'\''"
|
||||
* @generated
|
||||
*/
|
||||
public interface IdentifiedElement extends EObject {
|
||||
/**
|
||||
* Returns the value of the '<em><b>Uid</b></em>' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of the '<em>Uid</em>' attribute isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @return the value of the '<em>Uid</em>' attribute.
|
||||
* @see #isSetUid()
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getIdentifiedElement_Uid()
|
||||
* @model unsettable="true" id="true" changeable="false"
|
||||
* @generated
|
||||
*/
|
||||
String getUid();
|
||||
|
||||
/**
|
||||
* Returns whether the value of the '{@link com.irtsaintexupery.pseim.seim.IdentifiedElement#getUid <em>Uid</em>}' attribute is set.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @return whether the value of the '<em>Uid</em>' attribute is set.
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
*/
|
||||
boolean isSetUid();
|
||||
|
||||
} // IdentifiedElement
|
||||
@@ -0,0 +1,62 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Integer Property</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
* <p>
|
||||
* The following features are supported:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.IntegerProperty#getValue <em>Value</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getIntegerProperty()
|
||||
* @model
|
||||
* @generated
|
||||
*/
|
||||
public interface IntegerProperty extends BasicProperty {
|
||||
/**
|
||||
* Returns the value of the '<em><b>Value</b></em>' attribute.
|
||||
* The default value is <code>"0"</code>.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of the '<em>Value</em>' attribute isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @return the value of the '<em>Value</em>' attribute.
|
||||
* @see #setValue(int)
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getIntegerProperty_Value()
|
||||
* @model default="0" required="true"
|
||||
* @generated
|
||||
*/
|
||||
int getValue();
|
||||
|
||||
/**
|
||||
* Sets the value of the '{@link com.irtsaintexupery.pseim.seim.IntegerProperty#getValue <em>Value</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param value the new value of the '<em>Value</em>' attribute.
|
||||
* @see #getValue()
|
||||
* @generated
|
||||
*/
|
||||
void setValue(int value);
|
||||
|
||||
} // IntegerProperty
|
||||
@@ -0,0 +1,88 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Link</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
* <p>
|
||||
* The following features are supported:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.Link#getSrc <em>Src</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.Link#getDst <em>Dst</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getLink()
|
||||
* @model
|
||||
* @generated
|
||||
*/
|
||||
public interface Link extends GraphElement {
|
||||
/**
|
||||
* Returns the value of the '<em><b>Src</b></em>' reference.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of the '<em>Src</em>' reference isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @return the value of the '<em>Src</em>' reference.
|
||||
* @see #setSrc(Port)
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getLink_Src()
|
||||
* @model
|
||||
* @generated
|
||||
*/
|
||||
Port getSrc();
|
||||
|
||||
/**
|
||||
* Sets the value of the '{@link com.irtsaintexupery.pseim.seim.Link#getSrc <em>Src</em>}' reference.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param value the new value of the '<em>Src</em>' reference.
|
||||
* @see #getSrc()
|
||||
* @generated
|
||||
*/
|
||||
void setSrc(Port value);
|
||||
|
||||
/**
|
||||
* Returns the value of the '<em><b>Dst</b></em>' reference.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of the '<em>Dst</em>' reference isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @return the value of the '<em>Dst</em>' reference.
|
||||
* @see #setDst(Port)
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getLink_Dst()
|
||||
* @model
|
||||
* @generated
|
||||
*/
|
||||
Port getDst();
|
||||
|
||||
/**
|
||||
* Sets the value of the '{@link com.irtsaintexupery.pseim.seim.Link#getDst <em>Dst</em>}' reference.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param value the new value of the '<em>Dst</em>' reference.
|
||||
* @see #getDst()
|
||||
* @generated
|
||||
*/
|
||||
void setDst(Port value);
|
||||
|
||||
} // Link
|
||||
@@ -0,0 +1,53 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
import org.eclipse.emf.common.util.EList;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Model</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
* <p>
|
||||
* The following features are supported:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.Model#getModelElements <em>Model Elements</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getModel()
|
||||
* @model
|
||||
* @generated
|
||||
*/
|
||||
public interface Model extends PropertyHolder {
|
||||
/**
|
||||
* Returns the value of the '<em><b>Model Elements</b></em>' containment reference list.
|
||||
* The list contents are of type {@link com.irtsaintexupery.pseim.seim.GraphElement}.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of the '<em>Model Elements</em>' containment reference list isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @return the value of the '<em>Model Elements</em>' containment reference list.
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getModel_ModelElements()
|
||||
* @model containment="true"
|
||||
* @generated
|
||||
*/
|
||||
EList<GraphElement> getModelElements();
|
||||
|
||||
} // Model
|
||||
@@ -0,0 +1,63 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Named Element</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
* <p>
|
||||
* The following features are supported:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.NamedElement#getName <em>Name</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getNamedElement()
|
||||
* @model interface="true" abstract="true"
|
||||
* annotation="http://www.eclipse.org/emf/2002/Ecore constraints='nameNotEmpty'"
|
||||
* annotation="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot nameNotEmpty='name <> \'\''"
|
||||
* @generated
|
||||
*/
|
||||
public interface NamedElement extends IdentifiedElement {
|
||||
/**
|
||||
* Returns the value of the '<em><b>Name</b></em>' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of the '<em>Name</em>' attribute isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @return the value of the '<em>Name</em>' attribute.
|
||||
* @see #setName(String)
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getNamedElement_Name()
|
||||
* @model
|
||||
* @generated
|
||||
*/
|
||||
String getName();
|
||||
|
||||
/**
|
||||
* Sets the value of the '{@link com.irtsaintexupery.pseim.seim.NamedElement#getName <em>Name</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param value the new value of the '<em>Name</em>' attribute.
|
||||
* @see #getName()
|
||||
* @generated
|
||||
*/
|
||||
void setName(String value);
|
||||
|
||||
} // NamedElement
|
||||
@@ -0,0 +1,64 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Port</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
* <p>
|
||||
* The following features are supported:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.Port#getDirection <em>Direction</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getPort()
|
||||
* @model
|
||||
* @generated
|
||||
*/
|
||||
public interface Port extends BorderElement {
|
||||
/**
|
||||
* Returns the value of the '<em><b>Direction</b></em>' attribute.
|
||||
* The literals are from the enumeration {@link com.irtsaintexupery.pseim.seim.PortDirection}.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of the '<em>Direction</em>' attribute isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @return the value of the '<em>Direction</em>' attribute.
|
||||
* @see com.irtsaintexupery.pseim.seim.PortDirection
|
||||
* @see #setDirection(PortDirection)
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getPort_Direction()
|
||||
* @model required="true"
|
||||
* @generated
|
||||
*/
|
||||
PortDirection getDirection();
|
||||
|
||||
/**
|
||||
* Sets the value of the '{@link com.irtsaintexupery.pseim.seim.Port#getDirection <em>Direction</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param value the new value of the '<em>Direction</em>' attribute.
|
||||
* @see com.irtsaintexupery.pseim.seim.PortDirection
|
||||
* @see #getDirection()
|
||||
* @generated
|
||||
*/
|
||||
void setDirection(PortDirection value);
|
||||
|
||||
} // Port
|
||||
@@ -0,0 +1,279 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
import org.eclipse.emf.common.util.Enumerator;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the literals of the enumeration '<em><b>Port Direction</b></em>',
|
||||
* and utility methods for working with them.
|
||||
* <!-- end-user-doc -->
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getPortDirection()
|
||||
* @model
|
||||
* @generated
|
||||
*/
|
||||
public enum PortDirection implements Enumerator {
|
||||
/**
|
||||
* The '<em><b>UNSPECIFIED</b></em>' literal object.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #UNSPECIFIED_VALUE
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
UNSPECIFIED(3, "UNSPECIFIED", "UNSPECIFIED"),
|
||||
|
||||
/**
|
||||
* The '<em><b>IN</b></em>' literal object.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #IN_VALUE
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
IN(0, "IN", "IN"),
|
||||
|
||||
/**
|
||||
* The '<em><b>OUT</b></em>' literal object.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #OUT_VALUE
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
OUT(1, "OUT", "OUT"),
|
||||
|
||||
/**
|
||||
* The '<em><b>INOUT</b></em>' literal object.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #INOUT_VALUE
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
INOUT(2, "INOUT", "INOUT");
|
||||
|
||||
/**
|
||||
* The '<em><b>UNSPECIFIED</b></em>' literal value.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of '<em><b>UNSPECIFIED</b></em>' literal object isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @see #UNSPECIFIED
|
||||
* @model
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
public static final int UNSPECIFIED_VALUE = 3;
|
||||
|
||||
/**
|
||||
* The '<em><b>IN</b></em>' literal value.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of '<em><b>IN</b></em>' literal object isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @see #IN
|
||||
* @model
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
public static final int IN_VALUE = 0;
|
||||
|
||||
/**
|
||||
* The '<em><b>OUT</b></em>' literal value.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of '<em><b>OUT</b></em>' literal object isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @see #OUT
|
||||
* @model
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
public static final int OUT_VALUE = 1;
|
||||
|
||||
/**
|
||||
* The '<em><b>INOUT</b></em>' literal value.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of '<em><b>INOUT</b></em>' literal object isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @see #INOUT
|
||||
* @model
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
public static final int INOUT_VALUE = 2;
|
||||
|
||||
/**
|
||||
* An array of all the '<em><b>Port Direction</b></em>' enumerators.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private static final PortDirection[] VALUES_ARRAY = new PortDirection[] { UNSPECIFIED, IN, OUT, INOUT, };
|
||||
|
||||
/**
|
||||
* A public read-only list of all the '<em><b>Port Direction</b></em>' enumerators.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public static final List<PortDirection> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY));
|
||||
|
||||
/**
|
||||
* Returns the '<em><b>Port Direction</b></em>' literal with the specified literal value.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param literal the literal.
|
||||
* @return the matching enumerator or <code>null</code>.
|
||||
* @generated
|
||||
*/
|
||||
public static PortDirection get(String literal) {
|
||||
for (int i = 0; i < VALUES_ARRAY.length; ++i) {
|
||||
PortDirection result = VALUES_ARRAY[i];
|
||||
if (result.toString().equals(literal)) {
|
||||
return result;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the '<em><b>Port Direction</b></em>' literal with the specified name.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param name the name.
|
||||
* @return the matching enumerator or <code>null</code>.
|
||||
* @generated
|
||||
*/
|
||||
public static PortDirection getByName(String name) {
|
||||
for (int i = 0; i < VALUES_ARRAY.length; ++i) {
|
||||
PortDirection result = VALUES_ARRAY[i];
|
||||
if (result.getName().equals(name)) {
|
||||
return result;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the '<em><b>Port Direction</b></em>' literal with the specified integer value.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param value the integer value.
|
||||
* @return the matching enumerator or <code>null</code>.
|
||||
* @generated
|
||||
*/
|
||||
public static PortDirection get(int value) {
|
||||
switch (value) {
|
||||
case UNSPECIFIED_VALUE:
|
||||
return UNSPECIFIED;
|
||||
case IN_VALUE:
|
||||
return IN;
|
||||
case OUT_VALUE:
|
||||
return OUT;
|
||||
case INOUT_VALUE:
|
||||
return INOUT;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private final int value;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private final String name;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private final String literal;
|
||||
|
||||
/**
|
||||
* Only this class can construct instances.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private PortDirection(int value, String name, String literal) {
|
||||
this.value = value;
|
||||
this.name = name;
|
||||
this.literal = literal;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public int getValue() {
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getLiteral() {
|
||||
return literal;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the literal value of the enumerator, which is its string representation.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return literal;
|
||||
}
|
||||
|
||||
} //PortDirection
|
||||
@@ -0,0 +1,63 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Property</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
* <p>
|
||||
* The following features are supported:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.Property#getKey <em>Key</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getProperty()
|
||||
* @model interface="true" abstract="true"
|
||||
* annotation="http://www.eclipse.org/emf/2002/Ecore constraints='keyNotNull'"
|
||||
* annotation="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot keyNotNull='key <> \'\''"
|
||||
* @generated
|
||||
*/
|
||||
public interface Property extends IdentifiedElement {
|
||||
/**
|
||||
* Returns the value of the '<em><b>Key</b></em>' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of the '<em>Key</em>' attribute isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @return the value of the '<em>Key</em>' attribute.
|
||||
* @see #setKey(String)
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getProperty_Key()
|
||||
* @model required="true"
|
||||
* @generated
|
||||
*/
|
||||
String getKey();
|
||||
|
||||
/**
|
||||
* Sets the value of the '{@link com.irtsaintexupery.pseim.seim.Property#getKey <em>Key</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param value the new value of the '<em>Key</em>' attribute.
|
||||
* @see #getKey()
|
||||
* @generated
|
||||
*/
|
||||
void setKey(String value);
|
||||
|
||||
} // Property
|
||||
@@ -0,0 +1,55 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
import org.eclipse.emf.common.util.EList;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Property Holder</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
* <p>
|
||||
* The following features are supported:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.PropertyHolder#getProperties <em>Properties</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getPropertyHolder()
|
||||
* @model interface="true" abstract="true"
|
||||
* annotation="http://www.eclipse.org/emf/2002/Ecore constraints='uniqueKeys'"
|
||||
* annotation="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot uniqueKeys='properties->forAll(p1, p2 | p1 <> p2 implies p1.key <> p2.key)'"
|
||||
* @generated
|
||||
*/
|
||||
public interface PropertyHolder extends NamedElement {
|
||||
/**
|
||||
* Returns the value of the '<em><b>Properties</b></em>' containment reference list.
|
||||
* The list contents are of type {@link com.irtsaintexupery.pseim.seim.Property}.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of the '<em>Properties</em>' containment reference list isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @return the value of the '<em>Properties</em>' containment reference list.
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getPropertyHolder_Properties()
|
||||
* @model containment="true"
|
||||
* @generated
|
||||
*/
|
||||
EList<Property> getProperties();
|
||||
|
||||
} // PropertyHolder
|
||||
@@ -0,0 +1,61 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>Reference Property</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
* <p>
|
||||
* The following features are supported:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.ReferenceProperty#getRef <em>Ref</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getReferenceProperty()
|
||||
* @model
|
||||
* @generated
|
||||
*/
|
||||
public interface ReferenceProperty extends Property {
|
||||
/**
|
||||
* Returns the value of the '<em><b>Ref</b></em>' reference.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of the '<em>Ref</em>' reference isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @return the value of the '<em>Ref</em>' reference.
|
||||
* @see #setRef(PropertyHolder)
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getReferenceProperty_Ref()
|
||||
* @model required="true"
|
||||
* @generated
|
||||
*/
|
||||
PropertyHolder getRef();
|
||||
|
||||
/**
|
||||
* Sets the value of the '{@link com.irtsaintexupery.pseim.seim.ReferenceProperty#getRef <em>Ref</em>}' reference.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param value the new value of the '<em>Ref</em>' reference.
|
||||
* @see #getRef()
|
||||
* @generated
|
||||
*/
|
||||
void setRef(PropertyHolder value);
|
||||
|
||||
} // ReferenceProperty
|
||||
@@ -0,0 +1,118 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
import org.eclipse.emf.ecore.EFactory;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* The <b>Factory</b> for the model.
|
||||
* It provides a create method for each non-abstract class of the model.
|
||||
* <!-- end-user-doc -->
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage
|
||||
* @generated
|
||||
*/
|
||||
public interface SeimFactory extends EFactory {
|
||||
/**
|
||||
* The singleton instance of the factory.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
SeimFactory eINSTANCE = com.irtsaintexupery.pseim.seim.impl.SeimFactoryImpl.init();
|
||||
|
||||
/**
|
||||
* Returns a new object of class '<em>Component</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @return a new object of class '<em>Component</em>'.
|
||||
* @generated
|
||||
*/
|
||||
Component createComponent();
|
||||
|
||||
/**
|
||||
* Returns a new object of class '<em>Port</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @return a new object of class '<em>Port</em>'.
|
||||
* @generated
|
||||
*/
|
||||
Port createPort();
|
||||
|
||||
/**
|
||||
* Returns a new object of class '<em>Link</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @return a new object of class '<em>Link</em>'.
|
||||
* @generated
|
||||
*/
|
||||
Link createLink();
|
||||
|
||||
/**
|
||||
* Returns a new object of class '<em>Integer Property</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @return a new object of class '<em>Integer Property</em>'.
|
||||
* @generated
|
||||
*/
|
||||
IntegerProperty createIntegerProperty();
|
||||
|
||||
/**
|
||||
* Returns a new object of class '<em>String Property</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @return a new object of class '<em>String Property</em>'.
|
||||
* @generated
|
||||
*/
|
||||
StringProperty createStringProperty();
|
||||
|
||||
/**
|
||||
* Returns a new object of class '<em>Boolean Property</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @return a new object of class '<em>Boolean Property</em>'.
|
||||
* @generated
|
||||
*/
|
||||
BooleanProperty createBooleanProperty();
|
||||
|
||||
/**
|
||||
* Returns a new object of class '<em>Reference Property</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @return a new object of class '<em>Reference Property</em>'.
|
||||
* @generated
|
||||
*/
|
||||
ReferenceProperty createReferenceProperty();
|
||||
|
||||
/**
|
||||
* Returns a new object of class '<em>Model</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @return a new object of class '<em>Model</em>'.
|
||||
* @generated
|
||||
*/
|
||||
Model createModel();
|
||||
|
||||
/**
|
||||
* Returns the package supported by this factory.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @return the package supported by this factory.
|
||||
* @generated
|
||||
*/
|
||||
SeimPackage getSeimPackage();
|
||||
|
||||
} //SeimFactory
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,62 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* A representation of the model object '<em><b>String Property</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
*
|
||||
* <p>
|
||||
* The following features are supported:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.StringProperty#getValue <em>Value</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getStringProperty()
|
||||
* @model
|
||||
* @generated
|
||||
*/
|
||||
public interface StringProperty extends BasicProperty {
|
||||
/**
|
||||
* Returns the value of the '<em><b>Value</b></em>' attribute.
|
||||
* The default value is <code>"\'\'"</code>.
|
||||
* <!-- begin-user-doc -->
|
||||
* <p>
|
||||
* If the meaning of the '<em>Value</em>' attribute isn't clear,
|
||||
* there really should be more of a description here...
|
||||
* </p>
|
||||
* <!-- end-user-doc -->
|
||||
* @return the value of the '<em>Value</em>' attribute.
|
||||
* @see #setValue(String)
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#getStringProperty_Value()
|
||||
* @model default="\'\'" required="true"
|
||||
* @generated
|
||||
*/
|
||||
String getValue();
|
||||
|
||||
/**
|
||||
* Sets the value of the '{@link com.irtsaintexupery.pseim.seim.StringProperty#getValue <em>Value</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param value the new value of the '<em>Value</em>' attribute.
|
||||
* @see #getValue()
|
||||
* @generated
|
||||
*/
|
||||
void setValue(String value);
|
||||
|
||||
} // StringProperty
|
||||
@@ -0,0 +1,289 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim.impl;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.BooleanProperty;
|
||||
import com.irtsaintexupery.pseim.seim.SeimPackage;
|
||||
|
||||
import org.eclipse.emf.common.notify.Notification;
|
||||
|
||||
import org.eclipse.emf.ecore.EClass;
|
||||
|
||||
import org.eclipse.emf.ecore.impl.ENotificationImpl;
|
||||
import org.eclipse.emf.ecore.impl.MinimalEObjectImpl;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* An implementation of the model object '<em><b>Boolean Property</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
* <p>
|
||||
* The following features are implemented:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.BooleanPropertyImpl#getUid <em>Uid</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.BooleanPropertyImpl#getKey <em>Key</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.BooleanPropertyImpl#isValue <em>Value</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @generated
|
||||
*/
|
||||
public class BooleanPropertyImpl extends MinimalEObjectImpl.Container implements BooleanProperty {
|
||||
/**
|
||||
* The default value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String UID_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String uid = UID_EDEFAULT;
|
||||
|
||||
/**
|
||||
* This is true if the Uid attribute has been set.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected boolean uidESet;
|
||||
|
||||
/**
|
||||
* The default value of the '{@link #getKey() <em>Key</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getKey()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String KEY_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getKey() <em>Key</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getKey()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String key = KEY_EDEFAULT;
|
||||
|
||||
/**
|
||||
* The default value of the '{@link #isValue() <em>Value</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #isValue()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final boolean VALUE_EDEFAULT = false;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #isValue() <em>Value</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #isValue()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected boolean value = VALUE_EDEFAULT;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected BooleanPropertyImpl() {
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
protected EClass eStaticClass() {
|
||||
return SeimPackage.Literals.BOOLEAN_PROPERTY;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getUid() {
|
||||
return uid;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean isSetUid() {
|
||||
return uidESet;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getKey() {
|
||||
return key;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setKey(String newKey) {
|
||||
String oldKey = key;
|
||||
key = newKey;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.BOOLEAN_PROPERTY__KEY, oldKey, key));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean isValue() {
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setValue(boolean newValue) {
|
||||
boolean oldValue = value;
|
||||
value = newValue;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.BOOLEAN_PROPERTY__VALUE, oldValue,
|
||||
value));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public Object eGet(int featureID, boolean resolve, boolean coreType) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.BOOLEAN_PROPERTY__UID:
|
||||
return getUid();
|
||||
case SeimPackage.BOOLEAN_PROPERTY__KEY:
|
||||
return getKey();
|
||||
case SeimPackage.BOOLEAN_PROPERTY__VALUE:
|
||||
return isValue();
|
||||
}
|
||||
return super.eGet(featureID, resolve, coreType);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public void eSet(int featureID, Object newValue) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.BOOLEAN_PROPERTY__KEY:
|
||||
setKey((String) newValue);
|
||||
return;
|
||||
case SeimPackage.BOOLEAN_PROPERTY__VALUE:
|
||||
setValue((Boolean) newValue);
|
||||
return;
|
||||
}
|
||||
super.eSet(featureID, newValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public void eUnset(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.BOOLEAN_PROPERTY__KEY:
|
||||
setKey(KEY_EDEFAULT);
|
||||
return;
|
||||
case SeimPackage.BOOLEAN_PROPERTY__VALUE:
|
||||
setValue(VALUE_EDEFAULT);
|
||||
return;
|
||||
}
|
||||
super.eUnset(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public boolean eIsSet(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.BOOLEAN_PROPERTY__UID:
|
||||
return isSetUid();
|
||||
case SeimPackage.BOOLEAN_PROPERTY__KEY:
|
||||
return KEY_EDEFAULT == null ? key != null : !KEY_EDEFAULT.equals(key);
|
||||
case SeimPackage.BOOLEAN_PROPERTY__VALUE:
|
||||
return value != VALUE_EDEFAULT;
|
||||
}
|
||||
return super.eIsSet(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
if (eIsProxy())
|
||||
return super.toString();
|
||||
|
||||
StringBuffer result = new StringBuffer(super.toString());
|
||||
result.append(" (uid: ");
|
||||
if (uidESet)
|
||||
result.append(uid);
|
||||
else
|
||||
result.append("<unset>");
|
||||
result.append(", key: ");
|
||||
result.append(key);
|
||||
result.append(", value: ");
|
||||
result.append(value);
|
||||
result.append(')');
|
||||
return result.toString();
|
||||
}
|
||||
|
||||
} //BooleanPropertyImpl
|
||||
@@ -0,0 +1,330 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim.impl;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.Component;
|
||||
import com.irtsaintexupery.pseim.seim.Element;
|
||||
import com.irtsaintexupery.pseim.seim.Property;
|
||||
import com.irtsaintexupery.pseim.seim.SeimPackage;
|
||||
|
||||
import java.util.Collection;
|
||||
|
||||
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.ecore.EClass;
|
||||
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.EObjectContainmentEList;
|
||||
import org.eclipse.emf.ecore.util.InternalEList;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* An implementation of the model object '<em><b>Component</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
* <p>
|
||||
* The following features are implemented:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.ComponentImpl#getUid <em>Uid</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.ComponentImpl#getName <em>Name</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.ComponentImpl#getProperties <em>Properties</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.ComponentImpl#getContent <em>Content</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @generated
|
||||
*/
|
||||
public class ComponentImpl extends MinimalEObjectImpl.Container implements Component {
|
||||
/**
|
||||
* The default value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String UID_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String uid = UID_EDEFAULT;
|
||||
|
||||
/**
|
||||
* This is true if the Uid attribute has been set.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected boolean uidESet;
|
||||
|
||||
/**
|
||||
* The default value of the '{@link #getName() <em>Name</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getName()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String NAME_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getName() <em>Name</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getName()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String name = NAME_EDEFAULT;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getProperties()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected EList<Property> properties;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getContent() <em>Content</em>}' containment reference list.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getContent()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected EList<Element> content;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected ComponentImpl() {
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
protected EClass eStaticClass() {
|
||||
return SeimPackage.Literals.COMPONENT;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getUid() {
|
||||
return uid;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean isSetUid() {
|
||||
return uidESet;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setName(String newName) {
|
||||
String oldName = name;
|
||||
name = newName;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.COMPONENT__NAME, oldName, name));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EList<Property> getProperties() {
|
||||
if (properties == null) {
|
||||
properties = new EObjectContainmentEList<Property>(Property.class, this, SeimPackage.COMPONENT__PROPERTIES);
|
||||
}
|
||||
return properties;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EList<Element> getContent() {
|
||||
if (content == null) {
|
||||
content = new EObjectContainmentEList<Element>(Element.class, this, SeimPackage.COMPONENT__CONTENT);
|
||||
}
|
||||
return content;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.COMPONENT__PROPERTIES:
|
||||
return ((InternalEList<?>) getProperties()).basicRemove(otherEnd, msgs);
|
||||
case SeimPackage.COMPONENT__CONTENT:
|
||||
return ((InternalEList<?>) getContent()).basicRemove(otherEnd, msgs);
|
||||
}
|
||||
return super.eInverseRemove(otherEnd, featureID, msgs);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public Object eGet(int featureID, boolean resolve, boolean coreType) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.COMPONENT__UID:
|
||||
return getUid();
|
||||
case SeimPackage.COMPONENT__NAME:
|
||||
return getName();
|
||||
case SeimPackage.COMPONENT__PROPERTIES:
|
||||
return getProperties();
|
||||
case SeimPackage.COMPONENT__CONTENT:
|
||||
return getContent();
|
||||
}
|
||||
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 SeimPackage.COMPONENT__NAME:
|
||||
setName((String) newValue);
|
||||
return;
|
||||
case SeimPackage.COMPONENT__PROPERTIES:
|
||||
getProperties().clear();
|
||||
getProperties().addAll((Collection<? extends Property>) newValue);
|
||||
return;
|
||||
case SeimPackage.COMPONENT__CONTENT:
|
||||
getContent().clear();
|
||||
getContent().addAll((Collection<? extends Element>) newValue);
|
||||
return;
|
||||
}
|
||||
super.eSet(featureID, newValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public void eUnset(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.COMPONENT__NAME:
|
||||
setName(NAME_EDEFAULT);
|
||||
return;
|
||||
case SeimPackage.COMPONENT__PROPERTIES:
|
||||
getProperties().clear();
|
||||
return;
|
||||
case SeimPackage.COMPONENT__CONTENT:
|
||||
getContent().clear();
|
||||
return;
|
||||
}
|
||||
super.eUnset(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public boolean eIsSet(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.COMPONENT__UID:
|
||||
return isSetUid();
|
||||
case SeimPackage.COMPONENT__NAME:
|
||||
return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name);
|
||||
case SeimPackage.COMPONENT__PROPERTIES:
|
||||
return properties != null && !properties.isEmpty();
|
||||
case SeimPackage.COMPONENT__CONTENT:
|
||||
return content != null && !content.isEmpty();
|
||||
}
|
||||
return super.eIsSet(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
if (eIsProxy())
|
||||
return super.toString();
|
||||
|
||||
StringBuffer result = new StringBuffer(super.toString());
|
||||
result.append(" (uid: ");
|
||||
if (uidESet)
|
||||
result.append(uid);
|
||||
else
|
||||
result.append("<unset>");
|
||||
result.append(", name: ");
|
||||
result.append(name);
|
||||
result.append(')');
|
||||
return result.toString();
|
||||
}
|
||||
|
||||
} //ComponentImpl
|
||||
@@ -0,0 +1,289 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim.impl;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.IntegerProperty;
|
||||
import com.irtsaintexupery.pseim.seim.SeimPackage;
|
||||
|
||||
import org.eclipse.emf.common.notify.Notification;
|
||||
|
||||
import org.eclipse.emf.ecore.EClass;
|
||||
|
||||
import org.eclipse.emf.ecore.impl.ENotificationImpl;
|
||||
import org.eclipse.emf.ecore.impl.MinimalEObjectImpl;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* An implementation of the model object '<em><b>Integer Property</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
* <p>
|
||||
* The following features are implemented:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.IntegerPropertyImpl#getUid <em>Uid</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.IntegerPropertyImpl#getKey <em>Key</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.IntegerPropertyImpl#getValue <em>Value</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @generated
|
||||
*/
|
||||
public class IntegerPropertyImpl extends MinimalEObjectImpl.Container implements IntegerProperty {
|
||||
/**
|
||||
* The default value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String UID_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String uid = UID_EDEFAULT;
|
||||
|
||||
/**
|
||||
* This is true if the Uid attribute has been set.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected boolean uidESet;
|
||||
|
||||
/**
|
||||
* The default value of the '{@link #getKey() <em>Key</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getKey()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String KEY_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getKey() <em>Key</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getKey()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String key = KEY_EDEFAULT;
|
||||
|
||||
/**
|
||||
* The default value of the '{@link #getValue() <em>Value</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getValue()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final int VALUE_EDEFAULT = 0;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getValue() <em>Value</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getValue()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected int value = VALUE_EDEFAULT;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected IntegerPropertyImpl() {
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
protected EClass eStaticClass() {
|
||||
return SeimPackage.Literals.INTEGER_PROPERTY;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getUid() {
|
||||
return uid;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean isSetUid() {
|
||||
return uidESet;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getKey() {
|
||||
return key;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setKey(String newKey) {
|
||||
String oldKey = key;
|
||||
key = newKey;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.INTEGER_PROPERTY__KEY, oldKey, key));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public int getValue() {
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setValue(int newValue) {
|
||||
int oldValue = value;
|
||||
value = newValue;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.INTEGER_PROPERTY__VALUE, oldValue,
|
||||
value));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public Object eGet(int featureID, boolean resolve, boolean coreType) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.INTEGER_PROPERTY__UID:
|
||||
return getUid();
|
||||
case SeimPackage.INTEGER_PROPERTY__KEY:
|
||||
return getKey();
|
||||
case SeimPackage.INTEGER_PROPERTY__VALUE:
|
||||
return getValue();
|
||||
}
|
||||
return super.eGet(featureID, resolve, coreType);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public void eSet(int featureID, Object newValue) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.INTEGER_PROPERTY__KEY:
|
||||
setKey((String) newValue);
|
||||
return;
|
||||
case SeimPackage.INTEGER_PROPERTY__VALUE:
|
||||
setValue((Integer) newValue);
|
||||
return;
|
||||
}
|
||||
super.eSet(featureID, newValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public void eUnset(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.INTEGER_PROPERTY__KEY:
|
||||
setKey(KEY_EDEFAULT);
|
||||
return;
|
||||
case SeimPackage.INTEGER_PROPERTY__VALUE:
|
||||
setValue(VALUE_EDEFAULT);
|
||||
return;
|
||||
}
|
||||
super.eUnset(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public boolean eIsSet(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.INTEGER_PROPERTY__UID:
|
||||
return isSetUid();
|
||||
case SeimPackage.INTEGER_PROPERTY__KEY:
|
||||
return KEY_EDEFAULT == null ? key != null : !KEY_EDEFAULT.equals(key);
|
||||
case SeimPackage.INTEGER_PROPERTY__VALUE:
|
||||
return value != VALUE_EDEFAULT;
|
||||
}
|
||||
return super.eIsSet(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
if (eIsProxy())
|
||||
return super.toString();
|
||||
|
||||
StringBuffer result = new StringBuffer(super.toString());
|
||||
result.append(" (uid: ");
|
||||
if (uidESet)
|
||||
result.append(uid);
|
||||
else
|
||||
result.append("<unset>");
|
||||
result.append(", key: ");
|
||||
result.append(key);
|
||||
result.append(", value: ");
|
||||
result.append(value);
|
||||
result.append(')');
|
||||
return result.toString();
|
||||
}
|
||||
|
||||
} //IntegerPropertyImpl
|
||||
@@ -0,0 +1,416 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim.impl;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.Link;
|
||||
import com.irtsaintexupery.pseim.seim.Port;
|
||||
import com.irtsaintexupery.pseim.seim.Property;
|
||||
import com.irtsaintexupery.pseim.seim.SeimPackage;
|
||||
|
||||
import java.util.Collection;
|
||||
|
||||
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.ecore.EClass;
|
||||
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.EObjectContainmentEList;
|
||||
import org.eclipse.emf.ecore.util.InternalEList;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* An implementation of the model object '<em><b>Link</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
* <p>
|
||||
* The following features are implemented:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.LinkImpl#getUid <em>Uid</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.LinkImpl#getName <em>Name</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.LinkImpl#getProperties <em>Properties</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.LinkImpl#getSrc <em>Src</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.LinkImpl#getDst <em>Dst</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @generated
|
||||
*/
|
||||
public class LinkImpl extends MinimalEObjectImpl.Container implements Link {
|
||||
/**
|
||||
* The default value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String UID_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String uid = UID_EDEFAULT;
|
||||
|
||||
/**
|
||||
* This is true if the Uid attribute has been set.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected boolean uidESet;
|
||||
|
||||
/**
|
||||
* The default value of the '{@link #getName() <em>Name</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getName()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String NAME_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getName() <em>Name</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getName()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String name = NAME_EDEFAULT;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getProperties()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected EList<Property> properties;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getSrc() <em>Src</em>}' reference.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getSrc()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected Port src;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getDst() <em>Dst</em>}' reference.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getDst()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected Port dst;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected LinkImpl() {
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
protected EClass eStaticClass() {
|
||||
return SeimPackage.Literals.LINK;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getUid() {
|
||||
return uid;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean isSetUid() {
|
||||
return uidESet;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setName(String newName) {
|
||||
String oldName = name;
|
||||
name = newName;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.LINK__NAME, oldName, name));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EList<Property> getProperties() {
|
||||
if (properties == null) {
|
||||
properties = new EObjectContainmentEList<Property>(Property.class, this, SeimPackage.LINK__PROPERTIES);
|
||||
}
|
||||
return properties;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public Port getSrc() {
|
||||
if (src != null && src.eIsProxy()) {
|
||||
InternalEObject oldSrc = (InternalEObject) src;
|
||||
src = (Port) eResolveProxy(oldSrc);
|
||||
if (src != oldSrc) {
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.RESOLVE, SeimPackage.LINK__SRC, oldSrc, src));
|
||||
}
|
||||
}
|
||||
return src;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public Port basicGetSrc() {
|
||||
return src;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setSrc(Port newSrc) {
|
||||
Port oldSrc = src;
|
||||
src = newSrc;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.LINK__SRC, oldSrc, src));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public Port getDst() {
|
||||
if (dst != null && dst.eIsProxy()) {
|
||||
InternalEObject oldDst = (InternalEObject) dst;
|
||||
dst = (Port) eResolveProxy(oldDst);
|
||||
if (dst != oldDst) {
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.RESOLVE, SeimPackage.LINK__DST, oldDst, dst));
|
||||
}
|
||||
}
|
||||
return dst;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public Port basicGetDst() {
|
||||
return dst;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setDst(Port newDst) {
|
||||
Port oldDst = dst;
|
||||
dst = newDst;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.LINK__DST, oldDst, dst));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.LINK__PROPERTIES:
|
||||
return ((InternalEList<?>) getProperties()).basicRemove(otherEnd, msgs);
|
||||
}
|
||||
return super.eInverseRemove(otherEnd, featureID, msgs);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public Object eGet(int featureID, boolean resolve, boolean coreType) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.LINK__UID:
|
||||
return getUid();
|
||||
case SeimPackage.LINK__NAME:
|
||||
return getName();
|
||||
case SeimPackage.LINK__PROPERTIES:
|
||||
return getProperties();
|
||||
case SeimPackage.LINK__SRC:
|
||||
if (resolve)
|
||||
return getSrc();
|
||||
return basicGetSrc();
|
||||
case SeimPackage.LINK__DST:
|
||||
if (resolve)
|
||||
return getDst();
|
||||
return basicGetDst();
|
||||
}
|
||||
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 SeimPackage.LINK__NAME:
|
||||
setName((String) newValue);
|
||||
return;
|
||||
case SeimPackage.LINK__PROPERTIES:
|
||||
getProperties().clear();
|
||||
getProperties().addAll((Collection<? extends Property>) newValue);
|
||||
return;
|
||||
case SeimPackage.LINK__SRC:
|
||||
setSrc((Port) newValue);
|
||||
return;
|
||||
case SeimPackage.LINK__DST:
|
||||
setDst((Port) newValue);
|
||||
return;
|
||||
}
|
||||
super.eSet(featureID, newValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public void eUnset(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.LINK__NAME:
|
||||
setName(NAME_EDEFAULT);
|
||||
return;
|
||||
case SeimPackage.LINK__PROPERTIES:
|
||||
getProperties().clear();
|
||||
return;
|
||||
case SeimPackage.LINK__SRC:
|
||||
setSrc((Port) null);
|
||||
return;
|
||||
case SeimPackage.LINK__DST:
|
||||
setDst((Port) null);
|
||||
return;
|
||||
}
|
||||
super.eUnset(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public boolean eIsSet(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.LINK__UID:
|
||||
return isSetUid();
|
||||
case SeimPackage.LINK__NAME:
|
||||
return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name);
|
||||
case SeimPackage.LINK__PROPERTIES:
|
||||
return properties != null && !properties.isEmpty();
|
||||
case SeimPackage.LINK__SRC:
|
||||
return src != null;
|
||||
case SeimPackage.LINK__DST:
|
||||
return dst != null;
|
||||
}
|
||||
return super.eIsSet(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
if (eIsProxy())
|
||||
return super.toString();
|
||||
|
||||
StringBuffer result = new StringBuffer(super.toString());
|
||||
result.append(" (uid: ");
|
||||
if (uidESet)
|
||||
result.append(uid);
|
||||
else
|
||||
result.append("<unset>");
|
||||
result.append(", name: ");
|
||||
result.append(name);
|
||||
result.append(')');
|
||||
return result.toString();
|
||||
}
|
||||
|
||||
} //LinkImpl
|
||||
@@ -0,0 +1,331 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim.impl;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.GraphElement;
|
||||
import com.irtsaintexupery.pseim.seim.Model;
|
||||
import com.irtsaintexupery.pseim.seim.Property;
|
||||
import com.irtsaintexupery.pseim.seim.SeimPackage;
|
||||
|
||||
import java.util.Collection;
|
||||
|
||||
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.ecore.EClass;
|
||||
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.EObjectContainmentEList;
|
||||
import org.eclipse.emf.ecore.util.InternalEList;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* An implementation of the model object '<em><b>Model</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
* <p>
|
||||
* The following features are implemented:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.ModelImpl#getUid <em>Uid</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.ModelImpl#getName <em>Name</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.ModelImpl#getProperties <em>Properties</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.ModelImpl#getModelElements <em>Model Elements</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @generated
|
||||
*/
|
||||
public class ModelImpl extends MinimalEObjectImpl.Container implements Model {
|
||||
/**
|
||||
* The default value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String UID_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String uid = UID_EDEFAULT;
|
||||
|
||||
/**
|
||||
* This is true if the Uid attribute has been set.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected boolean uidESet;
|
||||
|
||||
/**
|
||||
* The default value of the '{@link #getName() <em>Name</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getName()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String NAME_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getName() <em>Name</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getName()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String name = NAME_EDEFAULT;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getProperties()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected EList<Property> properties;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getModelElements() <em>Model Elements</em>}' containment reference list.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getModelElements()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected EList<GraphElement> modelElements;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected ModelImpl() {
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
protected EClass eStaticClass() {
|
||||
return SeimPackage.Literals.MODEL;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getUid() {
|
||||
return uid;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean isSetUid() {
|
||||
return uidESet;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setName(String newName) {
|
||||
String oldName = name;
|
||||
name = newName;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.MODEL__NAME, oldName, name));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EList<Property> getProperties() {
|
||||
if (properties == null) {
|
||||
properties = new EObjectContainmentEList<Property>(Property.class, this, SeimPackage.MODEL__PROPERTIES);
|
||||
}
|
||||
return properties;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EList<GraphElement> getModelElements() {
|
||||
if (modelElements == null) {
|
||||
modelElements = new EObjectContainmentEList<GraphElement>(GraphElement.class, this,
|
||||
SeimPackage.MODEL__MODEL_ELEMENTS);
|
||||
}
|
||||
return modelElements;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.MODEL__PROPERTIES:
|
||||
return ((InternalEList<?>) getProperties()).basicRemove(otherEnd, msgs);
|
||||
case SeimPackage.MODEL__MODEL_ELEMENTS:
|
||||
return ((InternalEList<?>) getModelElements()).basicRemove(otherEnd, msgs);
|
||||
}
|
||||
return super.eInverseRemove(otherEnd, featureID, msgs);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public Object eGet(int featureID, boolean resolve, boolean coreType) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.MODEL__UID:
|
||||
return getUid();
|
||||
case SeimPackage.MODEL__NAME:
|
||||
return getName();
|
||||
case SeimPackage.MODEL__PROPERTIES:
|
||||
return getProperties();
|
||||
case SeimPackage.MODEL__MODEL_ELEMENTS:
|
||||
return getModelElements();
|
||||
}
|
||||
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 SeimPackage.MODEL__NAME:
|
||||
setName((String) newValue);
|
||||
return;
|
||||
case SeimPackage.MODEL__PROPERTIES:
|
||||
getProperties().clear();
|
||||
getProperties().addAll((Collection<? extends Property>) newValue);
|
||||
return;
|
||||
case SeimPackage.MODEL__MODEL_ELEMENTS:
|
||||
getModelElements().clear();
|
||||
getModelElements().addAll((Collection<? extends GraphElement>) newValue);
|
||||
return;
|
||||
}
|
||||
super.eSet(featureID, newValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public void eUnset(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.MODEL__NAME:
|
||||
setName(NAME_EDEFAULT);
|
||||
return;
|
||||
case SeimPackage.MODEL__PROPERTIES:
|
||||
getProperties().clear();
|
||||
return;
|
||||
case SeimPackage.MODEL__MODEL_ELEMENTS:
|
||||
getModelElements().clear();
|
||||
return;
|
||||
}
|
||||
super.eUnset(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public boolean eIsSet(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.MODEL__UID:
|
||||
return isSetUid();
|
||||
case SeimPackage.MODEL__NAME:
|
||||
return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name);
|
||||
case SeimPackage.MODEL__PROPERTIES:
|
||||
return properties != null && !properties.isEmpty();
|
||||
case SeimPackage.MODEL__MODEL_ELEMENTS:
|
||||
return modelElements != null && !modelElements.isEmpty();
|
||||
}
|
||||
return super.eIsSet(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
if (eIsProxy())
|
||||
return super.toString();
|
||||
|
||||
StringBuffer result = new StringBuffer(super.toString());
|
||||
result.append(" (uid: ");
|
||||
if (uidESet)
|
||||
result.append(uid);
|
||||
else
|
||||
result.append("<unset>");
|
||||
result.append(", name: ");
|
||||
result.append(name);
|
||||
result.append(')');
|
||||
return result.toString();
|
||||
}
|
||||
|
||||
} //ModelImpl
|
||||
@@ -0,0 +1,349 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim.impl;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.Port;
|
||||
import com.irtsaintexupery.pseim.seim.PortDirection;
|
||||
import com.irtsaintexupery.pseim.seim.Property;
|
||||
import com.irtsaintexupery.pseim.seim.SeimPackage;
|
||||
|
||||
import java.util.Collection;
|
||||
|
||||
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.ecore.EClass;
|
||||
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.EObjectContainmentEList;
|
||||
import org.eclipse.emf.ecore.util.InternalEList;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* An implementation of the model object '<em><b>Port</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
* <p>
|
||||
* The following features are implemented:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.PortImpl#getUid <em>Uid</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.PortImpl#getName <em>Name</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.PortImpl#getProperties <em>Properties</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.PortImpl#getDirection <em>Direction</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @generated
|
||||
*/
|
||||
public class PortImpl extends MinimalEObjectImpl.Container implements Port {
|
||||
/**
|
||||
* The default value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String UID_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String uid = UID_EDEFAULT;
|
||||
|
||||
/**
|
||||
* This is true if the Uid attribute has been set.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected boolean uidESet;
|
||||
|
||||
/**
|
||||
* The default value of the '{@link #getName() <em>Name</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getName()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String NAME_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getName() <em>Name</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getName()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String name = NAME_EDEFAULT;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getProperties()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected EList<Property> properties;
|
||||
|
||||
/**
|
||||
* The default value of the '{@link #getDirection() <em>Direction</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getDirection()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final PortDirection DIRECTION_EDEFAULT = PortDirection.UNSPECIFIED;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getDirection() <em>Direction</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getDirection()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected PortDirection direction = DIRECTION_EDEFAULT;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected PortImpl() {
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
protected EClass eStaticClass() {
|
||||
return SeimPackage.Literals.PORT;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getUid() {
|
||||
return uid;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean isSetUid() {
|
||||
return uidESet;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setName(String newName) {
|
||||
String oldName = name;
|
||||
name = newName;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.PORT__NAME, oldName, name));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EList<Property> getProperties() {
|
||||
if (properties == null) {
|
||||
properties = new EObjectContainmentEList<Property>(Property.class, this, SeimPackage.PORT__PROPERTIES);
|
||||
}
|
||||
return properties;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public PortDirection getDirection() {
|
||||
return direction;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setDirection(PortDirection newDirection) {
|
||||
PortDirection oldDirection = direction;
|
||||
direction = newDirection == null ? DIRECTION_EDEFAULT : newDirection;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.PORT__DIRECTION, oldDirection,
|
||||
direction));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.PORT__PROPERTIES:
|
||||
return ((InternalEList<?>) getProperties()).basicRemove(otherEnd, msgs);
|
||||
}
|
||||
return super.eInverseRemove(otherEnd, featureID, msgs);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public Object eGet(int featureID, boolean resolve, boolean coreType) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.PORT__UID:
|
||||
return getUid();
|
||||
case SeimPackage.PORT__NAME:
|
||||
return getName();
|
||||
case SeimPackage.PORT__PROPERTIES:
|
||||
return getProperties();
|
||||
case SeimPackage.PORT__DIRECTION:
|
||||
return getDirection();
|
||||
}
|
||||
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 SeimPackage.PORT__NAME:
|
||||
setName((String) newValue);
|
||||
return;
|
||||
case SeimPackage.PORT__PROPERTIES:
|
||||
getProperties().clear();
|
||||
getProperties().addAll((Collection<? extends Property>) newValue);
|
||||
return;
|
||||
case SeimPackage.PORT__DIRECTION:
|
||||
setDirection((PortDirection) newValue);
|
||||
return;
|
||||
}
|
||||
super.eSet(featureID, newValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public void eUnset(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.PORT__NAME:
|
||||
setName(NAME_EDEFAULT);
|
||||
return;
|
||||
case SeimPackage.PORT__PROPERTIES:
|
||||
getProperties().clear();
|
||||
return;
|
||||
case SeimPackage.PORT__DIRECTION:
|
||||
setDirection(DIRECTION_EDEFAULT);
|
||||
return;
|
||||
}
|
||||
super.eUnset(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public boolean eIsSet(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.PORT__UID:
|
||||
return isSetUid();
|
||||
case SeimPackage.PORT__NAME:
|
||||
return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name);
|
||||
case SeimPackage.PORT__PROPERTIES:
|
||||
return properties != null && !properties.isEmpty();
|
||||
case SeimPackage.PORT__DIRECTION:
|
||||
return direction != DIRECTION_EDEFAULT;
|
||||
}
|
||||
return super.eIsSet(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
if (eIsProxy())
|
||||
return super.toString();
|
||||
|
||||
StringBuffer result = new StringBuffer(super.toString());
|
||||
result.append(" (uid: ");
|
||||
if (uidESet)
|
||||
result.append(uid);
|
||||
else
|
||||
result.append("<unset>");
|
||||
result.append(", name: ");
|
||||
result.append(name);
|
||||
result.append(", direction: ");
|
||||
result.append(direction);
|
||||
result.append(')');
|
||||
return result.toString();
|
||||
}
|
||||
|
||||
} //PortImpl
|
||||
@@ -0,0 +1,298 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim.impl;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.PropertyHolder;
|
||||
import com.irtsaintexupery.pseim.seim.ReferenceProperty;
|
||||
import com.irtsaintexupery.pseim.seim.SeimPackage;
|
||||
|
||||
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.emf.ecore.impl.MinimalEObjectImpl;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* An implementation of the model object '<em><b>Reference Property</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
* <p>
|
||||
* The following features are implemented:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.ReferencePropertyImpl#getUid <em>Uid</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.ReferencePropertyImpl#getKey <em>Key</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.ReferencePropertyImpl#getRef <em>Ref</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @generated
|
||||
*/
|
||||
public class ReferencePropertyImpl extends MinimalEObjectImpl.Container implements ReferenceProperty {
|
||||
/**
|
||||
* The default value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String UID_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String uid = UID_EDEFAULT;
|
||||
|
||||
/**
|
||||
* This is true if the Uid attribute has been set.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected boolean uidESet;
|
||||
|
||||
/**
|
||||
* The default value of the '{@link #getKey() <em>Key</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getKey()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String KEY_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getKey() <em>Key</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getKey()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String key = KEY_EDEFAULT;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getRef() <em>Ref</em>}' reference.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getRef()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected PropertyHolder ref;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected ReferencePropertyImpl() {
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
protected EClass eStaticClass() {
|
||||
return SeimPackage.Literals.REFERENCE_PROPERTY;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getUid() {
|
||||
return uid;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean isSetUid() {
|
||||
return uidESet;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getKey() {
|
||||
return key;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setKey(String newKey) {
|
||||
String oldKey = key;
|
||||
key = newKey;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.REFERENCE_PROPERTY__KEY, oldKey, key));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public PropertyHolder getRef() {
|
||||
if (ref != null && ref.eIsProxy()) {
|
||||
InternalEObject oldRef = (InternalEObject) ref;
|
||||
ref = (PropertyHolder) eResolveProxy(oldRef);
|
||||
if (ref != oldRef) {
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.RESOLVE, SeimPackage.REFERENCE_PROPERTY__REF,
|
||||
oldRef, ref));
|
||||
}
|
||||
}
|
||||
return ref;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public PropertyHolder basicGetRef() {
|
||||
return ref;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setRef(PropertyHolder newRef) {
|
||||
PropertyHolder oldRef = ref;
|
||||
ref = newRef;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.REFERENCE_PROPERTY__REF, oldRef, ref));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public Object eGet(int featureID, boolean resolve, boolean coreType) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.REFERENCE_PROPERTY__UID:
|
||||
return getUid();
|
||||
case SeimPackage.REFERENCE_PROPERTY__KEY:
|
||||
return getKey();
|
||||
case SeimPackage.REFERENCE_PROPERTY__REF:
|
||||
if (resolve)
|
||||
return getRef();
|
||||
return basicGetRef();
|
||||
}
|
||||
return super.eGet(featureID, resolve, coreType);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public void eSet(int featureID, Object newValue) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.REFERENCE_PROPERTY__KEY:
|
||||
setKey((String) newValue);
|
||||
return;
|
||||
case SeimPackage.REFERENCE_PROPERTY__REF:
|
||||
setRef((PropertyHolder) newValue);
|
||||
return;
|
||||
}
|
||||
super.eSet(featureID, newValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public void eUnset(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.REFERENCE_PROPERTY__KEY:
|
||||
setKey(KEY_EDEFAULT);
|
||||
return;
|
||||
case SeimPackage.REFERENCE_PROPERTY__REF:
|
||||
setRef((PropertyHolder) null);
|
||||
return;
|
||||
}
|
||||
super.eUnset(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public boolean eIsSet(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.REFERENCE_PROPERTY__UID:
|
||||
return isSetUid();
|
||||
case SeimPackage.REFERENCE_PROPERTY__KEY:
|
||||
return KEY_EDEFAULT == null ? key != null : !KEY_EDEFAULT.equals(key);
|
||||
case SeimPackage.REFERENCE_PROPERTY__REF:
|
||||
return ref != null;
|
||||
}
|
||||
return super.eIsSet(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
if (eIsProxy())
|
||||
return super.toString();
|
||||
|
||||
StringBuffer result = new StringBuffer(super.toString());
|
||||
result.append(" (uid: ");
|
||||
if (uidESet)
|
||||
result.append(uid);
|
||||
else
|
||||
result.append("<unset>");
|
||||
result.append(", key: ");
|
||||
result.append(key);
|
||||
result.append(')');
|
||||
return result.toString();
|
||||
}
|
||||
|
||||
} //ReferencePropertyImpl
|
||||
@@ -0,0 +1,254 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim.impl;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.*;
|
||||
|
||||
import org.eclipse.emf.ecore.EClass;
|
||||
import org.eclipse.emf.ecore.EDataType;
|
||||
import org.eclipse.emf.ecore.EObject;
|
||||
import org.eclipse.emf.ecore.EPackage;
|
||||
|
||||
import org.eclipse.emf.ecore.impl.EFactoryImpl;
|
||||
|
||||
import org.eclipse.emf.ecore.plugin.EcorePlugin;
|
||||
import org.eclipse.emf.ecore.util.EcoreUtil;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* An implementation of the model <b>Factory</b>.
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public class SeimFactoryImpl extends EFactoryImpl implements SeimFactory {
|
||||
/**
|
||||
* Creates the default factory implementation.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public static SeimFactory init() {
|
||||
try {
|
||||
SeimFactory theSeimFactory = (SeimFactory) EPackage.Registry.INSTANCE.getEFactory(SeimPackage.eNS_URI);
|
||||
if (theSeimFactory != null) {
|
||||
return theSeimFactory;
|
||||
}
|
||||
} catch (Exception exception) {
|
||||
EcorePlugin.INSTANCE.log(exception);
|
||||
}
|
||||
return new SeimFactoryImpl();
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates an instance of the factory.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public SeimFactoryImpl() {
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public EObject create(EClass eClass) {
|
||||
switch (eClass.getClassifierID()) {
|
||||
case SeimPackage.COMPONENT:
|
||||
return createComponent();
|
||||
case SeimPackage.PORT:
|
||||
return createPort();
|
||||
case SeimPackage.LINK:
|
||||
return createLink();
|
||||
case SeimPackage.INTEGER_PROPERTY:
|
||||
return createIntegerProperty();
|
||||
case SeimPackage.STRING_PROPERTY:
|
||||
return createStringProperty();
|
||||
case SeimPackage.BOOLEAN_PROPERTY:
|
||||
return createBooleanProperty();
|
||||
case SeimPackage.REFERENCE_PROPERTY:
|
||||
return createReferenceProperty();
|
||||
case SeimPackage.MODEL:
|
||||
return createModel();
|
||||
default:
|
||||
throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public Object createFromString(EDataType eDataType, String initialValue) {
|
||||
switch (eDataType.getClassifierID()) {
|
||||
case SeimPackage.PORT_DIRECTION:
|
||||
return createPortDirectionFromString(eDataType, initialValue);
|
||||
default:
|
||||
throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public String convertToString(EDataType eDataType, Object instanceValue) {
|
||||
switch (eDataType.getClassifierID()) {
|
||||
case SeimPackage.PORT_DIRECTION:
|
||||
return convertPortDirectionToString(eDataType, instanceValue);
|
||||
default:
|
||||
throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated NOT
|
||||
*/
|
||||
public Component createComponent() {
|
||||
ComponentImpl component = new ComponentImpl();
|
||||
component.uid = EcoreUtil.generateUUID();
|
||||
return component;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated NOT
|
||||
*/
|
||||
public Port createPort() {
|
||||
PortImpl port = new PortImpl();
|
||||
port.uid = EcoreUtil.generateUUID();
|
||||
return port;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated NOT
|
||||
*/
|
||||
public Link createLink() {
|
||||
LinkImpl link = new LinkImpl();
|
||||
link.uid = EcoreUtil.generateUUID();
|
||||
return link;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated NOT
|
||||
*/
|
||||
public IntegerProperty createIntegerProperty() {
|
||||
IntegerPropertyImpl integerProperty = new IntegerPropertyImpl();
|
||||
integerProperty.uid = EcoreUtil.generateUUID();
|
||||
return integerProperty;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated NOT
|
||||
*/
|
||||
public StringProperty createStringProperty() {
|
||||
StringPropertyImpl stringProperty = new StringPropertyImpl();
|
||||
stringProperty.uid = EcoreUtil.generateUUID();
|
||||
return stringProperty;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated NOT
|
||||
*/
|
||||
public BooleanProperty createBooleanProperty() {
|
||||
BooleanPropertyImpl booleanProperty = new BooleanPropertyImpl();
|
||||
booleanProperty.uid = EcoreUtil.generateUUID();
|
||||
return booleanProperty;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated NOT
|
||||
*/
|
||||
public ReferenceProperty createReferenceProperty() {
|
||||
ReferencePropertyImpl referenceProperty = new ReferencePropertyImpl();
|
||||
referenceProperty.uid = EcoreUtil.generateUUID();
|
||||
return referenceProperty;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated NOT
|
||||
*/
|
||||
public Model createModel() {
|
||||
ModelImpl model = new ModelImpl();
|
||||
model.uid = EcoreUtil.generateUUID();
|
||||
return model;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public PortDirection createPortDirectionFromString(EDataType eDataType, String initialValue) {
|
||||
PortDirection result = PortDirection.get(initialValue);
|
||||
if (result == null)
|
||||
throw new IllegalArgumentException(
|
||||
"The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'");
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String convertPortDirectionToString(EDataType eDataType, Object instanceValue) {
|
||||
return instanceValue == null ? null : instanceValue.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public SeimPackage getSeimPackage() {
|
||||
return (SeimPackage) getEPackage();
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @deprecated
|
||||
* @generated
|
||||
*/
|
||||
@Deprecated
|
||||
public static SeimPackage getPackage() {
|
||||
return SeimPackage.eINSTANCE;
|
||||
}
|
||||
|
||||
} //SeimFactoryImpl
|
||||
@@ -0,0 +1,778 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim.impl;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.BasicProperty;
|
||||
import com.irtsaintexupery.pseim.seim.BooleanProperty;
|
||||
import com.irtsaintexupery.pseim.seim.BorderElement;
|
||||
import com.irtsaintexupery.pseim.seim.Component;
|
||||
import com.irtsaintexupery.pseim.seim.Element;
|
||||
import com.irtsaintexupery.pseim.seim.GraphElement;
|
||||
import com.irtsaintexupery.pseim.seim.IdentifiedElement;
|
||||
import com.irtsaintexupery.pseim.seim.IntegerProperty;
|
||||
import com.irtsaintexupery.pseim.seim.Link;
|
||||
import com.irtsaintexupery.pseim.seim.Model;
|
||||
import com.irtsaintexupery.pseim.seim.NamedElement;
|
||||
import com.irtsaintexupery.pseim.seim.Port;
|
||||
import com.irtsaintexupery.pseim.seim.PortDirection;
|
||||
import com.irtsaintexupery.pseim.seim.Property;
|
||||
import com.irtsaintexupery.pseim.seim.PropertyHolder;
|
||||
import com.irtsaintexupery.pseim.seim.ReferenceProperty;
|
||||
import com.irtsaintexupery.pseim.seim.SeimFactory;
|
||||
import com.irtsaintexupery.pseim.seim.SeimPackage;
|
||||
import com.irtsaintexupery.pseim.seim.StringProperty;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.util.SeimValidator;
|
||||
|
||||
import org.eclipse.emf.ecore.EAttribute;
|
||||
import org.eclipse.emf.ecore.EClass;
|
||||
import org.eclipse.emf.ecore.EEnum;
|
||||
import org.eclipse.emf.ecore.EPackage;
|
||||
import org.eclipse.emf.ecore.EReference;
|
||||
import org.eclipse.emf.ecore.EValidator;
|
||||
|
||||
import org.eclipse.emf.ecore.impl.EPackageImpl;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* An implementation of the model <b>Package</b>.
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public class SeimPackageImpl extends EPackageImpl implements SeimPackage {
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass componentEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass portEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass linkEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass graphElementEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass propertyEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass basicPropertyEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass integerPropertyEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass stringPropertyEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass booleanPropertyEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass referencePropertyEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass propertyHolderEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass namedElementEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass identifiedElementEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass modelEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass borderElementEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EClass elementEClass = null;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private EEnum portDirectionEEnum = null;
|
||||
|
||||
/**
|
||||
* Creates an instance of the model <b>Package</b>, registered with
|
||||
* {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package
|
||||
* package URI value.
|
||||
* <p>Note: the correct way to create the package is via the static
|
||||
* factory method {@link #init init()}, which also performs
|
||||
* initialization of the package, or returns the registered package,
|
||||
* if one already exists.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see org.eclipse.emf.ecore.EPackage.Registry
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage#eNS_URI
|
||||
* @see #init()
|
||||
* @generated
|
||||
*/
|
||||
private SeimPackageImpl() {
|
||||
super(eNS_URI, SeimFactory.eINSTANCE);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private static boolean isInited = false;
|
||||
|
||||
/**
|
||||
* Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends.
|
||||
*
|
||||
* <p>This method is used to initialize {@link SeimPackage#eINSTANCE} when that field is accessed.
|
||||
* Clients should not invoke it directly. Instead, they should simply access that field to obtain the package.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #eNS_URI
|
||||
* @see #createPackageContents()
|
||||
* @see #initializePackageContents()
|
||||
* @generated
|
||||
*/
|
||||
public static SeimPackage init() {
|
||||
if (isInited)
|
||||
return (SeimPackage) EPackage.Registry.INSTANCE.getEPackage(SeimPackage.eNS_URI);
|
||||
|
||||
// Obtain or create and register package
|
||||
SeimPackageImpl theSeimPackage = (SeimPackageImpl) (EPackage.Registry.INSTANCE
|
||||
.get(eNS_URI) instanceof SeimPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI)
|
||||
: new SeimPackageImpl());
|
||||
|
||||
isInited = true;
|
||||
|
||||
// Create package meta-data objects
|
||||
theSeimPackage.createPackageContents();
|
||||
|
||||
// Initialize created meta-data
|
||||
theSeimPackage.initializePackageContents();
|
||||
|
||||
// Register package validator
|
||||
EValidator.Registry.INSTANCE.put(theSeimPackage, new EValidator.Descriptor() {
|
||||
public EValidator getEValidator() {
|
||||
return SeimValidator.INSTANCE;
|
||||
}
|
||||
});
|
||||
|
||||
// Mark meta-data to indicate it can't be changed
|
||||
theSeimPackage.freeze();
|
||||
|
||||
// Update the registry and return the package
|
||||
EPackage.Registry.INSTANCE.put(SeimPackage.eNS_URI, theSeimPackage);
|
||||
return theSeimPackage;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getComponent() {
|
||||
return componentEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EReference getComponent_Content() {
|
||||
return (EReference) componentEClass.getEStructuralFeatures().get(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getPort() {
|
||||
return portEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EAttribute getPort_Direction() {
|
||||
return (EAttribute) portEClass.getEStructuralFeatures().get(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getLink() {
|
||||
return linkEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EReference getLink_Src() {
|
||||
return (EReference) linkEClass.getEStructuralFeatures().get(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EReference getLink_Dst() {
|
||||
return (EReference) linkEClass.getEStructuralFeatures().get(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getGraphElement() {
|
||||
return graphElementEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getProperty() {
|
||||
return propertyEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EAttribute getProperty_Key() {
|
||||
return (EAttribute) propertyEClass.getEStructuralFeatures().get(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getBasicProperty() {
|
||||
return basicPropertyEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getIntegerProperty() {
|
||||
return integerPropertyEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EAttribute getIntegerProperty_Value() {
|
||||
return (EAttribute) integerPropertyEClass.getEStructuralFeatures().get(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getStringProperty() {
|
||||
return stringPropertyEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EAttribute getStringProperty_Value() {
|
||||
return (EAttribute) stringPropertyEClass.getEStructuralFeatures().get(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getBooleanProperty() {
|
||||
return booleanPropertyEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EAttribute getBooleanProperty_Value() {
|
||||
return (EAttribute) booleanPropertyEClass.getEStructuralFeatures().get(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getReferenceProperty() {
|
||||
return referencePropertyEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EReference getReferenceProperty_Ref() {
|
||||
return (EReference) referencePropertyEClass.getEStructuralFeatures().get(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getPropertyHolder() {
|
||||
return propertyHolderEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EReference getPropertyHolder_Properties() {
|
||||
return (EReference) propertyHolderEClass.getEStructuralFeatures().get(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getNamedElement() {
|
||||
return namedElementEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EAttribute getNamedElement_Name() {
|
||||
return (EAttribute) namedElementEClass.getEStructuralFeatures().get(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getIdentifiedElement() {
|
||||
return identifiedElementEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EAttribute getIdentifiedElement_Uid() {
|
||||
return (EAttribute) identifiedElementEClass.getEStructuralFeatures().get(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getModel() {
|
||||
return modelEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EReference getModel_ModelElements() {
|
||||
return (EReference) modelEClass.getEStructuralFeatures().get(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getBorderElement() {
|
||||
return borderElementEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EClass getElement() {
|
||||
return elementEClass;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public EEnum getPortDirection() {
|
||||
return portDirectionEEnum;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public SeimFactory getSeimFactory() {
|
||||
return (SeimFactory) getEFactoryInstance();
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private boolean isCreated = false;
|
||||
|
||||
/**
|
||||
* Creates the meta-model objects for the package. This method is
|
||||
* guarded to have no affect on any invocation but its first.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void createPackageContents() {
|
||||
if (isCreated)
|
||||
return;
|
||||
isCreated = true;
|
||||
|
||||
// Create classes and their features
|
||||
componentEClass = createEClass(COMPONENT);
|
||||
createEReference(componentEClass, COMPONENT__CONTENT);
|
||||
|
||||
portEClass = createEClass(PORT);
|
||||
createEAttribute(portEClass, PORT__DIRECTION);
|
||||
|
||||
linkEClass = createEClass(LINK);
|
||||
createEReference(linkEClass, LINK__SRC);
|
||||
createEReference(linkEClass, LINK__DST);
|
||||
|
||||
graphElementEClass = createEClass(GRAPH_ELEMENT);
|
||||
|
||||
propertyEClass = createEClass(PROPERTY);
|
||||
createEAttribute(propertyEClass, PROPERTY__KEY);
|
||||
|
||||
basicPropertyEClass = createEClass(BASIC_PROPERTY);
|
||||
|
||||
integerPropertyEClass = createEClass(INTEGER_PROPERTY);
|
||||
createEAttribute(integerPropertyEClass, INTEGER_PROPERTY__VALUE);
|
||||
|
||||
stringPropertyEClass = createEClass(STRING_PROPERTY);
|
||||
createEAttribute(stringPropertyEClass, STRING_PROPERTY__VALUE);
|
||||
|
||||
booleanPropertyEClass = createEClass(BOOLEAN_PROPERTY);
|
||||
createEAttribute(booleanPropertyEClass, BOOLEAN_PROPERTY__VALUE);
|
||||
|
||||
referencePropertyEClass = createEClass(REFERENCE_PROPERTY);
|
||||
createEReference(referencePropertyEClass, REFERENCE_PROPERTY__REF);
|
||||
|
||||
propertyHolderEClass = createEClass(PROPERTY_HOLDER);
|
||||
createEReference(propertyHolderEClass, PROPERTY_HOLDER__PROPERTIES);
|
||||
|
||||
namedElementEClass = createEClass(NAMED_ELEMENT);
|
||||
createEAttribute(namedElementEClass, NAMED_ELEMENT__NAME);
|
||||
|
||||
identifiedElementEClass = createEClass(IDENTIFIED_ELEMENT);
|
||||
createEAttribute(identifiedElementEClass, IDENTIFIED_ELEMENT__UID);
|
||||
|
||||
modelEClass = createEClass(MODEL);
|
||||
createEReference(modelEClass, MODEL__MODEL_ELEMENTS);
|
||||
|
||||
borderElementEClass = createEClass(BORDER_ELEMENT);
|
||||
|
||||
elementEClass = createEClass(ELEMENT);
|
||||
|
||||
// Create enums
|
||||
portDirectionEEnum = createEEnum(PORT_DIRECTION);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private boolean isInitialized = false;
|
||||
|
||||
/**
|
||||
* Complete the initialization of the package and its meta-model. This
|
||||
* method is guarded to have no affect on any invocation but its first.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void initializePackageContents() {
|
||||
if (isInitialized)
|
||||
return;
|
||||
isInitialized = true;
|
||||
|
||||
// Initialize package
|
||||
setName(eNAME);
|
||||
setNsPrefix(eNS_PREFIX);
|
||||
setNsURI(eNS_URI);
|
||||
|
||||
// Create type parameters
|
||||
|
||||
// Set bounds for type parameters
|
||||
|
||||
// Add supertypes to classes
|
||||
componentEClass.getESuperTypes().add(this.getGraphElement());
|
||||
portEClass.getESuperTypes().add(this.getBorderElement());
|
||||
linkEClass.getESuperTypes().add(this.getGraphElement());
|
||||
graphElementEClass.getESuperTypes().add(this.getElement());
|
||||
propertyEClass.getESuperTypes().add(this.getIdentifiedElement());
|
||||
basicPropertyEClass.getESuperTypes().add(this.getProperty());
|
||||
integerPropertyEClass.getESuperTypes().add(this.getBasicProperty());
|
||||
stringPropertyEClass.getESuperTypes().add(this.getBasicProperty());
|
||||
booleanPropertyEClass.getESuperTypes().add(this.getBasicProperty());
|
||||
referencePropertyEClass.getESuperTypes().add(this.getProperty());
|
||||
propertyHolderEClass.getESuperTypes().add(this.getNamedElement());
|
||||
namedElementEClass.getESuperTypes().add(this.getIdentifiedElement());
|
||||
modelEClass.getESuperTypes().add(this.getPropertyHolder());
|
||||
borderElementEClass.getESuperTypes().add(this.getElement());
|
||||
elementEClass.getESuperTypes().add(this.getPropertyHolder());
|
||||
|
||||
// Initialize classes, features, and operations; add parameters
|
||||
initEClass(componentEClass, Component.class, "Component", !IS_ABSTRACT, !IS_INTERFACE,
|
||||
IS_GENERATED_INSTANCE_CLASS);
|
||||
initEReference(getComponent_Content(), this.getElement(), null, "content", null, 0, -1, Component.class,
|
||||
!IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE,
|
||||
IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
|
||||
|
||||
initEClass(portEClass, Port.class, "Port", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
|
||||
initEAttribute(getPort_Direction(), this.getPortDirection(), "direction", null, 1, 1, Port.class, !IS_TRANSIENT,
|
||||
!IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
|
||||
|
||||
initEClass(linkEClass, Link.class, "Link", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
|
||||
initEReference(getLink_Src(), this.getPort(), null, "src", null, 0, 1, Link.class, !IS_TRANSIENT, !IS_VOLATILE,
|
||||
IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
|
||||
initEReference(getLink_Dst(), this.getPort(), null, "dst", null, 0, 1, Link.class, !IS_TRANSIENT, !IS_VOLATILE,
|
||||
IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
|
||||
|
||||
initEClass(graphElementEClass, GraphElement.class, "GraphElement", IS_ABSTRACT, IS_INTERFACE,
|
||||
IS_GENERATED_INSTANCE_CLASS);
|
||||
|
||||
initEClass(propertyEClass, Property.class, "Property", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
|
||||
initEAttribute(getProperty_Key(), ecorePackage.getEString(), "key", null, 1, 1, Property.class, !IS_TRANSIENT,
|
||||
!IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
|
||||
|
||||
initEClass(basicPropertyEClass, BasicProperty.class, "BasicProperty", IS_ABSTRACT, IS_INTERFACE,
|
||||
IS_GENERATED_INSTANCE_CLASS);
|
||||
|
||||
initEClass(integerPropertyEClass, IntegerProperty.class, "IntegerProperty", !IS_ABSTRACT, !IS_INTERFACE,
|
||||
IS_GENERATED_INSTANCE_CLASS);
|
||||
initEAttribute(getIntegerProperty_Value(), ecorePackage.getEInt(), "value", "0", 1, 1, IntegerProperty.class,
|
||||
!IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
|
||||
|
||||
initEClass(stringPropertyEClass, StringProperty.class, "StringProperty", !IS_ABSTRACT, !IS_INTERFACE,
|
||||
IS_GENERATED_INSTANCE_CLASS);
|
||||
initEAttribute(getStringProperty_Value(), ecorePackage.getEString(), "value", "\'\'", 1, 1,
|
||||
StringProperty.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
|
||||
!IS_DERIVED, IS_ORDERED);
|
||||
|
||||
initEClass(booleanPropertyEClass, BooleanProperty.class, "BooleanProperty", !IS_ABSTRACT, !IS_INTERFACE,
|
||||
IS_GENERATED_INSTANCE_CLASS);
|
||||
initEAttribute(getBooleanProperty_Value(), ecorePackage.getEBoolean(), "value", "false", 1, 1,
|
||||
BooleanProperty.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
|
||||
!IS_DERIVED, IS_ORDERED);
|
||||
|
||||
initEClass(referencePropertyEClass, ReferenceProperty.class, "ReferenceProperty", !IS_ABSTRACT, !IS_INTERFACE,
|
||||
IS_GENERATED_INSTANCE_CLASS);
|
||||
initEReference(getReferenceProperty_Ref(), this.getPropertyHolder(), null, "ref", null, 1, 1,
|
||||
ReferenceProperty.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES,
|
||||
!IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
|
||||
|
||||
initEClass(propertyHolderEClass, PropertyHolder.class, "PropertyHolder", IS_ABSTRACT, IS_INTERFACE,
|
||||
IS_GENERATED_INSTANCE_CLASS);
|
||||
initEReference(getPropertyHolder_Properties(), this.getProperty(), null, "properties", null, 0, -1,
|
||||
PropertyHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES,
|
||||
!IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
|
||||
|
||||
initEClass(namedElementEClass, NamedElement.class, "NamedElement", IS_ABSTRACT, IS_INTERFACE,
|
||||
IS_GENERATED_INSTANCE_CLASS);
|
||||
initEAttribute(getNamedElement_Name(), ecorePackage.getEString(), "name", null, 0, 1, NamedElement.class,
|
||||
!IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
|
||||
|
||||
initEClass(identifiedElementEClass, IdentifiedElement.class, "IdentifiedElement", IS_ABSTRACT, IS_INTERFACE,
|
||||
IS_GENERATED_INSTANCE_CLASS);
|
||||
initEAttribute(getIdentifiedElement_Uid(), ecorePackage.getEString(), "uid", null, 0, 1,
|
||||
IdentifiedElement.class, !IS_TRANSIENT, !IS_VOLATILE, !IS_CHANGEABLE, IS_UNSETTABLE, IS_ID, IS_UNIQUE,
|
||||
!IS_DERIVED, IS_ORDERED);
|
||||
|
||||
initEClass(modelEClass, Model.class, "Model", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
|
||||
initEReference(getModel_ModelElements(), this.getGraphElement(), null, "modelElements", null, 0, -1,
|
||||
Model.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES,
|
||||
!IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
|
||||
|
||||
initEClass(borderElementEClass, BorderElement.class, "BorderElement", IS_ABSTRACT, IS_INTERFACE,
|
||||
IS_GENERATED_INSTANCE_CLASS);
|
||||
|
||||
initEClass(elementEClass, Element.class, "Element", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
|
||||
|
||||
// Initialize enums and add enum literals
|
||||
initEEnum(portDirectionEEnum, PortDirection.class, "PortDirection");
|
||||
addEEnumLiteral(portDirectionEEnum, PortDirection.UNSPECIFIED);
|
||||
addEEnumLiteral(portDirectionEEnum, PortDirection.IN);
|
||||
addEEnumLiteral(portDirectionEEnum, PortDirection.OUT);
|
||||
addEEnumLiteral(portDirectionEEnum, PortDirection.INOUT);
|
||||
|
||||
// Create resource
|
||||
createResource(eNS_URI);
|
||||
|
||||
// Create annotations
|
||||
// http://www.eclipse.org/OCL/Import
|
||||
createImportAnnotations();
|
||||
// http://www.eclipse.org/emf/2002/Ecore
|
||||
createEcoreAnnotations();
|
||||
// http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot
|
||||
createPivotAnnotations();
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the annotations for <b>http://www.eclipse.org/OCL/Import</b>.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected void createImportAnnotations() {
|
||||
String source = "http://www.eclipse.org/OCL/Import";
|
||||
addAnnotation(this, source, new String[] { "ecore", "http://www.eclipse.org/emf/2002/Ecore" });
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the annotations for <b>http://www.eclipse.org/emf/2002/Ecore</b>.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected void createEcoreAnnotations() {
|
||||
String source = "http://www.eclipse.org/emf/2002/Ecore";
|
||||
addAnnotation(this, source,
|
||||
new String[] { "invocationDelegates", "http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot",
|
||||
"settingDelegates", "http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot", "validationDelegates",
|
||||
"http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot" });
|
||||
addAnnotation(propertyEClass, source, new String[] { "constraints", "keyNotNull" });
|
||||
addAnnotation(propertyHolderEClass, source, new String[] { "constraints", "uniqueKeys" });
|
||||
addAnnotation(namedElementEClass, source, new String[] { "constraints", "nameNotEmpty" });
|
||||
addAnnotation(identifiedElementEClass, source, new String[] { "constraints", "uidNotEmpty" });
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the annotations for <b>http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot</b>.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected void createPivotAnnotations() {
|
||||
String source = "http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot";
|
||||
addAnnotation(propertyEClass, source, new String[] { "keyNotNull", "key <> \'\'" });
|
||||
addAnnotation(propertyHolderEClass, source,
|
||||
new String[] { "uniqueKeys", "properties->forAll(p1, p2 | p1 <> p2 implies p1.key <> p2.key)" });
|
||||
addAnnotation(namedElementEClass, source, new String[] { "nameNotEmpty", "name <> \'\'" });
|
||||
addAnnotation(identifiedElementEClass, source, new String[] { "uidNotEmpty", "uid <> \'\'" });
|
||||
}
|
||||
|
||||
} //SeimPackageImpl
|
||||
@@ -0,0 +1,288 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim.impl;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.SeimPackage;
|
||||
import com.irtsaintexupery.pseim.seim.StringProperty;
|
||||
|
||||
import org.eclipse.emf.common.notify.Notification;
|
||||
|
||||
import org.eclipse.emf.ecore.EClass;
|
||||
|
||||
import org.eclipse.emf.ecore.impl.ENotificationImpl;
|
||||
import org.eclipse.emf.ecore.impl.MinimalEObjectImpl;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* An implementation of the model object '<em><b>String Property</b></em>'.
|
||||
* <!-- end-user-doc -->
|
||||
* <p>
|
||||
* The following features are implemented:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.StringPropertyImpl#getUid <em>Uid</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.StringPropertyImpl#getKey <em>Key</em>}</li>
|
||||
* <li>{@link com.irtsaintexupery.pseim.seim.impl.StringPropertyImpl#getValue <em>Value</em>}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @generated
|
||||
*/
|
||||
public class StringPropertyImpl extends MinimalEObjectImpl.Container implements StringProperty {
|
||||
/**
|
||||
* The default value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String UID_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getUid() <em>Uid</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getUid()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String uid = UID_EDEFAULT;
|
||||
|
||||
/**
|
||||
* This is true if the Uid attribute has been set.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected boolean uidESet;
|
||||
|
||||
/**
|
||||
* The default value of the '{@link #getKey() <em>Key</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getKey()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String KEY_EDEFAULT = null;
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getKey() <em>Key</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getKey()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String key = KEY_EDEFAULT;
|
||||
|
||||
/**
|
||||
* The default value of the '{@link #getValue() <em>Value</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getValue()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected static final String VALUE_EDEFAULT = "\'\'";
|
||||
|
||||
/**
|
||||
* The cached value of the '{@link #getValue() <em>Value</em>}' attribute.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see #getValue()
|
||||
* @generated
|
||||
* @ordered
|
||||
*/
|
||||
protected String value = VALUE_EDEFAULT;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected StringPropertyImpl() {
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
protected EClass eStaticClass() {
|
||||
return SeimPackage.Literals.STRING_PROPERTY;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getUid() {
|
||||
return uid;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean isSetUid() {
|
||||
return uidESet;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getKey() {
|
||||
return key;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setKey(String newKey) {
|
||||
String oldKey = key;
|
||||
key = newKey;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.STRING_PROPERTY__KEY, oldKey, key));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public String getValue() {
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public void setValue(String newValue) {
|
||||
String oldValue = value;
|
||||
value = newValue;
|
||||
if (eNotificationRequired())
|
||||
eNotify(new ENotificationImpl(this, Notification.SET, SeimPackage.STRING_PROPERTY__VALUE, oldValue, value));
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public Object eGet(int featureID, boolean resolve, boolean coreType) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.STRING_PROPERTY__UID:
|
||||
return getUid();
|
||||
case SeimPackage.STRING_PROPERTY__KEY:
|
||||
return getKey();
|
||||
case SeimPackage.STRING_PROPERTY__VALUE:
|
||||
return getValue();
|
||||
}
|
||||
return super.eGet(featureID, resolve, coreType);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public void eSet(int featureID, Object newValue) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.STRING_PROPERTY__KEY:
|
||||
setKey((String) newValue);
|
||||
return;
|
||||
case SeimPackage.STRING_PROPERTY__VALUE:
|
||||
setValue((String) newValue);
|
||||
return;
|
||||
}
|
||||
super.eSet(featureID, newValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public void eUnset(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.STRING_PROPERTY__KEY:
|
||||
setKey(KEY_EDEFAULT);
|
||||
return;
|
||||
case SeimPackage.STRING_PROPERTY__VALUE:
|
||||
setValue(VALUE_EDEFAULT);
|
||||
return;
|
||||
}
|
||||
super.eUnset(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public boolean eIsSet(int featureID) {
|
||||
switch (featureID) {
|
||||
case SeimPackage.STRING_PROPERTY__UID:
|
||||
return isSetUid();
|
||||
case SeimPackage.STRING_PROPERTY__KEY:
|
||||
return KEY_EDEFAULT == null ? key != null : !KEY_EDEFAULT.equals(key);
|
||||
case SeimPackage.STRING_PROPERTY__VALUE:
|
||||
return VALUE_EDEFAULT == null ? value != null : !VALUE_EDEFAULT.equals(value);
|
||||
}
|
||||
return super.eIsSet(featureID);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
if (eIsProxy())
|
||||
return super.toString();
|
||||
|
||||
StringBuffer result = new StringBuffer(super.toString());
|
||||
result.append(" (uid: ");
|
||||
if (uidESet)
|
||||
result.append(uid);
|
||||
else
|
||||
result.append("<unset>");
|
||||
result.append(", key: ");
|
||||
result.append(key);
|
||||
result.append(", value: ");
|
||||
result.append(value);
|
||||
result.append(')');
|
||||
return result.toString();
|
||||
}
|
||||
|
||||
} //StringPropertyImpl
|
||||
@@ -0,0 +1,417 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim.util;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.*;
|
||||
|
||||
import org.eclipse.emf.common.notify.Adapter;
|
||||
import org.eclipse.emf.common.notify.Notifier;
|
||||
|
||||
import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl;
|
||||
|
||||
import org.eclipse.emf.ecore.EObject;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* The <b>Adapter Factory</b> for the model.
|
||||
* It provides an adapter <code>createXXX</code> method for each class of the model.
|
||||
* <!-- end-user-doc -->
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage
|
||||
* @generated
|
||||
*/
|
||||
public class SeimAdapterFactory extends AdapterFactoryImpl {
|
||||
/**
|
||||
* The cached model package.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected static SeimPackage modelPackage;
|
||||
|
||||
/**
|
||||
* Creates an instance of the adapter factory.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public SeimAdapterFactory() {
|
||||
if (modelPackage == null) {
|
||||
modelPackage = SeimPackage.eINSTANCE;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns whether this factory is applicable for the type of the object.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns <code>true</code> if the object is either the model's package or is an instance object of the model.
|
||||
* <!-- end-user-doc -->
|
||||
* @return whether this factory is applicable for the type of the object.
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public boolean isFactoryForType(Object object) {
|
||||
if (object == modelPackage) {
|
||||
return true;
|
||||
}
|
||||
if (object instanceof EObject) {
|
||||
return ((EObject) object).eClass().getEPackage() == modelPackage;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* The switch that delegates to the <code>createXXX</code> methods.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected SeimSwitch<Adapter> modelSwitch = new SeimSwitch<Adapter>() {
|
||||
@Override
|
||||
public Adapter caseComponent(Component object) {
|
||||
return createComponentAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter casePort(Port object) {
|
||||
return createPortAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter caseLink(Link object) {
|
||||
return createLinkAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter caseGraphElement(GraphElement object) {
|
||||
return createGraphElementAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter caseProperty(Property object) {
|
||||
return createPropertyAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter caseBasicProperty(BasicProperty object) {
|
||||
return createBasicPropertyAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter caseIntegerProperty(IntegerProperty object) {
|
||||
return createIntegerPropertyAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter caseStringProperty(StringProperty object) {
|
||||
return createStringPropertyAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter caseBooleanProperty(BooleanProperty object) {
|
||||
return createBooleanPropertyAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter caseReferenceProperty(ReferenceProperty object) {
|
||||
return createReferencePropertyAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter casePropertyHolder(PropertyHolder object) {
|
||||
return createPropertyHolderAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter caseNamedElement(NamedElement object) {
|
||||
return createNamedElementAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter caseIdentifiedElement(IdentifiedElement object) {
|
||||
return createIdentifiedElementAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter caseModel(Model object) {
|
||||
return createModelAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter caseBorderElement(BorderElement object) {
|
||||
return createBorderElementAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter caseElement(Element object) {
|
||||
return createElementAdapter();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Adapter defaultCase(EObject object) {
|
||||
return createEObjectAdapter();
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* Creates an adapter for the <code>target</code>.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param target the object to adapt.
|
||||
* @return the adapter for the <code>target</code>.
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public Adapter createAdapter(Notifier target) {
|
||||
return modelSwitch.doSwitch((EObject) target);
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.Component <em>Component</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.Component
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createComponentAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.Port <em>Port</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.Port
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createPortAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.Link <em>Link</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.Link
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createLinkAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.GraphElement <em>Graph Element</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.GraphElement
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createGraphElementAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.Property <em>Property</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.Property
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createPropertyAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.BasicProperty <em>Basic Property</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.BasicProperty
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createBasicPropertyAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.IntegerProperty <em>Integer Property</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.IntegerProperty
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createIntegerPropertyAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.StringProperty <em>String Property</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.StringProperty
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createStringPropertyAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.BooleanProperty <em>Boolean Property</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.BooleanProperty
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createBooleanPropertyAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.ReferenceProperty <em>Reference Property</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.ReferenceProperty
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createReferencePropertyAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.PropertyHolder <em>Property Holder</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.PropertyHolder
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createPropertyHolderAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.NamedElement <em>Named Element</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.NamedElement
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createNamedElementAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.IdentifiedElement <em>Identified Element</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.IdentifiedElement
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createIdentifiedElementAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.Model <em>Model</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.Model
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createModelAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.BorderElement <em>Border Element</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.BorderElement
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createBorderElementAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for an object of class '{@link com.irtsaintexupery.pseim.seim.Element <em>Element</em>}'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null so that we can easily ignore cases;
|
||||
* it's useful to ignore a case when inheritance will catch all the cases anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @see com.irtsaintexupery.pseim.seim.Element
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createElementAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new adapter for the default case.
|
||||
* <!-- begin-user-doc -->
|
||||
* This default implementation returns null.
|
||||
* <!-- end-user-doc -->
|
||||
* @return the new adapter.
|
||||
* @generated
|
||||
*/
|
||||
public Adapter createEObjectAdapter() {
|
||||
return null;
|
||||
}
|
||||
|
||||
} //SeimAdapterFactory
|
||||
@@ -0,0 +1,547 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim.util;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.*;
|
||||
|
||||
import org.eclipse.emf.ecore.EObject;
|
||||
import org.eclipse.emf.ecore.EPackage;
|
||||
|
||||
import org.eclipse.emf.ecore.util.Switch;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* The <b>Switch</b> for the model's inheritance hierarchy.
|
||||
* It supports the call {@link #doSwitch(EObject) doSwitch(object)}
|
||||
* to invoke the <code>caseXXX</code> method for each class of the model,
|
||||
* starting with the actual class of the object
|
||||
* and proceeding up the inheritance hierarchy
|
||||
* until a non-null result is returned,
|
||||
* which is the result of the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage
|
||||
* @generated
|
||||
*/
|
||||
public class SeimSwitch<T> extends Switch<T> {
|
||||
/**
|
||||
* The cached model package
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected static SeimPackage modelPackage;
|
||||
|
||||
/**
|
||||
* Creates an instance of the switch.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public SeimSwitch() {
|
||||
if (modelPackage == null) {
|
||||
modelPackage = SeimPackage.eINSTANCE;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks whether this is a switch for the given package.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @param ePackage the package in question.
|
||||
* @return whether this is a switch for the given package.
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
protected boolean isSwitchFor(EPackage ePackage) {
|
||||
return ePackage == modelPackage;
|
||||
}
|
||||
|
||||
/**
|
||||
* Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @return the first non-null result returned by a <code>caseXXX</code> call.
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
protected T doSwitch(int classifierID, EObject theEObject) {
|
||||
switch (classifierID) {
|
||||
case SeimPackage.COMPONENT: {
|
||||
Component component = (Component) theEObject;
|
||||
T result = caseComponent(component);
|
||||
if (result == null)
|
||||
result = caseGraphElement(component);
|
||||
if (result == null)
|
||||
result = caseElement(component);
|
||||
if (result == null)
|
||||
result = casePropertyHolder(component);
|
||||
if (result == null)
|
||||
result = caseNamedElement(component);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(component);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.PORT: {
|
||||
Port port = (Port) theEObject;
|
||||
T result = casePort(port);
|
||||
if (result == null)
|
||||
result = caseBorderElement(port);
|
||||
if (result == null)
|
||||
result = caseElement(port);
|
||||
if (result == null)
|
||||
result = casePropertyHolder(port);
|
||||
if (result == null)
|
||||
result = caseNamedElement(port);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(port);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.LINK: {
|
||||
Link link = (Link) theEObject;
|
||||
T result = caseLink(link);
|
||||
if (result == null)
|
||||
result = caseGraphElement(link);
|
||||
if (result == null)
|
||||
result = caseElement(link);
|
||||
if (result == null)
|
||||
result = casePropertyHolder(link);
|
||||
if (result == null)
|
||||
result = caseNamedElement(link);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(link);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.GRAPH_ELEMENT: {
|
||||
GraphElement graphElement = (GraphElement) theEObject;
|
||||
T result = caseGraphElement(graphElement);
|
||||
if (result == null)
|
||||
result = caseElement(graphElement);
|
||||
if (result == null)
|
||||
result = casePropertyHolder(graphElement);
|
||||
if (result == null)
|
||||
result = caseNamedElement(graphElement);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(graphElement);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.PROPERTY: {
|
||||
Property property = (Property) theEObject;
|
||||
T result = caseProperty(property);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(property);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.BASIC_PROPERTY: {
|
||||
BasicProperty basicProperty = (BasicProperty) theEObject;
|
||||
T result = caseBasicProperty(basicProperty);
|
||||
if (result == null)
|
||||
result = caseProperty(basicProperty);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(basicProperty);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.INTEGER_PROPERTY: {
|
||||
IntegerProperty integerProperty = (IntegerProperty) theEObject;
|
||||
T result = caseIntegerProperty(integerProperty);
|
||||
if (result == null)
|
||||
result = caseBasicProperty(integerProperty);
|
||||
if (result == null)
|
||||
result = caseProperty(integerProperty);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(integerProperty);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.STRING_PROPERTY: {
|
||||
StringProperty stringProperty = (StringProperty) theEObject;
|
||||
T result = caseStringProperty(stringProperty);
|
||||
if (result == null)
|
||||
result = caseBasicProperty(stringProperty);
|
||||
if (result == null)
|
||||
result = caseProperty(stringProperty);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(stringProperty);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.BOOLEAN_PROPERTY: {
|
||||
BooleanProperty booleanProperty = (BooleanProperty) theEObject;
|
||||
T result = caseBooleanProperty(booleanProperty);
|
||||
if (result == null)
|
||||
result = caseBasicProperty(booleanProperty);
|
||||
if (result == null)
|
||||
result = caseProperty(booleanProperty);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(booleanProperty);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.REFERENCE_PROPERTY: {
|
||||
ReferenceProperty referenceProperty = (ReferenceProperty) theEObject;
|
||||
T result = caseReferenceProperty(referenceProperty);
|
||||
if (result == null)
|
||||
result = caseProperty(referenceProperty);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(referenceProperty);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.PROPERTY_HOLDER: {
|
||||
PropertyHolder propertyHolder = (PropertyHolder) theEObject;
|
||||
T result = casePropertyHolder(propertyHolder);
|
||||
if (result == null)
|
||||
result = caseNamedElement(propertyHolder);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(propertyHolder);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.NAMED_ELEMENT: {
|
||||
NamedElement namedElement = (NamedElement) theEObject;
|
||||
T result = caseNamedElement(namedElement);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(namedElement);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.IDENTIFIED_ELEMENT: {
|
||||
IdentifiedElement identifiedElement = (IdentifiedElement) theEObject;
|
||||
T result = caseIdentifiedElement(identifiedElement);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.MODEL: {
|
||||
Model model = (Model) theEObject;
|
||||
T result = caseModel(model);
|
||||
if (result == null)
|
||||
result = casePropertyHolder(model);
|
||||
if (result == null)
|
||||
result = caseNamedElement(model);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(model);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.BORDER_ELEMENT: {
|
||||
BorderElement borderElement = (BorderElement) theEObject;
|
||||
T result = caseBorderElement(borderElement);
|
||||
if (result == null)
|
||||
result = caseElement(borderElement);
|
||||
if (result == null)
|
||||
result = casePropertyHolder(borderElement);
|
||||
if (result == null)
|
||||
result = caseNamedElement(borderElement);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(borderElement);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
case SeimPackage.ELEMENT: {
|
||||
Element element = (Element) theEObject;
|
||||
T result = caseElement(element);
|
||||
if (result == null)
|
||||
result = casePropertyHolder(element);
|
||||
if (result == null)
|
||||
result = caseNamedElement(element);
|
||||
if (result == null)
|
||||
result = caseIdentifiedElement(element);
|
||||
if (result == null)
|
||||
result = defaultCase(theEObject);
|
||||
return result;
|
||||
}
|
||||
default:
|
||||
return defaultCase(theEObject);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Component</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Component</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseComponent(Component object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Port</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Port</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T casePort(Port object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Link</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Link</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseLink(Link object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Graph Element</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Graph Element</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseGraphElement(GraphElement object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Property</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Property</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseProperty(Property object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Basic Property</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Basic Property</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseBasicProperty(BasicProperty object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Integer Property</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Integer Property</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseIntegerProperty(IntegerProperty object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>String Property</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>String Property</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseStringProperty(StringProperty object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Boolean Property</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Boolean Property</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseBooleanProperty(BooleanProperty object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Reference Property</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Reference Property</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseReferenceProperty(ReferenceProperty object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Property Holder</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Property Holder</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T casePropertyHolder(PropertyHolder object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Named Element</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Named Element</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseNamedElement(NamedElement object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Identified Element</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Identified Element</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseIdentifiedElement(IdentifiedElement object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Model</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Model</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseModel(Model object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Border Element</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Border Element</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseBorderElement(BorderElement object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>Element</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>Element</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
|
||||
* @generated
|
||||
*/
|
||||
public T caseElement(Element object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the result of interpreting the object as an instance of '<em>EObject</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* This implementation returns null;
|
||||
* returning a non-null result will terminate the switch, but this is the last case anyway.
|
||||
* <!-- end-user-doc -->
|
||||
* @param object the target of the switch.
|
||||
* @return the result of interpreting the object as an instance of '<em>EObject</em>'.
|
||||
* @see #doSwitch(org.eclipse.emf.ecore.EObject)
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public T defaultCase(EObject object) {
|
||||
return null;
|
||||
}
|
||||
|
||||
} //SeimSwitch
|
||||
@@ -0,0 +1,754 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 IRT AESE (IRT Saint Exupéry).
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v2.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* https://www.eclipse.org/legal/epl-2.0
|
||||
*
|
||||
* Contributors:
|
||||
* Arnaud Dieumegard (IRT Saint Exupéry) - initial API and implementation
|
||||
* Pierre Virelizier (IRT Saint Exupéry)
|
||||
* Julien Baclet (IRT Saint Exupéry)
|
||||
* Pierre Gaufillet (IRT Saint Exupéry)
|
||||
*******************************************************************************/
|
||||
/**
|
||||
*/
|
||||
package com.irtsaintexupery.pseim.seim.util;
|
||||
|
||||
import com.irtsaintexupery.pseim.seim.*;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
import org.eclipse.emf.common.util.Diagnostic;
|
||||
import org.eclipse.emf.common.util.DiagnosticChain;
|
||||
import org.eclipse.emf.common.util.ResourceLocator;
|
||||
|
||||
import org.eclipse.emf.ecore.EPackage;
|
||||
|
||||
import org.eclipse.emf.ecore.util.EObjectValidator;
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* The <b>Validator</b> for the model.
|
||||
* <!-- end-user-doc -->
|
||||
* @see com.irtsaintexupery.pseim.seim.SeimPackage
|
||||
* @generated
|
||||
*/
|
||||
public class SeimValidator extends EObjectValidator {
|
||||
/**
|
||||
* The cached model package
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public static final SeimValidator INSTANCE = new SeimValidator();
|
||||
|
||||
/**
|
||||
* A constant for the {@link org.eclipse.emf.common.util.Diagnostic#getSource() source} of diagnostic {@link org.eclipse.emf.common.util.Diagnostic#getCode() codes} from this package.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @see org.eclipse.emf.common.util.Diagnostic#getSource()
|
||||
* @see org.eclipse.emf.common.util.Diagnostic#getCode()
|
||||
* @generated
|
||||
*/
|
||||
public static final String DIAGNOSTIC_SOURCE = "com.irtsaintexupery.pseim.seim";
|
||||
|
||||
/**
|
||||
* A constant with a fixed name that can be used as the base value for additional hand written constants.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
private static final int GENERATED_DIAGNOSTIC_CODE_COUNT = 0;
|
||||
|
||||
/**
|
||||
* A constant with a fixed name that can be used as the base value for additional hand written constants in a derived class.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected static final int DIAGNOSTIC_CODE_COUNT = GENERATED_DIAGNOSTIC_CODE_COUNT;
|
||||
|
||||
/**
|
||||
* Creates an instance of the switch.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public SeimValidator() {
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the package of this validator switch.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
protected EPackage getEPackage() {
|
||||
return SeimPackage.eINSTANCE;
|
||||
}
|
||||
|
||||
/**
|
||||
* Calls <code>validateXXX</code> for the corresponding classifier of the model.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
protected boolean validate(int classifierID, Object value, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
switch (classifierID) {
|
||||
case SeimPackage.COMPONENT:
|
||||
return validateComponent((Component) value, diagnostics, context);
|
||||
case SeimPackage.PORT:
|
||||
return validatePort((Port) value, diagnostics, context);
|
||||
case SeimPackage.LINK:
|
||||
return validateLink((Link) value, diagnostics, context);
|
||||
case SeimPackage.GRAPH_ELEMENT:
|
||||
return validateGraphElement((GraphElement) value, diagnostics, context);
|
||||
case SeimPackage.PROPERTY:
|
||||
return validateProperty((Property) value, diagnostics, context);
|
||||
case SeimPackage.BASIC_PROPERTY:
|
||||
return validateBasicProperty((BasicProperty) value, diagnostics, context);
|
||||
case SeimPackage.INTEGER_PROPERTY:
|
||||
return validateIntegerProperty((IntegerProperty) value, diagnostics, context);
|
||||
case SeimPackage.STRING_PROPERTY:
|
||||
return validateStringProperty((StringProperty) value, diagnostics, context);
|
||||
case SeimPackage.BOOLEAN_PROPERTY:
|
||||
return validateBooleanProperty((BooleanProperty) value, diagnostics, context);
|
||||
case SeimPackage.REFERENCE_PROPERTY:
|
||||
return validateReferenceProperty((ReferenceProperty) value, diagnostics, context);
|
||||
case SeimPackage.PROPERTY_HOLDER:
|
||||
return validatePropertyHolder((PropertyHolder) value, diagnostics, context);
|
||||
case SeimPackage.NAMED_ELEMENT:
|
||||
return validateNamedElement((NamedElement) value, diagnostics, context);
|
||||
case SeimPackage.IDENTIFIED_ELEMENT:
|
||||
return validateIdentifiedElement((IdentifiedElement) value, diagnostics, context);
|
||||
case SeimPackage.MODEL:
|
||||
return validateModel((Model) value, diagnostics, context);
|
||||
case SeimPackage.BORDER_ELEMENT:
|
||||
return validateBorderElement((BorderElement) value, diagnostics, context);
|
||||
case SeimPackage.ELEMENT:
|
||||
return validateElement((Element) value, diagnostics, context);
|
||||
case SeimPackage.PORT_DIRECTION:
|
||||
return validatePortDirection((PortDirection) value, diagnostics, context);
|
||||
default:
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateComponent(Component component, DiagnosticChain diagnostics, Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(component, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(component, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(component, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(component, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(component, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(component, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(component, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(component, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(component, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(component, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateNamedElement_nameNotEmpty(component, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validatePropertyHolder_uniqueKeys(component, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validatePort(Port port, DiagnosticChain diagnostics, Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(port, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(port, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(port, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(port, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(port, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(port, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(port, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(port, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(port, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(port, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateNamedElement_nameNotEmpty(port, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validatePropertyHolder_uniqueKeys(port, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateLink(Link link, DiagnosticChain diagnostics, Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(link, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(link, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(link, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(link, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(link, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(link, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(link, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(link, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(link, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(link, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateNamedElement_nameNotEmpty(link, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validatePropertyHolder_uniqueKeys(link, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateGraphElement(GraphElement graphElement, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(graphElement, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(graphElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(graphElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(graphElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(graphElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(graphElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(graphElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(graphElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(graphElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(graphElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateNamedElement_nameNotEmpty(graphElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validatePropertyHolder_uniqueKeys(graphElement, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateProperty(Property property, DiagnosticChain diagnostics, Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(property, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(property, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(property, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(property, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(property, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(property, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(property, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(property, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(property, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(property, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateProperty_keyNotNull(property, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* The cached validation expression for the keyNotNull constraint of '<em>Property</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected static final String PROPERTY__KEY_NOT_NULL__EEXPRESSION = "key <> ''";
|
||||
|
||||
/**
|
||||
* Validates the keyNotNull constraint of '<em>Property</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateProperty_keyNotNull(Property property, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
return validate(SeimPackage.Literals.PROPERTY, property, diagnostics, context,
|
||||
"http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot", "keyNotNull", PROPERTY__KEY_NOT_NULL__EEXPRESSION,
|
||||
Diagnostic.ERROR, DIAGNOSTIC_SOURCE, 0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateBasicProperty(BasicProperty basicProperty, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(basicProperty, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(basicProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(basicProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(basicProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(basicProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(basicProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(basicProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(basicProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(basicProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(basicProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateProperty_keyNotNull(basicProperty, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateIntegerProperty(IntegerProperty integerProperty, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(integerProperty, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(integerProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(integerProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(integerProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(integerProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(integerProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(integerProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(integerProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(integerProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(integerProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateProperty_keyNotNull(integerProperty, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateStringProperty(StringProperty stringProperty, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(stringProperty, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(stringProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(stringProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(stringProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(stringProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(stringProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(stringProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(stringProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(stringProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(stringProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateProperty_keyNotNull(stringProperty, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateBooleanProperty(BooleanProperty booleanProperty, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(booleanProperty, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(booleanProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(booleanProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(booleanProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(booleanProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(booleanProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(booleanProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(booleanProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(booleanProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(booleanProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateProperty_keyNotNull(booleanProperty, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateReferenceProperty(ReferenceProperty referenceProperty, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(referenceProperty, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(referenceProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(referenceProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(referenceProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(referenceProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(referenceProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(referenceProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(referenceProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(referenceProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(referenceProperty, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateProperty_keyNotNull(referenceProperty, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validatePropertyHolder(PropertyHolder propertyHolder, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(propertyHolder, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(propertyHolder, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(propertyHolder, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(propertyHolder, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(propertyHolder, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(propertyHolder, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(propertyHolder, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(propertyHolder, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(propertyHolder, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(propertyHolder, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateNamedElement_nameNotEmpty(propertyHolder, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validatePropertyHolder_uniqueKeys(propertyHolder, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* The cached validation expression for the uniqueKeys constraint of '<em>Property Holder</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected static final String PROPERTY_HOLDER__UNIQUE_KEYS__EEXPRESSION = "properties->forAll(p1, p2 | p1 <> p2 implies p1.key <> p2.key)";
|
||||
|
||||
/**
|
||||
* Validates the uniqueKeys constraint of '<em>Property Holder</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validatePropertyHolder_uniqueKeys(PropertyHolder propertyHolder, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
return validate(SeimPackage.Literals.PROPERTY_HOLDER, propertyHolder, diagnostics, context,
|
||||
"http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot", "uniqueKeys",
|
||||
PROPERTY_HOLDER__UNIQUE_KEYS__EEXPRESSION, Diagnostic.ERROR, DIAGNOSTIC_SOURCE, 0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateNamedElement(NamedElement namedElement, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(namedElement, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(namedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(namedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(namedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(namedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(namedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(namedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(namedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(namedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(namedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateNamedElement_nameNotEmpty(namedElement, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* The cached validation expression for the nameNotEmpty constraint of '<em>Named Element</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected static final String NAMED_ELEMENT__NAME_NOT_EMPTY__EEXPRESSION = "name <> ''";
|
||||
|
||||
/**
|
||||
* Validates the nameNotEmpty constraint of '<em>Named Element</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateNamedElement_nameNotEmpty(NamedElement namedElement, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
return validate(SeimPackage.Literals.NAMED_ELEMENT, namedElement, diagnostics, context,
|
||||
"http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot", "nameNotEmpty",
|
||||
NAMED_ELEMENT__NAME_NOT_EMPTY__EEXPRESSION, Diagnostic.ERROR, DIAGNOSTIC_SOURCE, 0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateIdentifiedElement(IdentifiedElement identifiedElement, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(identifiedElement, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(identifiedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(identifiedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(identifiedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(identifiedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(identifiedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(identifiedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(identifiedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(identifiedElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(identifiedElement, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* The cached validation expression for the uidNotEmpty constraint of '<em>Identified Element</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
protected static final String IDENTIFIED_ELEMENT__UID_NOT_EMPTY__EEXPRESSION = "uid <> ''";
|
||||
|
||||
/**
|
||||
* Validates the uidNotEmpty constraint of '<em>Identified Element</em>'.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateIdentifiedElement_uidNotEmpty(IdentifiedElement identifiedElement,
|
||||
DiagnosticChain diagnostics, Map<Object, Object> context) {
|
||||
return validate(SeimPackage.Literals.IDENTIFIED_ELEMENT, identifiedElement, diagnostics, context,
|
||||
"http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot", "uidNotEmpty",
|
||||
IDENTIFIED_ELEMENT__UID_NOT_EMPTY__EEXPRESSION, Diagnostic.ERROR, DIAGNOSTIC_SOURCE, 0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateModel(Model model, DiagnosticChain diagnostics, Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(model, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(model, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(model, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(model, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(model, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(model, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(model, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(model, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(model, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(model, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateNamedElement_nameNotEmpty(model, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validatePropertyHolder_uniqueKeys(model, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateBorderElement(BorderElement borderElement, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(borderElement, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(borderElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(borderElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(borderElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(borderElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(borderElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(borderElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(borderElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(borderElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(borderElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateNamedElement_nameNotEmpty(borderElement, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validatePropertyHolder_uniqueKeys(borderElement, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validateElement(Element element, DiagnosticChain diagnostics, Map<Object, Object> context) {
|
||||
if (!validate_NoCircularContainment(element, diagnostics, context))
|
||||
return false;
|
||||
boolean result = validate_EveryMultiplicityConforms(element, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryDataValueConforms(element, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryReferenceIsContained(element, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryBidirectionalReferenceIsPaired(element, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryProxyResolves(element, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_UniqueID(element, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryKeyUnique(element, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validate_EveryMapEntryUnique(element, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateIdentifiedElement_uidNotEmpty(element, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validateNamedElement_nameNotEmpty(element, diagnostics, context);
|
||||
if (result || diagnostics != null)
|
||||
result &= validatePropertyHolder_uniqueKeys(element, diagnostics, context);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
public boolean validatePortDirection(PortDirection portDirection, DiagnosticChain diagnostics,
|
||||
Map<Object, Object> context) {
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the resource locator that will be used to fetch messages for this validator's diagnostics.
|
||||
* <!-- begin-user-doc -->
|
||||
* <!-- end-user-doc -->
|
||||
* @generated
|
||||
*/
|
||||
@Override
|
||||
public ResourceLocator getResourceLocator() {
|
||||
// TODO
|
||||
// Specialize this to return a resource locator for messages specific to this validator.
|
||||
// Ensure that you remove @generated or mark it @generated NOT
|
||||
return super.getResourceLocator();
|
||||
}
|
||||
|
||||
} //SeimValidator
|
||||
Reference in New Issue
Block a user