de.unima.alcomox.mapping
Class SemanticRelation

java.lang.Object
  extended by de.unima.alcomox.mapping.SemanticRelation

public class SemanticRelation
extends java.lang.Object

A semantic relation can be used to express equivalence, subsumption or disjointness between entities of different ontologies.


Field Summary
static int DIS
          Relation of disjointness, e.g.
static int EQUIV
          Relation of equivalence, e.g.
static int NA
          Relation thats not available.
static int SUB
          Relation of subsumption, e.g.
static int SUPER
          Relation of supsumption, e.g.
 
Constructor Summary
SemanticRelation(int type)
          Constructs a semantic relation of a certain type.
 
Method Summary
 boolean equals(java.lang.Object that)
          Checks equality of this and that semantic relation.
 SemanticRelation getInverse()
          Returns the inverse semantic relation of this semantic relation.
 int getType()
           
 int hashCode()
           
 java.lang.String toString()
          Returns the string representation of this semantic relation.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

NA

public static final int NA
Relation thats not available.

See Also:
Constant Field Values

EQUIV

public static final int EQUIV
Relation of equivalence, e.g. A = B.

See Also:
Constant Field Values

SUB

public static final int SUB
Relation of subsumption, e.g. A < B.

See Also:
Constant Field Values

SUPER

public static final int SUPER
Relation of supsumption, e.g. A > B.

See Also:
Constant Field Values

DIS

public static final int DIS
Relation of disjointness, e.g. A != B.

See Also:
Constant Field Values
Constructor Detail

SemanticRelation

public SemanticRelation(int type)
                 throws CorrespondenceException
Constructs a semantic relation of a certain type.

Parameters:
type - The type of the semantic relation.
Throws:
CorrespondenceException - Thrown, if a not existing type of relation is chosen.
Method Detail

getType

public int getType()
Returns:
The type of this semantic relation.

toString

public java.lang.String toString()
Returns the string representation of this semantic relation.

Overrides:
toString in class java.lang.Object
Returns:
Representation as string.

equals

public boolean equals(java.lang.Object that)
Checks equality of this and that semantic relation.

Overrides:
equals in class java.lang.Object
Parameters:
that - That semantic relation.
Returns:
True, if this and that are of the same type.

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

getInverse

public SemanticRelation getInverse()
Returns the inverse semantic relation of this semantic relation.

Returns:
The inverted semantic relation