info.sswap.api.model
Interface SSWAPType

All Superinterfaces:
SSWAPElement, SSWAPModel
All Known Implementing Classes:
TypeImpl

public interface SSWAPType
extends SSWAPElement

Represents a type of an individual in SSWAP.

Author:
Blazej Bulka

Method Summary
 void addAnnotationPredicate(SSWAPPredicate predicate, SSWAPElement value)
          Annotates a type with the given annotation predicate.
 void addDisjointUnionOf(java.util.Collection<SSWAPType> disjointClasses)
          Adds an owl:disjointUnionOf axiom to this type
 void addDisjointWith(SSWAPType type)
          Adds an owl:disjointWith axiom to this type.
 void addEquivalentClass(SSWAPType type)
          Adds an owl:equivalentClass axiom to this type.
 void addIntersectionOf(java.util.Collection<SSWAPType> classes)
          Adds an owl:intersectionOf axiom to this type.
 void addOneOf(java.util.Collection<java.net.URI> oneOf)
          Adds an owl:oneOf axiom to this type
 void addRestrictionAllValuesFrom(SSWAPPredicate predicate, SSWAPType type)
          Adds an owl:allValuesFrom restriction to this type on the specified predicate
 void addRestrictionCardinality(SSWAPPredicate predicate, int cardinality)
          Adds a cardinality restriction to this type on the specified predicate.
 void addRestrictionHasSelf(SSWAPPredicate predicate, boolean value)
          Adds an owl:hasSelf restriction to this type on the specified predicate
 void addRestrictionHasValue(SSWAPPredicate predicate, SSWAPElement element)
          Adds an owl:hasValue restriction to this type on the specified predicate
 void addRestrictionMaxCardinality(SSWAPPredicate predicate, int maxCardinality)
          Adds a max cardinality restriction to this type on the specified predicate.
 void addRestrictionMinCardinality(SSWAPPredicate predicate, int minCardinality)
          Adds a min cardinality restriction to this type on the specified predicate.
 void addRestrictionSomeValuesFrom(SSWAPPredicate predicate, SSWAPType type)
          Adds an owl:someValuesFrom restriction to this type on the specified predicate
 void addSubClassOf(SSWAPType type)
          Adds an rdfs:subClassOf axiom to this type.
 void addUnionOf(java.util.Collection<SSWAPType> classes)
          Adds an owl:unionOf axiom to this type
 SSWAPType complementOf()
          Creates the complement of the current type.
 SSWAPType intersectionOf(SSWAPType a)
          Creates and returns a new type that is an intersection of this type and the given type.
 boolean isNothing()
          Checks whether this type is unsatisfiable (i.e., whether it is a sub type of owl:Nothing).
 boolean isReserved()
          Checks whether the given type belongs to restricted vocabulary (e.g., types defined in RDF, RDFS, OWL or SSWAP namespaces).
 boolean isStrictSubTypeOf(SSWAPType superType)
          Checks whether this type is a strict subtype of the other.
 boolean isSubTypeOf(SSWAPType superType)
          Checks whether this type is a subtype of the other.
 SSWAPType unionOf(SSWAPType a)
          Creates and returns a new type that is a union of this type and the given type.
 
Methods inherited from interface info.sswap.api.model.SSWAPElement
addComment, addLabel, asBoolean, asDouble, asIndividual, asInteger, asList, asLiteral, asString, getComment, getLabel, isIndividual, isList, isLiteral
 
Methods inherited from interface info.sswap.api.model.SSWAPModel
addImport, checkProfile, dereference, dereference, doClosure, getDocument, getImports, getInputStream, getNsPrefixMap, getReasoningService, getTypeSignature, getURI, isDereferenced, removeImport, removeNsPrefix, serialize, serialize, setNsPrefix, validate
 

Method Detail

unionOf

SSWAPType unionOf(SSWAPType a)
Creates and returns a new type that is a union of this type and the given type. (That is, the new type contains all the individuals that belong to this type, the other type, OR both).

Parameters:
a - the other type, with which the union is taken.
Returns:
the new type that is the union of the current type and the given type.

intersectionOf

SSWAPType intersectionOf(SSWAPType a)
Creates and returns a new type that is an intersection of this type and the given type. (That is, the new type contains all the individuals that BOTH belong to this type AND the other type.)

Parameters:
a - the other type, with which the intersection is taken
Returns:
the new type that is the intersection of the current type and the given type.

complementOf

SSWAPType complementOf()
Creates the complement of the current type. (That is, the new type contains all the individuals that do NOT belong to the current type.)

Returns:
the new type that is the complement of the current type.

addRestrictionAllValuesFrom

void addRestrictionAllValuesFrom(SSWAPPredicate predicate,
                                 SSWAPType type)
Adds an owl:allValuesFrom restriction to this type on the specified predicate

Parameters:
predicate - predicate to which the restriction applies
type - the argument for owl:allValuesFrom

addRestrictionSomeValuesFrom

void addRestrictionSomeValuesFrom(SSWAPPredicate predicate,
                                  SSWAPType type)
Adds an owl:someValuesFrom restriction to this type on the specified predicate

Parameters:
predicate - predicate to which the restriction applies
type - the argument for owl:someValuesFrom

addRestrictionHasValue

void addRestrictionHasValue(SSWAPPredicate predicate,
                            SSWAPElement element)
Adds an owl:hasValue restriction to this type on the specified predicate

Parameters:
predicate - predicate to which the restriction applies
element - the value for owl:hasValue

addRestrictionHasSelf

void addRestrictionHasSelf(SSWAPPredicate predicate,
                           boolean value)
Adds an owl:hasSelf restriction to this type on the specified predicate

Parameters:
predicate - predicate to which the restriction applies
value - a boolean value (argument to owl:hasSelf)

addRestrictionMinCardinality

void addRestrictionMinCardinality(SSWAPPredicate predicate,
                                  int minCardinality)
Adds a min cardinality restriction to this type on the specified predicate.

Parameters:
predicate - predicate to which the cardinality restriction applies
minCardinality - the value of the minCardinality

addRestrictionMaxCardinality

void addRestrictionMaxCardinality(SSWAPPredicate predicate,
                                  int maxCardinality)
Adds a max cardinality restriction to this type on the specified predicate.

Parameters:
predicate - predicate to which the cardinality restriction applies
maxCardinality - the value of the maxCardinality

addRestrictionCardinality

void addRestrictionCardinality(SSWAPPredicate predicate,
                               int cardinality)
Adds a cardinality restriction to this type on the specified predicate.

Parameters:
predicate - predicate to which the cardinality restriction applies
cardinality - the cardinality value

addSubClassOf

void addSubClassOf(SSWAPType type)
Adds an rdfs:subClassOf axiom to this type.

Parameters:
type - the super type

addEquivalentClass

void addEquivalentClass(SSWAPType type)
Adds an owl:equivalentClass axiom to this type.

Parameters:
type - the equivalent type

addDisjointWith

void addDisjointWith(SSWAPType type)
Adds an owl:disjointWith axiom to this type.

Parameters:
type - the disjoint type with this one

addIntersectionOf

void addIntersectionOf(java.util.Collection<SSWAPType> classes)
Adds an owl:intersectionOf axiom to this type.

Parameters:
classes - SSWAPTypes that compose the intersection

addUnionOf

void addUnionOf(java.util.Collection<SSWAPType> classes)
Adds an owl:unionOf axiom to this type

Parameters:
classes - SSWAPTypes that compose the union

addDisjointUnionOf

void addDisjointUnionOf(java.util.Collection<SSWAPType> disjointClasses)
Adds an owl:disjointUnionOf axiom to this type

Parameters:
disjointClasses - SSWAPTypes that compose the disjointedness

addOneOf

void addOneOf(java.util.Collection<java.net.URI> oneOf)
Adds an owl:oneOf axiom to this type

Parameters:
oneOf - the collection of URIs that will be converted into argument to owl:oneOf

addAnnotationPredicate

void addAnnotationPredicate(SSWAPPredicate predicate,
                            SSWAPElement value)
Annotates a type with the given annotation predicate.

Parameters:
predicate - the predicate to be used in annotation

isSubTypeOf

boolean isSubTypeOf(SSWAPType superType)
Checks whether this type is a subtype of the other. (That is, whether all individuals of this type are necessarily individuals of the other type). By the laws of subsumption, "subtype" includes equivalency, so a type is always a subtype of itself.

Parameters:
superType - the potential super type
Returns:
true if this is a subtype of superType

isStrictSubTypeOf

boolean isStrictSubTypeOf(SSWAPType superType)
Checks whether this type is a strict subtype of the other. (That is, whether all individuals of this type are necessarily individuals of the other type, yet this type is not equivalent to the other type).

Parameters:
superType - the potential super type
Returns:
true if this is a strict subtype of sup.

isNothing

boolean isNothing()
Checks whether this type is unsatisfiable (i.e., whether it is a sub type of owl:Nothing).

Returns:
true if this type is unsatisfiable, false otherwise

isReserved

boolean isReserved()
Checks whether the given type belongs to restricted vocabulary (e.g., types defined in RDF, RDFS, OWL or SSWAP namespaces).

Returns:
true if the type belongs to restricted vocabulary.


Copyright (c) 2011, iPlant Collaborative, University of Arizona, Cold Spring Harbor Laboratories, University of Texas at Austin.