gate.creole.ontology
Interface OClass

All Superinterfaces:
OConstants, OResource
All Known Subinterfaces:
AllValuesFromRestriction, AnonymousClass, CardinalityRestriction, HasValueRestriction, MaxCardinalityRestriction, MinCardinalityRestriction, Restriction, SomeValuesFromRestriction

public interface OClass
extends OResource, OConstants

Each OClass (Ontology Class) represents a concept/class in ontology. It provides various methods (including and not limited) to iterate through its super and sub classes in the taxonomy hierarchy.

Author:
Niraj Aswani, Johann Petrak

Nested Class Summary
 
Nested classes/interfaces inherited from interface gate.creole.ontology.OConstants
OConstants.Closure, OConstants.OntologyFormat, OConstants.OWL, OConstants.QueryLanguage, OConstants.RDF, OConstants.RDFS, OConstants.XMLSchema
 
Field Summary
 
Fields inherited from interface gate.creole.ontology.OConstants
ABKHAZIAN, AFAR, AFRIKAANS, ALBANIAN, ALL_VALUES_FROM_RESTRICTION, ALL_VALUES_FROM_RESTRICTION_ADDED_EVENT, AMHARIC, ANNONYMOUS_CLASS, ANNOTATION_PROPERTY, ANNOTATION_PROPERTY_ADDED_EVENT, ANNOTATION_PROPERTY_VALUE_ADDED_EVENT, ANNOTATION_PROPERTY_VALUE_REMOVED_EVENT, ANONYMOUS_CLASS_ADDED_EVENT, ANONYMOUS_CLASS_NAME, ARABIC, ARMENIAN, ASSAMESE, AYMARA, AZERBAIJANI, BASHKIR, BASQUE, BENGALI, BHUTANI, BIHARI, BISLAMA, BRETON, BULGARIAN, BURMESE, BYELORUSSIAN, CAMBODIAN, CARDINALITY_RESTRICTION, CARDINALITY_RESTRICTION_ADDED_EVENT, CATALAN, CHINESE, CORSICAN, CROATIAN, CZECH, DANISH, DATATYPE_PROPERTY, DATATYPE_PROPERTY_ADDED_EVENT, DATATYPE_PROPERTY_VALUE_ADDED_EVENT, DATATYPE_PROPERTY_VALUE_REMOVED_EVENT, DIFFERENT_INSTANCE_EVENT, DIRECT_CLOSURE, DUTCH, ENGLISH, EQUIVALENT_CLASS_EVENT, EQUIVALENT_PROPERTY_EVENT, ESPERANTO, ESTONIAN, FAROESE, FIJI, FINNISH, FRENCH, FRISIAN, GALICIAN, GEORGIAN, GERMAN, GREEK, GREENLANDIC, GUARANI, GUJARATI, HAS_VALUE_RESTRICTION, HAS_VALUE_RESTRICTION_ADDED_EVENT, HAUSA, HEBREW, HINDI, HUNGARIAN, ICELANDIC, INDONESIAN, INSTANCE, INTERLINGUA, INTERLINGUE, INUKTITUT, INUPIAK, IRISH, ITALIAN, JAPANESE, JAVANESE, KANNADA, KASHMIRI, KAZAKH, KINYARWANDA, KIRGHIZ, KIRUNDI, KOREAN, KURDISH, LAOTHIAN, LATIN, LATVIAN, LINGALA, LITHUANIAN, MACEDONIAN, MALAGASY, MALAY, MALAYALAM, MALTESE, MAORI, MARATHI, MAX_CARDINALITY_RESTRICTION, MAX_CARDINALITY_RESTRICTION_ADDED_EVENT, MIN_CARDINALITY_RESTRICTION, MIN_CARDINALITY_RESTRICTION_ADDED_EVENT, MOLDAVIAN, MONGOLIAN, NAURU, NEPALI, NORWEGIAN, OBJECT_PROPERTY, OBJECT_PROPERTY_ADDED_EVENT, OBJECT_PROPERTY_VALUE_ADDED_EVENT, OBJECT_PROPERTY_VALUE_REMOVED_EVENT, OCCITAN, OCLASS_ADDED_EVENT, OINSTANCE_ADDED_EVENT, ONTOLOGY_DEFAULT_BASE_URI, ONTOLOGY_EVENT_LOG_FEATURE_NAME, ONTOLOGY_FORMAT_N3, ONTOLOGY_FORMAT_NTRIPLES, ONTOLOGY_FORMAT_RDFXML, ONTOLOGY_FORMAT_TURTLE, ORIYA, OROMO, OWL_CLASS, PASHTO, PERSIAN, POLISH, PORTUGUESE, PUNJABI, QUECHUA, RDF_PROPERTY, RDF_PROPERTY_VALUE_ADDED_EVENT, RDF_PROPERTY_VALUE_REMOVED_EVENT, RESOURCE_REMOVED_EVENT, RESTRICTION_ON_PROPERTY_VALUE_CHANGED, RHAETO_ROMANCE, ROMANIAN, RUSSIAN, SAME_INSTANCE_EVENT, SAMOAN, SANGHO, SANSKRIT, SCOTS, SERBIAN, SERBO_CROATIAN, SESOTHO, SETSWANA, SHONA, SINDHI, SINHALESE, SISWATI, SLOVAK, SLOVENIAN, SOMALI, SOME_VALUES_FROM_RESTRICTION, SOME_VALUES_FROM_RESTRICTION_ADDED_EVENT, SPANISH, SUB_CLASS_ADDED_EVENT, SUB_CLASS_REMOVED_EVENT, SUB_PROPERTY_ADDED_EVENT, SUB_PROPERTY_REMOVED_EVENT, SUNDANESE, SWAHILI, SWEDISH, SYMMETRIC_PROPERTY, SYMMETRIC_PROPERTY_ADDED_EVENT, TAGALOG, TAJIK, TAMIL, TATAR, TELUGU, THAI, TIBETAN, TIGRINYA, TONGA, TRANSITIVE_CLOSURE, TRANSITIVE_PROPERTY, TRANSTIVE_PROPERTY_ADDED_EVENT, TSONGA, TURKISH, TURKMEN, TWI, UIGHUR, UKRAINIAN, URDU, UZBEK, VIETNAMESE, VOLAPUK, WELSH, WOLOF, XHOSA, YIDDISH, YORUBA, ZHUANG, ZULU
 
Method Summary
 void addSubClass(OClass subClass)
          Adds a sub class to this class.
 Set<OClass> getEquivalentClasses()
          Returns a set of all classes that are equivalent as this one.
 Set<OClass> getSubClasses(byte closure)
          Deprecated. 
 Set<OClass> getSubClasses(OConstants.Closure closure)
           
 ClosableIterator<OClass> getSubClassesIterator(OConstants.Closure closure)
           
 ArrayList<Set<OClass>> getSubClassesVsDistance()
          Gets the sub classes, and returns them in an array list where on each index there is a collection of the sub classes at distance - the index.
 Set<OClass> getSuperClasses(byte closure)
          Deprecated. 
 Set<OClass> getSuperClasses(OConstants.Closure closure)
           
 ArrayList<Set<OClass>> getSuperClassesVSDistance()
          Gets the super classes, and returns them in an array list where on each index there is a collection of the super classes at distance - the index.
 boolean isEquivalentClassAs(OClass aClass)
          Checks whether the class is equivalent as the given class.
 boolean isSubClassOf(OClass aClass, byte closure)
          Deprecated. 
 boolean isSubClassOf(OClass aClass, OConstants.Closure closure)
           
 boolean isSuperClassOf(OClass aClass, byte closure)
          Checks whether the class is a super class of the given class.
 boolean isSuperClassOf(OClass aClass, OConstants.Closure closure)
           
 boolean isTopClass()
          Checks whether this class is a top.
 void removeSubClass(OClass subClass)
          Removes a sub class.
 void setEquivalentClassAs(OClass theClass)
          Indicates that these classes are the equivalent
 
Methods inherited from interface gate.creole.ontology.OResource
addAnnotationPropertyValue, getAllSetProperties, getAnnotationPropertyValues, getComment, getComments, getLabel, getLabels, getName, getONodeID, getOntology, getPropertiesWithResourceAsDomain, getPropertiesWithResourceAsRange, getSetAnnotationProperties, getURI, hasAnnotationPropertyWithValue, removeAnnotationPropertyValue, removeAnnotationPropertyValues, setComment, setLabel, setURI
 

Method Detail

addSubClass

void addSubClass(OClass subClass)
Adds a sub class to this class.

Parameters:
subClass - the subClass to be added.

removeSubClass

void removeSubClass(OClass subClass)
Removes a sub class.

Parameters:
subClass - the sub class to be removed

getSubClasses

@Deprecated
Set<OClass> getSubClasses(byte closure)
Deprecated. 

Gets the subclasses according to the desired closure.

Parameters:
closure - either DIRECT_CLOSURE or TRASITIVE_CLOSURE
Returns:
the set of subclasses

getSubClasses

Set<OClass> getSubClasses(OConstants.Closure closure)

getSubClassesIterator

ClosableIterator<OClass> getSubClassesIterator(OConstants.Closure closure)

getSuperClasses

@Deprecated
Set<OClass> getSuperClasses(byte closure)
Deprecated. 

Gets the super classes according to the desired closure.

Parameters:
closure - either DIRECT_CLOSURE or TRASITIVE_CLOSURE
Returns:
the set of super classes

getSuperClasses

Set<OClass> getSuperClasses(OConstants.Closure closure)

isSuperClassOf

boolean isSuperClassOf(OClass aClass,
                       byte closure)
Checks whether the class is a super class of the given class.

Parameters:
aClass -
closure - either OntologyConstants.DIRECT_CLOSURE or OntologyConstants.TRANSITIVE_CLOSURE
Returns:
true, if the class is a super class of the given class, otherwise - false.

isSuperClassOf

boolean isSuperClassOf(OClass aClass,
                       OConstants.Closure closure)

isSubClassOf

@Deprecated
boolean isSubClassOf(OClass aClass,
                                byte closure)
Deprecated. 

Checks whether the class is a sub class of the given class.

Parameters:
aClass -
closure - either OntologyConstants.DIRECT_CLOSURE or OntologyConstants.TRANSITIVE_CLOSURE
Returns:
true, if the class is a sub class of the given class, otherwise - false.

isSubClassOf

boolean isSubClassOf(OClass aClass,
                     OConstants.Closure closure)

isTopClass

boolean isTopClass()
Checks whether this class is a top.

Returns:
true if this is a top class, otherwise - false.

setEquivalentClassAs

void setEquivalentClassAs(OClass theClass)
Indicates that these classes are the equivalent


getEquivalentClasses

Set<OClass> getEquivalentClasses()
Returns a set of all classes that are equivalent as this one. Null if no such classes.


isEquivalentClassAs

boolean isEquivalentClassAs(OClass aClass)
Checks whether the class is equivalent as the given class.

Parameters:
aClass -
Returns:
true, if the class is equivalent as the aClass, otherwise - false.

getSuperClassesVSDistance

ArrayList<Set<OClass>> getSuperClassesVSDistance()
Gets the super classes, and returns them in an array list where on each index there is a collection of the super classes at distance - the index.


getSubClassesVsDistance

ArrayList<Set<OClass>> getSubClassesVsDistance()
Gets the sub classes, and returns them in an array list where on each index there is a collection of the sub classes at distance - the index.