|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectkaos.core.csi.ontology.OntologyServiceImpl
public class OntologyServiceImpl
Defines the operations to manage and access Ontology Service and its repository
| Method Summary | |
|---|---|
SerializableOntModelImpl |
getConstructedOntologyStructure(java.lang.String structureId)
This method retrieves user defined ontology structure identified by the id from the repository. |
java.util.List |
getConstructedOntologyStructures()
This method retrieves all user defined ontology structures in the repository. |
java.util.Set |
getImmediateSubClassesOf(java.lang.String className)
Get set of immediate subclasses of the given class (direct children of the class). |
static OntologyService |
getInstance()
Retrieve an instance of OntologyService. |
static OntologyService |
getInstance(java.lang.String transportName)
Retrieve an instance of OntologyService. |
java.util.Set<java.lang.String> |
getInstancesOf(java.lang.String conceptName)
Get set of instances of the given concept; if the concept is an instance itself the set contains just this instance. |
java.util.Set<java.lang.String> |
getListOfLoadedOntologies()
This method returns a set of urls depicting ontologies loaded into the Ontology Service |
java.util.Set<java.lang.String> |
getOntologyDefinitionForConcept(java.lang.String conceptName)
Get set of urls for the given short concept name. |
java.util.List<java.lang.String> |
getPropertiesApplicableTo(java.lang.String className)
Get properties applicable to the given class |
java.lang.String |
getRangeOnPropertyForClass(java.lang.String className,
java.lang.String propertyName)
Get the name of the class defining the range of the specified property for the given class. |
java.util.List<java.lang.String> |
getSchema(java.lang.String conceptName)
Get XML schema of the given concept if such a schema is available |
java.util.Set |
getSubClassesOf(java.lang.String className)
Get set of subclasses of the given class. |
java.util.Set |
getSubPropertiesOf(java.lang.String propertyName)
Get set of subproperties of the given property. |
java.util.Set |
getSuperPropertiesOf(java.lang.String propertyName)
Get set of superproperties of the given property. |
java.util.Set<java.lang.String> |
getUltimateOntologyTypesOfIndividual(java.lang.String individualName)
Finds the ultimate Ontology type of the provided individual |
java.util.Set<java.lang.String> |
getValuesForProperty(java.lang.String property,
java.lang.String subject)
Get the values of a given property for a given subject |
java.util.Vector |
initiateActionClassTargets(java.lang.String actionClassName,
java.lang.String actorClassName)
Get properties applicable to the action class |
void |
loadOntologies(java.util.List<SerializableOntModelImpl> myOntModels,
boolean recursiveLoad)
Adds ontology included in the provide objects into the ontology repository. |
void |
loadOntology(SerializableOntModelImpl myOntModel,
boolean recursiveLoad)
Adds ontology included in the provide objects into the ontology repository. |
void |
loadOntology(java.lang.String loadedOWL)
Loads ontology in OWL into the repository of the Ontology Service |
void |
loadOntology(java.lang.String myURL,
boolean recursiveLoad)
Loads ontology in OWL from given URL into the repository of the Ontology Service |
protected void |
logMessage(java.lang.String msg,
java.lang.Exception e,
int logLevel)
|
protected void |
logMessage(java.lang.String msg,
int logLevel)
|
void |
putSchema(java.lang.String conceptName,
java.lang.String xmlSchema)
Add an XML schema for the given concept |
void |
removeConstructedOntologyStructure(java.lang.String structureId)
This method removes a user defined ontology structure identified by the id from the repository. |
void |
removeConstructedOntologyStructures(java.util.List<java.lang.String> structureIds)
This method removes multiple user defined ontology structure identified by the id from the repository. |
boolean |
testTrue(java.lang.String statement)
Test if the KIF statemant is true according to the ontologies in the ontology repository. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static OntologyService getInstance(java.lang.String transportName)
throws java.lang.Exception
transportName - String specifying the name of the transport to use for communication with the KAoS Directory Service.
java.lang.Exception
public static OntologyService getInstance()
throws java.lang.Exception
java.lang.Exception
public java.util.Set<java.lang.String> getInstancesOf(java.lang.String conceptName)
throws UnknownConceptException,
DirectoryFailure
OntologyService
getInstancesOf in interface OntologyServiceconceptName - The name of the concept in the Jena format
UnknownConceptException
DirectoryFailureOntologyService.getInstancesOf(java.lang.String)
public java.util.Set<java.lang.String> getUltimateOntologyTypesOfIndividual(java.lang.String individualName)
throws UnknownConceptException,
DirectoryFailure
getUltimateOntologyTypesOfIndividual in interface OntologyServiceindividualName - the name of the individual
UnknownConceptException - if concept unknown or any problem with JTP approached
DirectoryFailure
public java.util.Set<java.lang.String> getListOfLoadedOntologies()
throws DirectoryFailure
OntologyService
getListOfLoadedOntologies in interface OntologyServiceDirectoryFailureOntologyService.getListOfLoadedOntologies()
public java.util.Set<java.lang.String> getOntologyDefinitionForConcept(java.lang.String conceptName)
throws DirectoryFailure
OntologyService
getOntologyDefinitionForConcept in interface OntologyServiceconceptName - A short name of concept, e.g. "Actor"
DirectoryFailureOntologyService.getOntologyDefinitionForConcept(java.lang.String)
public java.util.List<java.lang.String> getPropertiesApplicableTo(java.lang.String className)
throws UnknownConceptException,
QueryFailure,
DirectoryFailure
OntologyService
getPropertiesApplicableTo in interface OntologyServiceclassName - the name of the class
UnknownConceptException
QueryFailure
DirectoryFailureOntologyService.getPropertiesApplicableTo(java.lang.String)
public java.util.Set<java.lang.String> getValuesForProperty(java.lang.String property,
java.lang.String subject)
throws DirectoryFailure,
QueryFailure
OntologyService
getValuesForProperty in interface OntologyServiceproperty - - the property for which to lookup valuessubject - - the subject to get the property values for
QueryFailure
DirectoryFailureOntologyService.getValuesForProperty(java.lang.String, java.lang.String)
public java.lang.String getRangeOnPropertyForClass(java.lang.String className,
java.lang.String propertyName)
throws UnknownConceptException,
QueryFailure,
DirectoryFailure
OntologyService
getRangeOnPropertyForClass in interface OntologyServiceclassName - the name of the classpropertyName - the name of the property
UnknownConceptException
QueryFailure
DirectoryFailureOntologyService.getRangeOnPropertyForClass(java.lang.String, java.lang.String)
public java.util.List<java.lang.String> getSchema(java.lang.String conceptName)
throws UnknownConceptException,
DirectoryFailure
OntologyService
getSchema in interface OntologyServiceconceptName - uri name of the concept
UnknownConceptException
DirectoryFailureOntologyService.getSchema(java.lang.String)
public void putSchema(java.lang.String conceptName,
java.lang.String xmlSchema)
throws DirectoryFailure
OntologyService
putSchema in interface OntologyServiceconceptName - uri name of the concept
DirectoryFailureOntologyService.putSchema(java.lang.String, java.lang.String)
public java.util.Set getSubClassesOf(java.lang.String className)
throws UnknownConceptException,
DirectoryFailure
OntologyService
getSubClassesOf in interface OntologyServiceclassName - The name of the class
UnknownConceptException
DirectoryFailure
public java.util.Set getImmediateSubClassesOf(java.lang.String className)
throws UnknownConceptException,
DirectoryFailure
OntologyService
getImmediateSubClassesOf in interface OntologyServiceclassName - The name of the class in Jena format
UnknownConceptException
DirectoryFailure
public java.util.Set getSubPropertiesOf(java.lang.String propertyName)
throws UnknownConceptException,
DirectoryFailure
OntologyService
getSubPropertiesOf in interface OntologyServicepropertyName - The name of the property
UnknownConceptException
DirectoryFailure
public java.util.Set getSuperPropertiesOf(java.lang.String propertyName)
throws UnknownConceptException,
DirectoryFailure
OntologyService
getSuperPropertiesOf in interface OntologyServicepropertyName - The name of the property
UnknownConceptException
DirectoryFailure
public java.util.Vector initiateActionClassTargets(java.lang.String actionClassName,
java.lang.String actorClassName)
throws DirectoryFailure
OntologyService
initiateActionClassTargets in interface OntologyServiceactionClassName - the name of the action class performingactorClassName - the name of the actor class performing the action
DirectoryFailure
public void loadOntology(java.lang.String loadedOWL)
throws OntologyRepository.ReasoningException,
DirectoryFailure
OntologyService
loadOntology in interface OntologyServiceloadedOWL - string containing a syntactically correctly OWL
OntologyRepository.ReasoningException - when loading of the ontology failed.
DirectoryFailure
public void loadOntology(java.lang.String myURL,
boolean recursiveLoad)
throws OntologyRepository.ReasoningException,
java.io.IOException,
DirectoryFailure
OntologyService
loadOntology in interface OntologyServicerecursiveLoad - whether to load the OWL imported by the given URI
OntologyRepository.ReasoningException - when loading of the ontology failed.
java.io.IOException
DirectoryFailure
public void loadOntology(SerializableOntModelImpl myOntModel,
boolean recursiveLoad)
throws OntologyRepository.ReasoningException,
java.io.IOException
OntologyService
loadOntology in interface OntologyServicemyOntModel - The object of type Jena OntModel containing the added ontologyrecursiveLoad - Indicates if the imported ontologies (by the ontology contained in myOntModel) should also be recursively loaded.
OntologyRepository.ReasoningException
java.io.IOException
public void loadOntologies(java.util.List<SerializableOntModelImpl> myOntModels,
boolean recursiveLoad)
throws OntologyRepository.ReasoningException,
java.io.IOException
OntologyService
loadOntologies in interface OntologyServicerecursiveLoad - Indicates if the imported ontologies (by the ontology contained in myOntModel) should also be recursively loaded.
OntologyRepository.ReasoningException
java.io.IOException
public boolean testTrue(java.lang.String statement)
throws QueryFailure,
DirectoryFailure
OntologyService
testTrue in interface OntologyServicestatement - the statement in KIF to be tested if true
QueryFailure
DirectoryFailure
public SerializableOntModelImpl getConstructedOntologyStructure(java.lang.String structureId)
throws OntologyRepository.ReasoningException,
UnknownConceptException,
java.io.IOException,
DirectoryFailure
OntologyService
getConstructedOntologyStructure in interface OntologyServiceOntologyRepository.ReasoningException
UnknownConceptException
java.io.IOException
DirectoryFailure
public java.util.List getConstructedOntologyStructures()
throws DirectoryFailure
OntologyService
getConstructedOntologyStructures in interface OntologyServiceDirectoryFailure
public void removeConstructedOntologyStructure(java.lang.String structureId)
throws DirectoryFailure
OntologyService
removeConstructedOntologyStructure in interface OntologyServiceDirectoryFailure
public void removeConstructedOntologyStructures(java.util.List<java.lang.String> structureIds)
throws DirectoryFailure
OntologyService
removeConstructedOntologyStructures in interface OntologyServiceDirectoryFailure
protected void logMessage(java.lang.String msg,
int logLevel)
protected void logMessage(java.lang.String msg,
java.lang.Exception e,
int logLevel)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||