Skip to content

Commit

Permalink
Merge remote-tracking branch 'refs/remotes/origin/develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
dgarijo committed Mar 7, 2017
2 parents 3627f4d + c2a1110 commit 4aa22e0
Show file tree
Hide file tree
Showing 26 changed files with 1,380 additions and 274 deletions.
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ The character ";" is used for lists (for instance first author; second author; t

Now you can execute Widoco through the console. Usage:

java -jar widoco.jar [-ontFile file] or [-ontURI uri] [-outFolder folderName] [-confFile propertiesFile] or [-getOntologyMetadata] [-oops] [-rewriteAll] [-saveConfig configOutFile] [-useCustomStyle] [-lang lang1-lang2] [-includeImportedOntologies] [-htaccess] [-webVowl] [-licensius]
java -jar widoco.jar [-ontFile file] or [-ontURI uri] [-outFolder folderName] [-confFile propertiesFile] or [-getOntologyMetadata] [-oops] [-rewriteAll] [-crossRef] [-saveConfig configOutFile] [-useCustomStyle] [-lang lang1-lang2] [-includeImportedOntologies] [-htaccess] [-webVowl] [-licensius]

The ontFile and ontURI options allow you to choose the ontology file or ontology URI of your ontology.

Expand All @@ -66,6 +66,8 @@ The -oops flag creates an html page with the evaluation from the OOPS service (h

The -rewriteAll option will tell Widoco to rewrite files if the new generate files are replacing existing files. Otherwise the tool will promt a window asking the user.

The -crossRef option will ONLY generate the overview and cross reference sections. The index document will NOT be generated. The htaccess, provenance page, etc., will not be generated unless requested by other flags. This flag in intended to be used only after a first version of the documentation exists.

The -saveConfig option allows you to save a configuration file on the "configOutFile" route with the properties of a given ontology.

The -useCustomStyle option allows exporting the documentation using alternate css files (thanks to Daniel Vila).
Expand All @@ -82,7 +84,7 @@ The -licensius flag uses the Licensius web services (http://licensius.com/apidoc

Browser problems
==========
The result of executing Widoco is an html file. We have tested it in Mozilla, IE and Chrome, and when the page is stored in a server all the browsers work correctly. If you view the file locally, we recommend you to use Mozilla Firefox (or Internet Explorer, if you must). Google Chrome will not show the contents correctly, as it doesn't allow XMLHttpRequest without HTTP. If you want to view the page locally with Google Chrome you have two possibilities:
The result of executing Widoco is an html file. We have tested it in Mozilla, IE and Chrome, and when the page is stored in a server all the browsers work correctly. If you view the file locally, we recommend you to use Mozilla Firefox or Safari (or Internet Explorer, if you must). Google Chrome will not show the contents correctly, as it doesn't allow XMLHttpRequest without HTTP. If you want to view the page locally with Google Chrome you have two possibilities:

a) Place the file in a server and access it via its URL (for example, put it in dropbox and access through its public url).

Expand Down
2 changes: 0 additions & 2 deletions src/main/java/ar2dtool/readme.md

This file was deleted.

391 changes: 391 additions & 0 deletions src/main/java/diff/CompareOntologies.java

Large diffs are not rendered by default.

101 changes: 101 additions & 0 deletions src/main/java/diff/OWLAxiomInfo.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
package diff;

import java.util.HashSet;
import java.util.Set;

import org.semanticweb.owlapi.model.*;


/*
* Helper class to store information on a class which can be
* used to store information about difference between two classes
* newClassAxiomsSet holds axioms that have been added to this class
* and deletedClassAxiomsSet holds axioms that have been removed compared with
* the same class in another ontology
*/

/**
* @author Daniel Garijo
* This class has been modified by Daniel Garijo to make the axioms more general
* and capture changes in labels and comments or definitions (annotation properties)
* @author dgarijo
*/


public class OWLAxiomInfo {

private final IRI classIRI;
private Set<OWLAxiom> newAxiomSet;
private Set<OWLAxiom> deletedAxiomSet;




//constructor
public OWLAxiomInfo(IRI classIRI, Set<OWLAxiom> newClassAxiomsSet,
Set<OWLAxiom> deletedClassAxiomsSet) {
this.classIRI = classIRI;
this.newAxiomSet = newClassAxiomsSet;
this.deletedAxiomSet = deletedClassAxiomsSet;
}




public IRI getIRI(){
return classIRI;
}


//get method to return the new class axioms as Axioms
public Set<OWLAxiom> getNewAxioms(){
return newAxiomSet;
}

/**
* Method to merge two collection of axioms to the new Changes Set
* @param newAxioms
*/
public void addNewChangeAxioms(Set<OWLAxiom> newAxioms){
if(this.newAxiomSet==null){
this.newAxiomSet = new HashSet<OWLAxiom>();
}
if(newAxioms!= null && !newAxioms.isEmpty()){
this.newAxiomSet.addAll(newAxioms);
}

}

/**
* Method to merge two collection of axioms to the deletions Set
* @param deleteAxioms
*/
public void addDeleteChangeAxioms(Set<OWLAxiom> deleteAxioms){
if(this.deletedAxiomSet==null){
this.deletedAxiomSet = new HashSet<OWLAxiom>();
}
if(deleteAxioms !=null && !deleteAxioms.isEmpty()){
this.deletedAxiomSet.addAll(deleteAxioms);
}
}

//get method to return the deleted class axioms as Axioms
public Set<OWLAxiom> getDeletedAxioms(){
return deletedAxiomSet;
}


public String getIRIAsString(){
return this.classIRI.toString();
}



public boolean isEmpty(){
return!((this.newAxiomSet!=null && !this.newAxiomSet.isEmpty())||
(this.deletedAxiomSet!=null && !this.deletedAxiomSet.isEmpty()));
}



}
Loading

0 comments on commit 4aa22e0

Please sign in to comment.