com.togethersoft.openapi.model.elements
Interface Link

All Known Subinterfaces:
Entity, Model

public interface Link

This interface groups all link-related functionality and is considered only as part
of Entity interface. In Model only Entity can behave as link.
The link has a number of participants (not neccessarily two), each of them has a role.
One Element cannot participate in the link twice in the same role.

Author:
TogetherSoft

Field Summary
 final static ElementlnkIElement
           

Method Summary
 booleancanSetParticipant(Element participant, String oldRole, String newRole)
           
 booleancanSetParticipant(String role, Element oldParticipant, Element newParticipant)
           
 StringEnumerationparticipantRoles()
          List all roles, participants of this link have.
 ElementEnumerationparticipants(String role)
          List all participants of this link, which has specified role.
 voidsetParticipant(String role, Element oldParticipant, Element newParticipant)
          Changes one of participants to another, keeping role the same.
 voidsetParticipant(Element participant, String oldRole, String newRole)
          Changes role of participant.

Field Detail

lnkIElement

public final static Element lnkIElement
clientCardinality 1
label pariticipants
directed
supplierCardinality 0..*
Method Detail

canSetParticipant

public boolean canSetParticipant(Element participant, String oldRole, String newRole)

canSetParticipant

public boolean canSetParticipant(String role, Element oldParticipant, Element newParticipant)

participantRoles

public StringEnumeration participantRoles()
List all roles, participants of this link have.

participants

public ElementEnumeration participants(String role)
List all participants of this link, which has specified role.

setParticipant

public void setParticipant(String role, Element oldParticipant, Element newParticipant)
Changes one of participants to another, keeping role the same.
When newParticipant is null the operation is equivalent to removing of
oldParticipant from link.
When oldParticipant is null the operation is equivalent to adding
newParticipant to link.

setParticipant

public void setParticipant(Element participant, String oldRole, String newRole)
Changes role of participant.

Association Links

to Class com.togethersoft.openapi.model.elements.Element

Label pariticipants
Client Cardinality 1
Supplier Cardinality 0..*
Is directed