Class InstanceOntologyOrderPredicateImpl
- java.lang.Object
-
- de.uni_trier.wi2.procake.data.model.base.impl.InstancePredicateImpl
-
- de.uni_trier.wi2.procake.data.model.base.impl.InstanceOntologyOrderPredicateImpl
-
- All Implemented Interfaces:
InstanceOntologyOrderPredicate,InstancePredicate
public class InstanceOntologyOrderPredicateImpl extends InstancePredicateImpl implements InstanceOntologyOrderPredicate
InstanceOntologyOrderPredicateImpl class.
-
-
Field Summary
-
Fields inherited from class de.uni_trier.wi2.procake.data.model.base.impl.InstancePredicateImpl
atomicClass
-
-
Constructor Summary
Constructors Constructor Description InstanceOntologyOrderPredicateImpl(AtomicClassImpl parentClass)Constructor for InstanceOntologyOrderPredicateImpl.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetHierarchyHeight()getHierarchyHeight.BooleangetIntersection(Set<org.apache.jena.rdf.model.Resource> nodeSetA, Set<org.apache.jena.rdf.model.Resource> nodeSetB)getIntersection.Set<org.apache.jena.rdf.model.Resource>getParentNodes(org.apache.jena.rdf.model.Resource node)getParentNodes.Set<String>getRelations()getRelations.StringgetRootNodeURI()getRootNodeURI.booleanholdsFor(Object value)EachInstancePredicatemust implement this method to check if the givenvalueis an element of theInstancePredicate.voidinit()Re-inits the predicate.voidinit(String rootNodeUri, String... relations)(Re)Inits the predicate with the given root uri and relations.voidsetIntersection(Set<org.apache.jena.rdf.model.Resource> nodeSetA, Set<org.apache.jena.rdf.model.Resource> nodeSetB, boolean intersection)setIntersection.voidsetParentNodes(org.apache.jena.rdf.model.Resource node, Set<org.apache.jena.rdf.model.Resource> parentNodes)setParentNodes.-
Methods inherited from class de.uni_trier.wi2.procake.data.model.base.impl.InstancePredicateImpl
checkFinishEditing, finishEditing, getAtomicClass, isEnumerationPredicate, isIntervalPredicate, isTaxonomyOrderPredicate, isTotalOrderPredicate
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface de.uni_trier.wi2.procake.data.model.base.InstancePredicate
getAtomicClass, isEnumerationPredicate, isIntervalPredicate, isTaxonomyOrderPredicate, isTotalOrderPredicate
-
-
-
-
Constructor Detail
-
InstanceOntologyOrderPredicateImpl
public InstanceOntologyOrderPredicateImpl(AtomicClassImpl parentClass)
Constructor for InstanceOntologyOrderPredicateImpl.
- Parameters:
parentClass- aAtomicClassImplobject
-
-
Method Detail
-
holdsFor
public boolean holdsFor(Object value)
EachInstancePredicatemust implement this method to check if the givenvalueis an element of theInstancePredicate.- Specified by:
holdsForin interfaceInstancePredicate- Parameters:
value- The value to check- Returns:
trueif the value is an element of theInstancePredicate
-
getRootNodeURI
public String getRootNodeURI()
getRootNodeURI.
- Specified by:
getRootNodeURIin interfaceInstanceOntologyOrderPredicate- Returns:
- root node
-
getRelations
public Set<String> getRelations()
getRelations.
- Specified by:
getRelationsin interfaceInstanceOntologyOrderPredicate- Returns:
- set of relations
-
init
public void init(String rootNodeUri, String... relations)
(Re)Inits the predicate with the given root uri and relations. Collects a set of valid values from the ontology respecting the given root node and added relations.- Specified by:
initin interfaceInstanceOntologyOrderPredicate- Parameters:
rootNodeUri- the root node urirelations- the list of relations that should be added.
-
init
public void init()
Re-inits the predicate. Uses a given root node and relations. Collects a set of valid values from the ontology.- Specified by:
initin interfaceInstanceOntologyOrderPredicate
-
getHierarchyHeight
public int getHierarchyHeight()
getHierarchyHeight.
- Specified by:
getHierarchyHeightin interfaceInstanceOntologyOrderPredicate- Returns:
- a int
-
getParentNodes
public Set<org.apache.jena.rdf.model.Resource> getParentNodes(org.apache.jena.rdf.model.Resource node)
getParentNodes.
- Specified by:
getParentNodesin interfaceInstanceOntologyOrderPredicate- Parameters:
node- aResourceobject- Returns:
- a
Setobject
-
setParentNodes
public void setParentNodes(org.apache.jena.rdf.model.Resource node, Set<org.apache.jena.rdf.model.Resource> parentNodes)setParentNodes.
- Specified by:
setParentNodesin interfaceInstanceOntologyOrderPredicate- Parameters:
node- aResourceobjectparentNodes- aSetobject
-
getIntersection
public Boolean getIntersection(Set<org.apache.jena.rdf.model.Resource> nodeSetA, Set<org.apache.jena.rdf.model.Resource> nodeSetB)
getIntersection.
- Specified by:
getIntersectionin interfaceInstanceOntologyOrderPredicate- Parameters:
nodeSetA- aSetobjectnodeSetB- aSetobject- Returns:
- a
Booleanobject
-
setIntersection
public void setIntersection(Set<org.apache.jena.rdf.model.Resource> nodeSetA, Set<org.apache.jena.rdf.model.Resource> nodeSetB, boolean intersection)
setIntersection.
- Specified by:
setIntersectionin interfaceInstanceOntologyOrderPredicate- Parameters:
nodeSetA- aSetobjectnodeSetB- aSetobjectintersection- a boolean
-
-