com.apelon.dts.client.attribute
Class DTSRoleType

java.lang.Object
  extended by com.apelon.dts.client.common.DTSObject
      extended by com.apelon.dts.client.attribute.DTSRoleType
All Implemented Interfaces:
Cloneable

public class DTSRoleType
extends DTSObject

In an Ontylog namespace a role is an association between kinds. Before a role is used within a concept, the role's type (that is, definition) must be defined to specify the domain and range for the role. The role definition's domain must agree with the kind of the concept. The role type consists of the name of the role, as well as the role code and ID.

Copyright: Copyright (c) 2007

Company: Apelon, Inc.

Since:
DTS 3.0.0
Version:
DTS 3.4.1
Author:
Apelon, Inc.
See Also:
DTSRole

Constructor Summary
DTSRoleType(String name, int id, String code, int namespaceId)
          Deprecated. Use DTSRoleType(String name, int id, String code, int namespaceId, Kind domainKind, Kind rangeKind) instead.
DTSRoleType(String name, int id, String code, int namespaceId, Kind domainKind, Kind rangeKind)
          Constructs a new DTSRoleType that includes domain and range Kind information.
 
Method Summary
 Kind getDomainKind()
          Gets the Kind of the domain concept (to which the role is attached).
 DTSRoleType getParentRoleType()
          Gets the parent DTSRoleType for this DTSRoleType
 Kind getRangeKind()
          Gets the Kind of the range concept (the role value concept).
 DTSRoleType getRightIdentity()
          Gets the DTSRoleType that when composed with this one, creates the identical role type.
 void setDomainKind(Kind domainKind)
          Sets the Kind of the domain concept (to which the role is attached).
 void setParentRoleType(DTSRoleType parentRoleType)
          Sets the DTSRoleType as parent DTSRoleType
 void setRangeKind(Kind rangeKind)
          Sets the Kind of the range concept (the role value concept).
 void setRightIdentity(DTSRoleType rightIdentity)
          Sets the DTSRoleType that when composed with this one, creates the identical role type.
 
Methods inherited from class com.apelon.dts.client.common.DTSObject
equals, getCode, getId, getName, getNamespaceId, hashCode, setCode, setId, setName, setNamespaceId, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DTSRoleType

public DTSRoleType(String name,
                   int id,
                   String code,
                   int namespaceId)
Deprecated. Use DTSRoleType(String name, int id, String code, int namespaceId, Kind domainKind, Kind rangeKind) instead.

Constructs a new DTSRoleType for Ontylog concepts.

Parameters:
name - the role's name
id - the role's ID
code - the role's code
namespaceId - the ID of the role type's namespace

DTSRoleType

public DTSRoleType(String name,
                   int id,
                   String code,
                   int namespaceId,
                   Kind domainKind,
                   Kind rangeKind)
Constructs a new DTSRoleType that includes domain and range Kind information. When a DTSRole is created the Ontylog concept to which it is attached must be of the domain Kind and the role value must be an Ontylog concept of the range Kind.

Parameters:
name - the role's name
id - the role's ID
code - the role's code
namespaceId - the ID of the role type's namespace
domainKind - the Kind of the concept to which the role is attached
rangeKind - the Kind of role value concept
Since:
DTS 3.3.0
Method Detail

getDomainKind

public Kind getDomainKind()
Gets the Kind of the domain concept (to which the role is attached).

Returns:
the Kind of the domain concept.
Since:
DTS 3.3.0

setDomainKind

public void setDomainKind(Kind domainKind)
Sets the Kind of the domain concept (to which the role is attached).

Parameters:
domainKind - the Kind of the domain concept.
Since:
DTS 3.3.0

getRangeKind

public Kind getRangeKind()
Gets the Kind of the range concept (the role value concept).

Returns:
the Kind of the domain concept.
Since:
DTS 3.3.0

setRangeKind

public void setRangeKind(Kind rangeKind)
Sets the Kind of the range concept (the role value concept).

Parameters:
rangeKind - the Kind of the range concept.
Since:
DTS 3.3.0

getRightIdentity

public DTSRoleType getRightIdentity()
Gets the DTSRoleType that when composed with this one, creates the identical role type. For example,
  located_in *composed_with* part_of == located_in
 

Returns:
the right identity DTSRoleType, if one exists; otherwise null.
Since:
DTS 3.3.0

setRightIdentity

public void setRightIdentity(DTSRoleType rightIdentity)
Sets the DTSRoleType that when composed with this one, creates the identical role type. For example,
  located_in *composed_with* part_of == located_in
 

Parameters:
rightIdentity - the right identity DTSRoleType
Since:
DTS 3.3.0

getParentRoleType

public DTSRoleType getParentRoleType()
Gets the parent DTSRoleType for this DTSRoleType

Returns:
the parent DTSRoleType, if one exists; otherwise null.
Since:
DTS 3.3.0

setParentRoleType

public void setParentRoleType(DTSRoleType parentRoleType)
Sets the DTSRoleType as parent DTSRoleType

Parameters:
parentRoleType - the parent DTSRoleType
Since:
DTS 3.3.0


Copyright © 2011. All Rights Reserved.