blob: d53238907efae45f4976c832824167de86ee0097 [file] [log] [blame]
/*
* Copyright (c) 2005, 2006 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* IBM - initial API and implementation
*
* $Id: StructuralFeatureAction.java,v 1.6 2006/05/26 16:34:03 khussey Exp $
*/
package org.eclipse.uml2.uml;
import java.util.Map;
import org.eclipse.emf.common.util.DiagnosticChain;
import org.eclipse.emf.ecore.EClass;
/**
* <!-- begin-user-doc -->
* A representation of the model object '<em><b>Structural Feature Action</b></em>'.
* <!-- end-user-doc -->
*
* <!-- begin-model-doc -->
* StructuralFeatureAction is an abstract class for all structural feature actions.
* <!-- end-model-doc -->
*
* <p>
* The following features are supported:
* <ul>
* <li>{@link org.eclipse.uml2.uml.StructuralFeatureAction#getStructuralFeature <em>Structural Feature</em>}</li>
* <li>{@link org.eclipse.uml2.uml.StructuralFeatureAction#getObject <em>Object</em>}</li>
* </ul>
* </p>
*
* @see org.eclipse.uml2.uml.UMLPackage#getStructuralFeatureAction()
* @model abstract="true"
* @generated
*/
public interface StructuralFeatureAction
extends Action {
/**
* Returns the value of the '<em><b>Structural Feature</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* Structural feature to be read.
* <!-- end-model-doc -->
* @return the value of the '<em>Structural Feature</em>' reference.
* @see #setStructuralFeature(StructuralFeature)
* @see org.eclipse.uml2.uml.UMLPackage#getStructuralFeatureAction_StructuralFeature()
* @model required="true" ordered="false"
* @generated
*/
StructuralFeature getStructuralFeature();
/**
* Sets the value of the '{@link org.eclipse.uml2.uml.StructuralFeatureAction#getStructuralFeature <em>Structural Feature</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @param value the new value of the '<em>Structural Feature</em>' reference.
* @see #getStructuralFeature()
* @generated
*/
void setStructuralFeature(StructuralFeature value);
/**
* Returns the value of the '<em><b>Object</b></em>' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* Gives the input pin from which the object whose structural feature is to be read or written is obtained.
*
* <!-- end-model-doc -->
* @return the value of the '<em>Object</em>' containment reference.
* @see #setObject(InputPin)
* @see org.eclipse.uml2.uml.UMLPackage#getStructuralFeatureAction_Object()
* @model containment="true" resolveProxies="true" required="true" ordered="false"
* @generated
*/
InputPin getObject();
/**
* Sets the value of the '{@link org.eclipse.uml2.uml.StructuralFeatureAction#getObject <em>Object</em>}' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @param value the new value of the '<em>Object</em>' containment reference.
* @see #getObject()
* @generated
*/
void setObject(InputPin value);
/**
* Creates a new {@link org.eclipse.uml2.uml.InputPin}, with the specified '<em><b>Name</b></em>', and '<em><b>Type</b></em>', and sets the '<em><b>Object</b></em>' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @param name The '<em><b>Name</b></em>' for the new {@link org.eclipse.uml2.uml.InputPin}, or <code>null</code>.
* @param type The '<em><b>Type</b></em>' for the new {@link org.eclipse.uml2.uml.InputPin}, or <code>null</code>.
* @param eClass The Ecore class of the {@link org.eclipse.uml2.uml.InputPin} to create.
* @return The new {@link org.eclipse.uml2.uml.InputPin}.
* @see #getObject()
* @generated
*/
InputPin createObject(String name, Type type, EClass eClass);
/**
* Creates a new {@link org.eclipse.uml2.uml.InputPin},with the specified '<em><b>Name</b></em>', and '<em><b>Type</b></em>', and sets the '<em><b>Object</b></em>' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @param name The '<em><b>Name</b></em>' for the new {@link org.eclipse.uml2.uml.InputPin}, or <code>null</code>.
* @param type The '<em><b>Type</b></em>' for the new {@link org.eclipse.uml2.uml.InputPin}, or <code>null</code>.
* @return The new {@link org.eclipse.uml2.uml.InputPin}.
* @see #getObject()
* @generated
*/
InputPin createObject(String name, Type type);
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* The structural feature must not be static.
* self.structuralFeature.isStatic = #false
* <!-- end-model-doc -->
* @model
* @generated
*/
boolean validateNotStatic(DiagnosticChain diagnostics, Map context);
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* The type of the object input pin is the same as the classifier of the object passed on this pin.
* true
* <!-- end-model-doc -->
* @model
* @generated
*/
boolean validateSameType(DiagnosticChain diagnostics, Map context);
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* The multiplicity of the input pin must be 1..1.
* self.object.multiplicity.is(1,1)
* <!-- end-model-doc -->
* @model
* @generated
*/
boolean validateMultiplicity(DiagnosticChain diagnostics, Map context);
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* Visibility of structural feature must allow access to the object performing the action.
* let host : Classifier = self.context in
* self.structuralFeature.visibility = #public
* or host = self.structuralFeature.featuringClassifier.type
* or (self.structuralFeature.visibility = #protected and host.allSupertypes
* ->includes(self.structuralFeature.featuringClassifier.type)))
*
* <!-- end-model-doc -->
* @model
* @generated
*/
boolean validateVisibility(DiagnosticChain diagnostics, Map context);
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* A structural feature has exactly one featuringClassifier.
* self.structuralFeature.featuringClassifier->size() = 1
* <!-- end-model-doc -->
* @model
* @generated
*/
boolean validateOneFeaturingClassifier(DiagnosticChain diagnostics,
Map context);
} // StructuralFeatureAction