Package org.semanticweb.owlapi.model

Examples of org.semanticweb.owlapi.model.OWLRuntimeException


    void ReInit(java.io.InputStream stream, String encoding) {
        try {
            jj_input_stream.ReInit(stream, encoding, 1, 1);
        } catch (java.io.UnsupportedEncodingException e) {
            throw new OWLRuntimeException(e);
        }
        token_source.ReInit(jj_input_stream);
        token = new Token();
        jj_ntk = -1;
        jj_gen = 0;
View Full Code Here


            if (obodoc.getTermFrames().isEmpty() && !allowEmptyFrames) {
                fail("Term frames should not be empty.");
            }
            return obodoc;
        } catch (IOException e) {
            throw new OWLRuntimeException(e);
        }
    }
View Full Code Here

        OWLOntology ontology;
        try {
            ontology = bridge.convert(obodoc);
            return ontology;
        } catch (OWLOntologyCreationException e) {
            throw new OWLRuntimeException(e);
        }
    }
View Full Code Here

        StringDocumentTarget target = new StringDocumentTarget();
        OWLOntologyManager manager = ontology.getOWLOntologyManager();
        try {
            manager.saveOntology(ontology, format, target);
        } catch (OWLOntologyStorageException e) {
            throw new OWLRuntimeException(e);
        }
        return target;
    }
View Full Code Here

                    new RDFXMLDocumentFormat(), target);
            return OWLManager.createOWLOntologyManager()
                    .loadOntologyFromOntologyDocument(
                            new StringDocumentSource(target));
        } catch (OWLException e) {
            throw new OWLRuntimeException(e);
        }
    }
View Full Code Here

        if (fullIRI != null) {
            return fullIRI;
        }
        OBOIdType idType = OBOIdType.getIdType(symbolicIdOrOBOId);
        if (idType == null) {
            throw new OWLRuntimeException("Invalid ID: " + symbolicIdOrOBOId
                    + " in frame " + currentId);
        } else {
            return idType.getIRIFromOBOId(ontology.getOntologyID(),
                    idSpaceManager, symbolicIdOrOBOId);
        }
View Full Code Here

            return iri;
        }
        OWLOntologyID ontologyID = getOntology().getOntologyID();
        OBOIdType type = OBOIdType.getIdType(trimmed);
        if (type == null) {
            throw new OWLRuntimeException("Not a valid OBO ID: " + s);
        }
        IRI freshIRI = type
                .getIRIFromOBOId(ontologyID, idSpaceManager, trimmed);
        uriCache.put(trimmed, freshIRI);
        return freshIRI;
View Full Code Here

                handler.getConfiguration());
    }

    @Override
    OWLOntology getOWLObject() {
        throw new OWLRuntimeException(
                "There is no OWLObject for imports handlers");
    }
View Full Code Here

                    configuration);
            parser.parse(isrc, handler);
            format.copyPrefixesFrom(handler.getPrefixName2PrefixMap());
            return format;
        } catch (ParserConfigurationException e) {
            throw new OWLRuntimeException(e);
        } catch (SAXException e) {
            // General exception
            throw new OWLParserException(e);
        } finally {
            if (isrc != null && isrc.getByteStream() != null) {
View Full Code Here

        try {
            return OWLManager.createOWLOntologyManager()
                    .loadOntologyFromOntologyDocument(
                            new StringDocumentSource(in));
        } catch (OWLOntologyCreationException e) {
            throw new OWLRuntimeException(e);
        }
    }
View Full Code Here

TOP

Related Classes of org.semanticweb.owlapi.model.OWLRuntimeException

Copyright © 2018 www.massapicom. 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.