blob: cebb3db1a8214d96c06d6ea033374ee12c9f1e6b [file] [log] [blame]
/*
* Copyright (c) 2005 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: TemplateableElement.java,v 1.1 2005/11/14 22:26:00 khussey Exp $
*/
package org.eclipse.uml2.uml;
import java.util.List;
import org.eclipse.emf.ecore.EClass;
/**
* <!-- begin-user-doc -->
* A representation of the model object '<em><b>Templateable Element</b></em>'.
* <!-- end-user-doc -->
*
* <!-- begin-model-doc -->
* TemplateableElement may contain a template signature which specifies the formal template parameters. A TemplateableElement that contains a template signature is often referred to as a template. TemplateableElement may contain bindings to templates that describe how the templateable element is constructed by replacing the formal template parameters with actual parameters. A TemplateableElement containing bindings is oftenreferred to as a bound element.
* <!-- end-model-doc -->
*
* <p>
* The following features are supported:
* <ul>
* <li>{@link org.eclipse.uml2.uml.TemplateableElement#getTemplateBindings <em>Template Binding</em>}</li>
* <li>{@link org.eclipse.uml2.uml.TemplateableElement#getOwnedTemplateSignature <em>Owned Template Signature</em>}</li>
* </ul>
* </p>
*
* @see org.eclipse.uml2.uml.UMLPackage#getTemplateableElement()
* @model abstract="true"
* @generated
*/
public interface TemplateableElement
extends Element {
/**
* Returns the value of the '<em><b>Template Binding</b></em>' containment reference list.
* The list contents are of type {@link org.eclipse.uml2.uml.TemplateBinding}.
* It is bidirectional and its opposite is '{@link org.eclipse.uml2.uml.TemplateBinding#getBoundElement <em>Bound Element</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* The optional bindings from this element to templates.
* <!-- end-model-doc -->
* @return the value of the '<em>Template Binding</em>' containment reference list.
* @see org.eclipse.uml2.uml.UMLPackage#getTemplateableElement_TemplateBinding()
* @see org.eclipse.uml2.uml.TemplateBinding#getBoundElement
* @model type="org.eclipse.uml2.uml.TemplateBinding" opposite="boundElement" containment="true" resolveProxies="false" ordered="false"
* @generated
*/
List getTemplateBindings();
/**
* Creates a {@link org.eclipse.uml2.uml.TemplateBinding} and appends it to the '<em><b>Template Binding</b></em>' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return The new {@link org.eclipse.uml2.uml.TemplateBinding}.
* @see #getTemplateBindings()
* @generated
*/
TemplateBinding createTemplateBinding();
/**
* Returns the value of the '<em><b>Owned Template Signature</b></em>' containment reference.
* It is bidirectional and its opposite is '{@link org.eclipse.uml2.uml.TemplateSignature#getTemplate <em>Template</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* The optional template signature specifying the formal template parameters.
* <!-- end-model-doc -->
* @return the value of the '<em>Owned Template Signature</em>' containment reference.
* @see #setOwnedTemplateSignature(TemplateSignature)
* @see org.eclipse.uml2.uml.UMLPackage#getTemplateableElement_OwnedTemplateSignature()
* @see org.eclipse.uml2.uml.TemplateSignature#getTemplate
* @model opposite="template" containment="true" resolveProxies="false" ordered="false"
* @generated
*/
TemplateSignature getOwnedTemplateSignature();
/**
* Sets the value of the '{@link org.eclipse.uml2.uml.TemplateableElement#getOwnedTemplateSignature <em>Owned Template Signature</em>}' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @param value the new value of the '<em>Owned Template Signature</em>' containment reference.
* @see #getOwnedTemplateSignature()
* @generated
*/
void setOwnedTemplateSignature(TemplateSignature value);
/**
* Creates a {@link org.eclipse.uml2.uml.TemplateSignature} and sets the '<em><b>Owned Template Signature</b></em>' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @param eClass The Ecore class of the {@link org.eclipse.uml2.uml.TemplateSignature} to create.
* @return The new {@link org.eclipse.uml2.uml.TemplateSignature}.
* @see #getOwnedTemplateSignature()
* @generated
*/
TemplateSignature createOwnedTemplateSignature(EClass eClass);
/**
* Creates a {@link org.eclipse.uml2.uml.TemplateSignature} and sets the '<em><b>Owned Template Signature</b></em>' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return The new {@link org.eclipse.uml2.uml.TemplateSignature}.
* @see #getOwnedTemplateSignature()
* @generated
*/
TemplateSignature createOwnedTemplateSignature();
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* The query parameterableElements() returns the set of elements that may be used as the parametered elements for a template parameter of this templateable element. By default, this set includes all the owned elements. Subclasses may override this operation if they choose to restrict the set of parameterable elements.
* result = allOwnedElements->select(oclIsKindOf(ParameterableElement))
* <!-- end-model-doc -->
* @model type="org.eclipse.uml2.uml.ParameterableElement" ordered="false"
* annotation="http://www.eclipse.org/emf/2002/Ecore constraints='spec'"
* @generated
*/
List parameterableElements();
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
* The query isTemplate() returns whether this templateable element is actually a template.
* result = ownedSignature->notEmpty()
* <!-- end-model-doc -->
* @model kind="operation" required="true" ordered="false"
* annotation="http://www.eclipse.org/emf/2002/Ecore constraints='spec'"
* @generated
*/
boolean isTemplate();
} // TemplateableElement