be.ac.vub.cocompose.lang.core
Interface Role

All Superinterfaces:
Cloneable, Element, ModelElement, Namespace, RefinedElement, RelationElement, VisitedElement
All Known Implementing Classes:
DefaultRole

public interface Role
extends RefinedElement

The Solution Role language element interface.

Since:
0.1.0
Version:
0.2.7, 16/04/2004
Author:
Dennis Wagelaar

Method Summary
 void addPart(Concept concept)
          Adds a concept to the role part.
 void addPart(int index, Concept concept)
          Adds a concept to the role part.
 Multiplicity getMultiplicity()
          Returns the multiplicity constraint for this solution role.
 List getParts()
          Returns the concepts that belong to this role part.
 void removePart(Concept concept)
          Removes a concept from the role part.
 void setMultiplicity(Multiplicity multiplicity)
          Sets the multiplicity constraint for this solution role.
 
Methods inherited from interface be.ac.vub.cocompose.lang.core.RefinedElement
addInheritsFrom, addInheritsFrom, addSuperimposesOn, addSuperimposesOn, getIconUri, getInheritsFrom, getRefinements, getSuperimposesOn, removeInheritsFrom, removeSuperimposesOn, setIconUri
 
Methods inherited from interface be.ac.vub.cocompose.lang.core.RelationElement
addRelationship, addRelationship, getBackgroundColor, getPosition, getRelationships, getSourceRelationships, getTargetRelationships, removeRelationship, setBackgroundColor, setPosition
 
Methods inherited from interface be.ac.vub.cocompose.lang.core.Namespace
addOwnedElement, addOwnedElement, getDeepOwnedElements, getOwnedElement, getOwnedElementId, getOwnedElements, getOwnedElements, isRegistered, registerNameChange, removeOwnedElement
 
Methods inherited from interface be.ac.vub.cocompose.lang.core.ModelElement
getId, getModel, getName, getNamespace, setId, setName, setNamespace
 
Methods inherited from interface be.ac.vub.cocompose.lang.Element
addPropertyChangeListener, removePropertyChangeListener
 
Methods inherited from interface be.ac.vub.cocompose.lang.VisitedElement
accept
 

Method Detail

getParts

public List getParts()
Returns the concepts that belong to this role part.

Returns:
the list of concepts.

addPart

public void addPart(Concept concept)
Adds a concept to the role part.

Parameters:
concept - - the concept to add.

addPart

public void addPart(int index,
                    Concept concept)
Adds a concept to the role part.

Parameters:
index - the index at which to add the element.
concept - - the concept to add.

removePart

public void removePart(Concept concept)
Removes a concept from the role part.

Parameters:
concept - - the concept to remove.

getMultiplicity

public Multiplicity getMultiplicity()
Returns the multiplicity constraint for this solution role.

Returns:
the multiplicity constraint.

setMultiplicity

public void setMultiplicity(Multiplicity multiplicity)
Sets the multiplicity constraint for this solution role.

Parameters:
multiplicity - the multiplicity constraint.