Examples of ReasoningServiceException


Examples of org.apache.stanbol.reasoners.servicesapi.ReasoningServiceException

                    inferred.fillOntology(manager, output);
                } catch (InconsistentOntologyException i) {
                    throw i;
                } catch (Throwable t) {
                    log.error("Some problem occurred:\n {}", t.getStackTrace());
                    throw new ReasoningServiceException();
                }
                log.debug("Filled ontology: {}", output);
                log.debug("Temporary ID is {}", output.getOntologyID());
                axioms = manager.getOntology(output.getOntologyID()).getAxioms();
                // IMPORTANT We remove the ontology from the manager
                manager.removeOntology(output);
            } catch (OWLOntologyCreationException e) {
                log.error("An exception have been thrown when instantiating the ontology");
                throw new ReasoningServiceException();
            }

            return axioms;
        } catch (InconsistentOntologyException inconsistent) {
            /**
             * TODO Add report. Why it is inconsistent?
             */
            throw new InconsistentInputException();
        } catch (Exception exception) {
            log.error("An exception have been thrown while executing method run()", exception);
            throw new ReasoningServiceException();
        }
    }
View Full Code Here

Examples of org.apache.stanbol.reasoners.servicesapi.ReasoningServiceException

            return getReasoner(ontology).isConsistent();
        } catch (Exception e) {
            log.error("An error have been thrown while attempting to check consistency. Message was: {}",
                e.getLocalizedMessage());
            // TODO Add explanation of this exception
            throw new ReasoningServiceException();
        }
    }
View Full Code Here

Examples of org.apache.stanbol.reasoners.servicesapi.ReasoningServiceException

        } catch (OWLOntologyCreationException e) {
            log.error("An error have been thrown while attempting to create ontology. Message was: {}",
                e.getLocalizedMessage());
            // TODO Add explanation of this exception
            throw new ReasoningServiceException();
        }
    }
View Full Code Here

Examples of org.apache.stanbol.reasoners.servicesapi.ReasoningServiceException

            return new ReasoningServiceResult<Model>(ReasoningServiceExecutor.TASK_CHECK, false);
        } catch (UnsupportedTaskException e) {
            log.error("Error thrown: {}", e);
            throw e;
        } catch (IOException e) {
            throw new ReasoningServiceException(e);
        }
    }
View Full Code Here

Examples of org.apache.stanbol.reasoners.servicesapi.ReasoningServiceException

            return new ReasoningServiceResult<OWLOntology>(ReasoningServiceExecutor.TASK_CHECK, false);
        } catch (ReasoningServiceException e) {
            throw e;
        } catch (OWLOntologyCreationException e) {
            log.error("Error! \n", e);
            throw new ReasoningServiceException(new IOException(e));
        } catch (UnsupportedTaskException e) {
            log.error("Error! \n", e);
            throw e;
        } catch (Throwable t) {
            log.error("Error! \n", t);
            throw new ReasoningServiceException(t);
        }
    }
View Full Code Here

Examples of org.apache.stanbol.reasoners.servicesapi.ReasoningServiceException

        } else if (service instanceof OWLApiReasoningService) {
            OWLOntology input;
            try {
                input = OWLManager.createOWLOntologyManager().createOntology();
            } catch (OWLOntologyCreationException e) {
                throw new ReasoningServiceException(e);
            }
            synchronized (inmgr) {
                Iterator<OWLAxiom> statements = inmgr.getInputData(OWLAxiom.class);
                while (statements.hasNext()) {
                    input.getOWLOntologyManager().addAxiom(input, statements.next());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.