org.openehr.rm.common.archetyped
Class Link

java.lang.Object
  extended by org.openehr.rm.RMObject
      extended by org.openehr.rm.common.archetyped.Link
All Implemented Interfaces:
java.io.Serializable

public final class Link
extends RMObject

The Link type defines a logical relationship between two items, such as two ENTRYs or an ENTRY and a COMPOSITION. Links can be used across compositions, and across EHRs. Links can potentially be used between interior (ie non archetype root) nodes, although this probably should be prevented in archetypes. Multiple LINKs can be attached to the root object of any archetyped structure to give the effect of a 1->N link. Instances of this class are immutable

Version:
1.0
Author:
Rong Chen
See Also:
Serialized Form

Constructor Summary
Link(DvText meaning, DvText type, DvEHRURI target)
          Constructs a Link by meaning, type and target
 
Method Summary
 boolean equals(java.lang.Object o)
          Two links equal if both have same values for meaning, type and target
 DvText getMeaning()
          Used to describe the relationship, usually in clinical terms, such as in response to (the relationship between test results and an order), follow-up to and so on.
 DvEHRURI getTarget()
          the logical "to" object in the link relation, as per the linguistic sense of the meaning attribute.
 DvText getType()
          The type attribute is used to indicate a clinical or domain-level meaning for the kind of link, for example "problem" or "issue".
 int hashCode()
          Return a hash code of this link
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Link

public Link(DvText meaning,
            DvText type,
            DvEHRURI target)
Constructs a Link by meaning, type and target

Parameters:
meaning - not null
type - not null
target - not null
Throws:
java.lang.IllegalArgumentException - if any null argument
Method Detail

getMeaning

public DvText getMeaning()
Used to describe the relationship, usually in clinical terms, such as in response to (the relationship between test results and an order), follow-up to and so on. Such relationships can represent any clinically meaningful connection between pieces of information.

Returns:
meaning

getType

public DvText getType()
The type attribute is used to indicate a clinical or domain-level meaning for the kind of link, for example "problem" or "issue". If type values are designed appropriately, they can be used by the requestor of EHR extracts to categorise links which must be followed and which can be broken when the extract is created.

Returns:
type

getTarget

public DvEHRURI getTarget()
the logical "to" object in the link relation, as per the linguistic sense of the meaning attribute.

Returns:
target

equals

public boolean equals(java.lang.Object o)
Two links equal if both have same values for meaning, type and target

Overrides:
equals in class java.lang.Object
Parameters:
o -
Returns:
true if equals

hashCode

public int hashCode()
Return a hash code of this link

Overrides:
hashCode in class java.lang.Object
Returns:
hash code


Copyright © 2004-2005 Acode HB. All Rights Reserved.