public class OwlQuery
extends java.lang.Object
| Constructor and Description |
|---|
OwlQuery()
Create a new OwlQuery with a null queryClass.
|
OwlQuery(OwlClass owlClass)
Create a new OwlQuery with the specified class as the queryClass
|
OwlQuery(java.lang.String className)
Create a new OwlQuery with the specified class as the queryClass.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addRelation(java.lang.String relationName,
OwlThing relatedTo)
Add a relation to the set of relations to match.
|
void |
addRestriction(OwlRestriction rest)
Add a restriction to the set of restrictions for this query
|
java.util.Set<OwlThing> |
getMatches()
Get the set of OwlThings that match the query.
|
OwlClass |
getQueryClass()
Return the queryClass
|
void |
setQueryClass(OwlClass cls)
Set the queryClass.
|
public OwlQuery()
public OwlQuery(OwlClass owlClass)
owlClass - the queryClasspublic OwlQuery(java.lang.String className)
className - the name of the queryClasspublic void addRelation(java.lang.String relationName,
OwlThing relatedTo)
relationName - the relation namerelatedTo - the object the thing should be related to.public void addRestriction(OwlRestriction rest)
rest - the new restrictionpublic java.util.Set<OwlThing> getMatches()
public OwlClass getQueryClass()
public void setQueryClass(OwlClass cls)
cls - the query class