Package com.hp.hpl.jena.ontology

Examples of com.hp.hpl.jena.ontology.OntDocumentManager


        || (cmd.contains(liteDecl) && cmd.contains(dlDecl));
    if (cmd.contains(helpDecl) || bad) {
      System.out.println(usageMessage);
      System.exit(bad ? 1 : 0);
    }
    OntDocumentManager dm;
   
    if ( cmd.contains(dmDecl) )
      dm =  new OntDocumentManager(
        cmd.getArg(dmDecl).getValue());
    else {
      dm =new OntDocumentManager();
        dm.setProcessImports(true);
    }
   
    if (testing) {
      String manifest = "http://www.w3.org/TR/owl-test/Manifest";
      if (cmd.numItems() > 0) {
View Full Code Here


    return model;
  }
 
  private static OntModel createDefaultOntModel() {
    OntModelSpec spec = new OntModelSpec(OntModelSpec.OWL_MEM);
    OntDocumentManager docMang = new OntDocumentManager();
    spec.setDocumentManager(docMang);
    OntModel model = ModelFactory.createOntologyModel(spec, null);
    // removeNotNeccesaryNamespaces(model);

    return model;
View Full Code Here

  }

  // verbatim copy from JenaUtil
  public static OntModel createDefaultOntModel() {
    OntModelSpec spec = new OntModelSpec(OntModelSpec.OWL_MEM);
    OntDocumentManager docMang = new OntDocumentManager();
    spec.setDocumentManager(docMang);
    OntModel model = ModelFactory.createOntologyModel(spec, null);
    // removeNotNeccesaryNamespaces(model);

    return model;
View Full Code Here

  }
 
 
  private static OntModel createDefaultOntModel() {
    OntModelSpec spec = new OntModelSpec(OntModelSpec.OWL_MEM);
    OntDocumentManager docMang = new OntDocumentManager();
    spec.setDocumentManager(docMang);
    OntModel model = ModelFactory.createOntologyModel(spec, null);
    // removeNotNeccesaryNamespaces(model);

    return model;
View Full Code Here

    model.read(uriModel, lang);
    return model;
  }
  private static OntModel _createDefaultOntModel() {
    OntModelSpec spec = new OntModelSpec(OntModelSpec.OWL_MEM);
    OntDocumentManager docMang = new OntDocumentManager();
    spec.setDocumentManager(docMang);
    OntModel model = ModelFactory.createOntologyModel(spec, null);
    // removeNotNeccesaryNamespaces(model);

    return model;
View Full Code Here

    return uri.replaceAll("(/|#)+$", "");
  }

  private static OntModel createDefaultOntModel() {
    OntModelSpec spec = new OntModelSpec(OntModelSpec.OWL_MEM);
    OntDocumentManager docMang = new OntDocumentManager();
    spec.setDocumentManager(docMang);
    OntModel model = ModelFactory.createOntologyModel(spec, null);
    // removeNotNeccesaryNamespaces(model);

    return model;
View Full Code Here

    return model;
  }

  private static OntModel createDefaultOntModel() {
    OntModelSpec spec = new OntModelSpec(OntModelSpec.OWL_MEM);
    OntDocumentManager docMang = new OntDocumentManager();
    spec.setDocumentManager(docMang);
    OntModel model = ModelFactory.createOntologyModel(spec, null);
    // removeNotNeccesaryNamespaces(model);

    return model;
View Full Code Here

     * @throws ResourceNotFoundException
     */
    private OntModel createJenaOWLModel(ResourceLoader owlSource) throws ResourceNotFoundException {
        KnowledgeResourceTO[] owlsources = null;
        //Do not use reasoner to load ontologies
        OntDocumentManager dm = OntDocumentManager.getInstance();
        dm.setProcessImports(false);
        OntModelSpec spec = new OntModelSpec( OntModelSpec.OWL_MEM);
        spec.setDocumentManager(dm);
        OntModel ontModel = ModelFactory.createOntologyModel(spec, null );
        owlsources = owlSource.getKnowledgeResources();
        logger.debug("Loading " + owlsources.length  +" resources into the model");
View Full Code Here

    }
   
    private OntModel createJenaOWLModel(ResourceLoader owlSource) throws ResourceNotFoundException {
        KnowledgeResourceTO[] owlsources = null;
        Reasoner reasoner =  PelletReasonerFactory.theInstance().create();
        OntDocumentManager dm = OntDocumentManager.getInstance();
        dm.setProcessImports(false);
        OntModelSpec spec = new OntModelSpec( OntModelSpec.OWL_DL_MEM);
        spec.setDocumentManager(dm);       
        //spec.setReasoner(new OWLMicroReasoner(OWLMicroReasonerFactory.theInstance()));
        spec.setReasoner(reasoner);
        OntModel ontModel = ModelFactory.createOntologyModel( spec, null );
View Full Code Here

  }
 
 
  private static OntModel createDefaultOntModel() {
    OntModelSpec spec = new OntModelSpec(OntModelSpec.OWL_MEM);
    OntDocumentManager docMang = new OntDocumentManager();
    spec.setDocumentManager(docMang);
    OntModel model = ModelFactory.createOntologyModel(spec, null);
    // removeNotNeccesaryNamespaces(model);

    return model;
View Full Code Here

TOP

Related Classes of com.hp.hpl.jena.ontology.OntDocumentManager

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.