Package edu.stanford.smi.protegex.owl.repository

Examples of edu.stanford.smi.protegex.owl.repository.Repository


    if(model != null){
      model.getProject().setProjectFilePath((new File(f,name+".pprj")).getAbsolutePath());
      model.getOWLProject().getSettingsMap().setString("owl_file_name",filePath);
     
      // add repository from potential import ontologies
      Repository rep = RepositoryFactory.getInstance().createOntRepository(model,""+f.toURI());
      if (rep != null) {
        model.getRepositoryManager().addProjectRepository(rep);
          }
     
      // this should be here
View Full Code Here


    if(model != null){
      model.getProject().setProjectFilePath((new File(f,name+".pprj")).getAbsolutePath());
      model.getOWLProject().getSettingsMap().setString("owl_file_name",filePath);
     
      // add repository from potential import ontologies
      Repository rep = RepositoryFactory.getInstance().createOntRepository(model,""+f.toURI());
      if (rep != null) {
        model.getRepositoryManager().addProjectRepository(rep);
          }
     
      // this should be here
View Full Code Here

      // I am tired, for some reason this property may be reset and
      // instead of full path URI it stores file name, well in this case
      // lets return location instead
      if(!path.contains("/"))
        path = o.getLocation();
      Repository rep = RepositoryFactory.getInstance().createOntRepository(imodel,path);
      if (rep != null) {
        model.getRepositoryManager().addProjectRepository(rep);
          }
     
      /*
 
View Full Code Here

        if(o instanceof RDFResource){
          //TODO: maybe there is some tripplestore trick that I can use
          // and avoid loading imported ontology again
          RDFResource on = (RDFResource) o;
          PResource ont = new PResource(on);
          Repository r = model.getRepositoryManager().getRepository(ont.getURI());
          //TODO We check this because sometimes r is null. We dont understand this completely,
          //just circumventing this for now.
          if(r==null)
            continue;
          URI uri = ont.getURI();
          String location = r.getOntologyLocationDescription(uri);
          Properties map = new Properties();
          map.put("name",PUtils.getName(uri));
          map.put("version",ont.getVersion());
          map.put("description",ont.getDescription());
          map.put("uri",""+uri);
View Full Code Here

    if(model != null){
      model.getProject().setProjectFilePath((new File(f,name+".pprj")).getAbsolutePath());
      model.getOWLProject().getSettingsMap().setString("owl_file_name",filePath);
     
      // add repository from potential import ontologies
      Repository rep = RepositoryFactory.getInstance().createOntRepository(model,""+f.toURI());
      if (rep != null) {
        model.getRepositoryManager().addProjectRepository(rep);
          }
     
      // this should be here
View Full Code Here

    if(model != null){
      model.getProject().setProjectFilePath((new File(f,name+".pprj")).getAbsolutePath());
      model.getOWLProject().getSettingsMap().setString("owl_file_name",filePath);
     
      // add repository from potential import ontologies
      Repository rep = RepositoryFactory.getInstance().createOntRepository(model,""+f.toURI());
      if (rep != null) {
        model.getRepositoryManager().addProjectRepository(rep);
          }
     
      // this should be here
View Full Code Here

      // I am tired, for some reason this property may be reset and
      // instead of full path URI it stores file name, well in this case
      // lets return location instead
      if(!path.contains("/"))
        path = o.getLocation();
      Repository rep = RepositoryFactory.getInstance().createOntRepository(imodel,path);
      if (rep != null) {
        model.getRepositoryManager().addProjectRepository(rep);
          }
     
      /*
 
View Full Code Here

        if(o instanceof RDFResource){
          //TODO: maybe there is some tripplestore trick that I can use
          // and avoid loading imported ontology again
          RDFResource on = (RDFResource) o;
          PResource ont = new PResource(on);
          Repository r = model.getRepositoryManager().getRepository(ont.getURI());
          //TODO We check this because sometimes r is null. We dont understand this completely,
          //just circumventing this for now.
          if(r==null)
            continue;
          URI uri = ont.getURI();
          String location = r.getOntologyLocationDescription(uri);
          Properties map = new Properties();
          map.put("name",PUtils.getName(uri));
          map.put("version",ont.getVersion());
          map.put("description",ont.getDescription());
          map.put("uri",""+uri);
View Full Code Here

TOP

Related Classes of edu.stanford.smi.protegex.owl.repository.Repository

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.