blob: 72e3b8ded15f357c77277785d53daa5753fa5813 [file] [log] [blame]
/*******************************************************************************
* Copyright (c) 2013 CEA LIST.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Cedric Dumoulin - cedric.dumoulin@lifl.fr
******************************************************************************/
/**
*/
package org.eclipse.papyrus.layers.stackmodel.layers;
import java.util.List;
import org.eclipse.emf.common.util.EList;
import org.eclipse.gmf.runtime.notation.Diagram;
import org.eclipse.gmf.runtime.notation.View;
import org.eclipse.papyrus.layers.stackmodel.LayersException;
import org.eclipse.papyrus.layers.stackmodel.command.ComputePropertyValueCommand;
/**
* <!-- begin-user-doc -->
* A representation of the model object '<em><b>Stack</b></em>'.
* <!-- end-user-doc -->
*
* <p>
* The following features are supported:
* <ul>
* <li>{@link org.eclipse.papyrus.layers.stackmodel.layers.LayersStack#getLayers <em>Layers</em>}</li>
* <li>{@link org.eclipse.papyrus.layers.stackmodel.layers.LayersStack#getName <em>Name</em>}</li>
* <li>{@link org.eclipse.papyrus.layers.stackmodel.layers.LayersStack#getDescription <em>Description</em>}</li>
* <li>{@link org.eclipse.papyrus.layers.stackmodel.layers.LayersStack#getDiagram <em>Diagram</em>}</li>
* <li>{@link org.eclipse.papyrus.layers.stackmodel.layers.LayersStack#getState <em>State</em>}</li>
* </ul>
* </p>
*
* @see org.eclipse.papyrus.layers.stackmodel.layers.LayersPackage#getLayersStack()
* @model
* @generated
*/
public interface LayersStack extends LayersContainer {
/**
* Returns the value of the '<em><b>Layers</b></em>' containment reference.
* <!-- begin-user-doc -->
* <p>
* If the meaning of the '<em>Layers</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>Layers</em>' containment reference.
* @see #setLayers(LayerExpression)
* @see org.eclipse.papyrus.layers.stackmodel.layers.LayersPackage#getLayersStack_Layers()
* @model containment="true" ordered="false"
* @generated
*/
LayerExpression getLayers();
/**
* Sets the value of the '{@link org.eclipse.papyrus.layers.stackmodel.layers.LayersStack#getLayers <em>Layers</em>}' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @param value
* the new value of the '<em>Layers</em>' containment reference.
* @see #getLayers()
* @generated
*/
void setLayers(LayerExpression value);
/**
* 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 org.eclipse.papyrus.layers.stackmodel.layers.LayersPackage#getLayersStack_Name()
* @model dataType="org.eclipse.papyrus.layers.stackmodel.layers.String" required="true" ordered="false"
* @generated
*/
String getName();
/**
* Sets the value of the '{@link org.eclipse.papyrus.layers.stackmodel.layers.LayersStack#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);
/**
* Returns the value of the '<em><b>Description</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
* If the meaning of the '<em>Description</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
*
* @return the value of the '<em>Description</em>' attribute.
* @see #setDescription(String)
* @see org.eclipse.papyrus.layers.stackmodel.layers.LayersPackage#getLayersStack_Description()
* @model dataType="org.eclipse.papyrus.layers.stackmodel.layers.String" required="true" ordered="false"
* @generated
*/
String getDescription();
/**
* Sets the value of the '{@link org.eclipse.papyrus.layers.stackmodel.layers.LayersStack#getDescription <em>Description</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @param value
* the new value of the '<em>Description</em>' attribute.
* @see #getDescription()
* @generated
*/
void setDescription(String value);
/**
* Returns the value of the '<em><b>Diagram</b></em>' reference.
* <!-- begin-user-doc -->
* <p>
* If the meaning of the '<em>Diagram</em>' reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
*
* @return the value of the '<em>Diagram</em>' reference.
* @see #setDiagram(Diagram)
* @see org.eclipse.papyrus.layers.stackmodel.layers.LayersPackage#getLayersStack_Diagram()
* @model ordered="false"
* @generated
*/
Diagram getDiagram();
/**
* Sets the value of the '{@link org.eclipse.papyrus.layers.stackmodel.layers.LayersStack#getDiagram <em>Diagram</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @param value
* the new value of the '<em>Diagram</em>' reference.
* @see #getDiagram()
* @generated
*/
void setDiagram(Diagram value);
/**
* Returns the value of the '<em><b>State</b></em>' attribute.
* The default value is <code>"detached"</code>.
* The literals are from the enumeration {@link org.eclipse.papyrus.layers.stackmodel.layers.LayerState}.
* <!-- begin-user-doc -->
* <p>
* If the meaning of the '<em>State</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
*
* @return the value of the '<em>State</em>' attribute.
* @see org.eclipse.papyrus.layers.stackmodel.layers.LayerState
* @see #setState(LayerState)
* @see org.eclipse.papyrus.layers.stackmodel.layers.LayersPackage#getLayersStack_State()
* @model default="detached" unique="false" required="true" ordered="false"
* @generated
*/
LayerState getState();
/**
* Sets the value of the '{@link org.eclipse.papyrus.layers.stackmodel.layers.LayersStack#getState <em>State</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @param value
* the new value of the '<em>State</em>' attribute.
* @see org.eclipse.papyrus.layers.stackmodel.layers.LayerState
* @see #getState()
* @generated
*/
void setState(LayerState value);
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @model dataType="org.eclipse.papyrus.layers.stackmodel.layers.ComputePropertyValueCommand" required="true" ordered="false" exceptions="org.eclipse.papyrus.layers.stackmodel.layers.LayersException" viewRequired="true" viewOrdered="false"
* propertyRequired="true" propertyOrdered="false"
* @generated
*/
ComputePropertyValueCommand getComputePropertyValueCommand(View view, Property property) throws LayersException;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @model dataType="org.eclipse.papyrus.layers.stackmodel.layers.ComputePropertyValueCommand" exceptions="org.eclipse.papyrus.layers.stackmodel.layers.LayersException" viewRequired="true" viewOrdered="false" propertyRequired="true" propertyMany="true"
* @generated
*/
EList<ComputePropertyValueCommand> getPropertiesComputePropertyValueCommand(View view, EList<Property> property) throws LayersException;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @model dataType="org.eclipse.papyrus.layers.stackmodel.layers.ComputePropertyValueCommand" exceptions="org.eclipse.papyrus.layers.stackmodel.layers.LayersException" viewMany="true" propertyRequired="true" propertyOrdered="false"
* @generated
*/
EList<ComputePropertyValueCommand> getViewsComputePropertyValueCommand(EList<View> view, Property property) throws LayersException;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @model
* @generated
*/
void startAfterCreation();
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* Start the LayersStack after a reloading by EMF. This method should be explicitly called after a reloading.
* The method usually start the layer behaviors.
* <!-- end-model-doc -->
*
* @model exceptions="org.eclipse.papyrus.layers.stackmodel.layers.LayersException"
* @generated
*/
void attachLayers() throws LayersException;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* Try to attach this Layer. If successful, the state go to "attached". Otherwise, an exception is thrown.
* A Layer can be attached if its required attributes are set.
* Required attributes:
* <ul>
* <li>application</li>
* <li>owningLayerStack</li>
* <li>parent container</li>
* <li></li>
* </ul>
* Just after enterring in "attached" state, the enterAttachedState() method is called.
* If this Layer is successfully attached, then attach subLayers.
* <!-- end-model-doc -->
*
* @model exceptions="org.eclipse.papyrus.layers.stackmodel.layers.LayersException"
* @generated
*/
void attach() throws LayersException;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* Detach the Layer. The state go to "detached".
* Associated behavior are stopped.
* <!-- end-model-doc -->
*
* @model exceptions="org.eclipse.papyrus.layers.stackmodel.layers.LayersException"
* @generated
*/
void detach() throws LayersException;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* This method is called by the class immediately after entering in attached state.
* The methodcan be used to start the layer behaviors.
* <!-- end-model-doc -->
*
* @model exceptions="org.eclipse.papyrus.layers.stackmodel.layers.LayersException"
* @generated
*/
void enterAttachedState() throws LayersException;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* This method is called just before this Layer leave the attached state.
*
* <!-- end-model-doc -->
*
* @model
* @generated
*/
void exitAttachedState();
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @throws LayersException
* @model dataType="org.eclipse.papyrus.layers.stackmodel.layers.ComputePropertyValueCommand" viewRequired="true" viewOrdered="false" propertyRequired="true" propertyMany="true"
* @generated NOT
*/
EList<ComputePropertyValueCommand> getPropertiesComputePropertyValueCommand(View view, List<Property> property) throws LayersException;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @throws LayersException
* If something wrong happen during computation.
* @model dataType="org.eclipse.papyrus.layers.stackmodel.layers.ComputePropertyValueCommand" viewMany="true" propertyRequired="true" propertyOrdered="false"
* @generated NOT
*/
EList<ComputePropertyValueCommand> getViewsComputePropertyValueCommand(List<View> view, Property property) throws LayersException;
} // LayersStack