public enum RelationType extends java.lang.Enum<RelationType>
EntityTypes that
are defined in [Berr05]. For more information about each relation see
[Berr05].
There's one slight difference thought: The relation type ProjectInvolvement (which was a relation between Project and either OrgPosition or OrgUnit) has been split into the two relation types ProjectInvolvementOrgPosition and ProjectInvolvementOrgUnit. This has been done in order to avoid the use of the discriminant/discrimination which would also appear in the interface and unnecessarily complicate things.
Each RelationType involves two EntityTypes. The first
one (leftHandEntityType()) is always the more general one (e.g.
ROLE_SPECIALISATION), the one that groups/combines the second one
(e.g. ORG_GROUP_INVOLVEMENT and all other 1:n relations) or the one
that is a superior/manager to the second one.
The same order is used in
ModelChangeOperations.addRelation(de.aristaflow.adept2.base.sessionmanagement.SessionToken, RelationType, long, long) and
ModelChangeOperations.deleteRelation(de.aristaflow.adept2.base.sessionmanagement.SessionToken, RelationType, long, long).
See the individual relation types for more information about their kind (1:m or n:m) and the required order.
| Enum Constant and Description |
|---|
AGENT_ABILITY
refers to AgentAbility, an n:m relation type between Agent and Ability
|
ORG_GROUP_INVOLVEMENT
refers to OrgGroupInvolvement, an n:m relation type between OrgGroup and
(the involved) OrgUnit
|
ORG_GROUP_MANAGEMENT
refers to OrgGroupManagement, a 1:m relation type between (the managing)
OrgPosition and OrgGroup; the reference attribute: OrgGroup.managerId
|
ORG_POSITION_AFFILIATION
refers to OrgPositionAffiliation, a 1:m relation type between OrgUnit and
OrgPosition; the reference attribute: OrgPosition.orgUnitId
|
ORG_POSITION_DESCRIPTION
refers to OrgPositionDescription, an n:m relation type between OrgPosition
and Role
|
ORG_POSITION_OCCUPATION
refers to OrgPositionOccupation, an n:m relation type between OrgPosition
and Agent
|
ORG_POSITION_SUBSTITUTE
refers to OrgPositionSubstitute, a 1:m relation type between OrgPosition
(to substitute the other one) and SubstitutionRule; the reference
attribute: SubstitutionRule.substituteId
|
ORG_POSITION_SUBSTITUTION
refers to OrgPositionSubstitution, a 1:m relation type between OrgPosition
and SubstitutionRule; the reference attribute:
SubstitutionRule.orgPositionId
|
ORG_UNIT_MANAGEMENT
refers to OrgUnitManagement, a 1:m relation type between (the managing)
OrgPosition and OrgUnit; the reference attribute: OrgUnit.managerId
|
ORG_UNIT_SUBORDINATION
refers to OrgUnitSubordination, a 1:m relation type between OrgUnit and
(the subordinate) OrgUnit; the reference attribute: OrgUnit.supId
|
PROJECT_GROUP_MANAGEMENT
refers to ProjectGroupManagement, a 1:m relation type between (the
managing) OrgPosition and ProjectGroup; the reference attribute:
ProjectGroup.managerId
|
PROJECT_GROUP_SUBORDINATION
refers to ProjectGroupSubordination, a 1:m relation type between
ProjectGroup and (the subordinate) ProjectGroup; the reference attribute:
ProjectGroup.supId
|
PROJECT_INVOLVEMENT_ORG_POSITION
refers to ProjectInvolvementOrgPosition, an n:m relation type between
ProjectGroup and (the involved) OrgPosition
|
PROJECT_INVOLVEMENT_ORG_UNIT
refers to ProjectInvolvementOrgUnit, an n:m relation type between
ProjectGroup and (the involved) OrgUnit
|
ROLE_DESCRIPTION
refers to RoleDescription, an n:m relation type between Role and Ability
|
ROLE_SPECIALISATION
refers to RoleSpecialisation, a 1:m relation type between (the more
generic) Role and (the specialised) Role; the reference attribute:
Role.supId
|
ROLE_SUBSTITUTION
refers to RoleSubstitution, a 1:m relation type between Role and
SubstitutionRule; the reference attribute: SubstitutionRule.roleId
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
isNMRelation()
Returns whether this is an n:m relation type (and not a 1:m relation type).
|
boolean |
isRecursive()
Returns whether a
RelationType is recursive, i.e. connects
an EntityType with itself. |
EntityType |
leftHandEntityType()
Returns the first (left-hand) entity type in this relation type.
|
java.lang.String |
oneToMReferenceAttribute()
If this is a 1:m relation type, this method will return the attribute name
in the right-hand entity type that references an entity of the left-hand
entity type.
|
EntityType |
rightHandEntityType()
Returns the second (right-hand) entity type in this relation type.
|
static RelationType |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static RelationType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final RelationType ORG_POSITION_OCCUPATION
public static final RelationType ORG_POSITION_DESCRIPTION
public static final RelationType ORG_POSITION_AFFILIATION
public static final RelationType ORG_UNIT_SUBORDINATION
public static final RelationType ORG_UNIT_MANAGEMENT
public static final RelationType ORG_GROUP_MANAGEMENT
public static final RelationType ORG_GROUP_INVOLVEMENT
public static final RelationType PROJECT_GROUP_SUBORDINATION
public static final RelationType PROJECT_GROUP_MANAGEMENT
public static final RelationType PROJECT_INVOLVEMENT_ORG_POSITION
public static final RelationType PROJECT_INVOLVEMENT_ORG_UNIT
public static final RelationType AGENT_ABILITY
public static final RelationType ROLE_DESCRIPTION
public static final RelationType ROLE_SPECIALISATION
public static final RelationType ORG_POSITION_SUBSTITUTION
public static final RelationType ORG_POSITION_SUBSTITUTE
public static final RelationType ROLE_SUBSTITUTION
public static RelationType[] values()
for (RelationType c : RelationType.values()) System.out.println(c);
public static RelationType valueOf(java.lang.String name)
name - the name of the enum constant to be returned.java.lang.IllegalArgumentException - if this enum type has no constant with the specified namejava.lang.NullPointerException - if the argument is nullpublic EntityType leftHandEntityType()
public EntityType rightHandEntityType()
public boolean isNMRelation()
public java.lang.String oneToMReferenceAttribute()
isNMRelation()) this method will throw an
IllegalStateException.public boolean isRecursive()
RelationType is recursive, i.e. connects
an EntityType with itself.RelationType is recursive