it.polito.elite.ontology
Class NodeTypeAbstraction

java.lang.Object
  extended by it.polito.elite.ontology.NodeTypeAbstraction
Direct Known Subclasses:
NodeTypeOWL

public abstract class NodeTypeAbstraction
extends java.lang.Object


Field Summary
protected  boolean isEnumeration
           
protected  boolean isLogicalClass
           
protected  boolean isRestriction
           
protected  NodeTypesEnum type
           
 
Constructor Summary
NodeTypeAbstraction()
           
 
Method Summary
 boolean equals(NodeTypeAbstraction t)
          Base Comparison
abstract  int getCardinality()
          Retrieves the cardinality of the restriction if type is Cardinality (base, min o max)
abstract  java.util.HashSet<NodeTypeAbstraction> getEnumerationSet()
          Retrieves the set of NodeTypeAbstraction in a OneOf enumeration
abstract  java.util.HashSet<NodeTypeAbstraction> getLogicSet()
          Retrieves the set of NodeTypeAbstraction forming the union logical class or the intersection.
abstract  NodeTypeAbstraction getRestrictionFiller()
          Retrieves the NodeTypeAbstraction filler of the restrictions, if it is a HAS_VALUE or Qualified Cardinality or a SOME / ALL values TO restrictions
abstract  java.lang.String getRestrictionPropertyURI()
          Retrieves the URI of the property restriction is on
 NodeTypesEnum getType()
           
 int hashCode()
           
 boolean isEnumeration()
           
 boolean isLogicalClass()
           
 boolean isRestriction()
           
abstract  java.lang.String toString()
          Represents the node stored in the internal model of the subclass with a textual expression, an example format could be: UnionOf( ConceptA, ComplementOf(ConceptB),..) - OneOf(InstA, InstB) with the pourpose to be displayed on Screen
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

isEnumeration

protected boolean isEnumeration

isLogicalClass

protected boolean isLogicalClass

isRestriction

protected boolean isRestriction

type

protected NodeTypesEnum type
Constructor Detail

NodeTypeAbstraction

public NodeTypeAbstraction()
Method Detail

equals

public boolean equals(NodeTypeAbstraction t)
Base Comparison

Parameters:
t - a NodeTypeAbstraction
Returns:
true if they are equals, false otherwhise. It compares the two textual representations

getCardinality

public abstract int getCardinality()
Retrieves the cardinality of the restriction if type is Cardinality (base, min o max)

Returns:
a int value > 0 or -1 if not a cardinality restriction type

getEnumerationSet

public abstract java.util.HashSet<NodeTypeAbstraction> getEnumerationSet()
Retrieves the set of NodeTypeAbstraction in a OneOf enumeration

Returns:
a set of OneOf, if type is Enumeration, null otherwise

getLogicSet

public abstract java.util.HashSet<NodeTypeAbstraction> getLogicSet()
Retrieves the set of NodeTypeAbstraction forming the union logical class or the intersection. Returns null otherwise

Returns:
a set of NodeTypeAbstraction, if type is Union or Intersection, null otherwise

getRestrictionFiller

public abstract NodeTypeAbstraction getRestrictionFiller()
Retrieves the NodeTypeAbstraction filler of the restrictions, if it is a HAS_VALUE or Qualified Cardinality or a SOME / ALL values TO restrictions

Returns:
a NodeTypeAbstraction, if type is correct type, null otherwise

getRestrictionPropertyURI

public abstract java.lang.String getRestrictionPropertyURI()
Retrieves the URI of the property restriction is on

Returns:
a set of NodeTypeAbstraction, if type is Union or Intersection, null otherwise

getType

public NodeTypesEnum getType()

hashCode

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

isEnumeration

public boolean isEnumeration()

isLogicalClass

public boolean isLogicalClass()

isRestriction

public boolean isRestriction()

toString

public abstract java.lang.String toString()
Represents the node stored in the internal model of the subclass with a textual expression, an example format could be: UnionOf( ConceptA, ComplementOf(ConceptB),..) - OneOf(InstA, InstB) with the pourpose to be displayed on Screen

Overrides:
toString in class java.lang.Object