Protege 4.1 Migration Guide
This page describes the major differences between Protege4.0 and Protege4.1 for developers of plugins to allow for smooth migration of plugins.
Back to Protege4DevDocs
Work in progress
The OWL 2 specification has been a slowly moving target in the 2 years preceding the release of Protege 4.0.
In order for the platform to be reasonably stable for developers we have been using a version of the OWL API that approximately implements OWL 1.1 (the initial iteration of the OWL 1 specification). In the background work has been going on to bring the OWL API in line with the OWL 2 specification and Protege 4.1 was branched in Spring 2009 to allow migration to this version (OWL API v3).
The code for Protege 4.1 (working title) is available in svn at protege4/protege-standalone/branches/protege4_1_port/. It can be built and run in the same way as the current codebase. Although most new work will be on this branch, the code will remain branched until the OWL API is deemed stable. As of late June 2009, there are still some fairly large refactoring exercises going on.
As of the end of June 2009, the OWL API is still in flux and changes will be reflected in Protege 4.1 as soon as it is possible to do so.
The codebase builds and seems to run fairly smoothly, but has not been significantly regression tested, so please use with care - particularly with new features.
The code still has a few unported features or open questions - these are currently marked with @@TODO v3 port.
- Editing of annotation axioms is not implemented (adding one will cause a NPE)
- Editing of SWRL rules is not currently implemented
What has changed?
OWL API changes
The OWL API v3 now implements the OWL 2 specification and has matched, wherever possible, the OWL vocabulary.
This means that some classes, such as OWLDescription have now been changed (it is now OWLClassExpression). An incomplete list is below.
It was also decided to rename the packages in the new version of the OWL API so that name clashes could be avoided completely (so that implementors could bundle implementations that run on both versions).
There are several major structural changes:
- All named things are now referred to by IRI (unicode version of URI) instead of URI
- Ontologies are now referred to by an OWLOntologyID which may be anonymous, contain a single URI or additionally a version URI
- Annotation properties have been re-introduced as entities - replacing annotations using just URIs
- OWLIndividuals are no longer entities as they can be anonymous - OWLNamedIndividuals (a subclass) are entities
- Top level object and data properties are now in existence.
- Axiom annotations are no longer stand-off axioms in there own right. They are now part of other axioms
- Annotations can be on entities or on IRIs
- There have been some extra constructs added to the vocabulary (such as OWLDatatypeDefinition) which means that visitor implementations must be updated
- Imports are no longer axioms
- The changes API has been extended to support ontology name, annotation and import changes
Fundamentally, Protege 4.1 has tried to remain fairly unchanged where possible. Most of the changes have been to match the new names for OWLObjects and aligning method names etc.
Most notably in the UI, we now have an annotation property hierarchy (and appropriate hierarchy provider) and additional views for describing annotation properties (so that annotations, superproperties, domain and range can be added) as well as support for rendering, finding etc.
There is also support for the additional vocabulary - Keys and Datatype definitions.
Finally, this has been a good opportunity to remove deprecated classes and a number of classes have been moved to make the package structure a bit more clear.
Package changes in P4.1
The following packages have been restructured:
- org.protege.editor.owl.ui.view has been split up into more categorised sub-packages based on type
- Class hierarchy views have been moved from org.protege.editor.owl.ui.clshierarchy to org.protege.editor.owl.ui.view.cls
- org.protege.editor.owl.ui.frame has been split up into more categorised sub-packages based on type
OWL API package Changes
|OWL API v2||OWL API v3|
OWL API Vocabulary Changes
The OWL API v3 should be in line with the vocabulary described in the OWL 2 specification. This list is incomplete, but shows the most likely renames that will be required. Consult the OWL 2 quick reference guide for additional pointers.
|OWL API v2||OWL API v3|