This package provides a collection of interface definitions that provide an API to OWL ontologies. An ontology consists of a number of classes, properties and individuals. In addition, an ontology will contain a number of axioms that provide definitions of classes and describe the relationships that hold between classes.
The interfaces defined here essentially describe the OWL objects as
simple structs. There is little functionality offered here other than
get and set methods.
Many of the classes defined here make use of collections. For example, {@link uk.ac.man.cs.img.owl.model.NaryBooleanDescription NaryBooleanDescription} has a collection of expressions which are (unsurprisingly) the operands to the operator. The interfaces use a generic List type {@link uk.ac.man.cs.img.owl.model.OWLList OWLList}. This means that users of the API may have to cast objects as they are extracted from the lists, e.g. the operands of a conjunction may have to be cast to {@link uk.ac.man.cs.img.owl.model.Description Description} before they can be used. The issue here is in the trade-off between type-safety (providing a number of different typed collection classes) and keeping the interfaces small, easy to understand, maintain and implement.
In some cases, the collections are theoretically unordered (for example the individuals in an enumeration). For the purposes of implementation, however, it is often useful to be able to consider them as lists whose order is fixed. In user interfaces, for example, it can be disconcerting to find that the order of presentation changes unpredictably. For this reason, the collections are based on a List model.
Note also that in general, where collections are used, classes only offer get methods. Thus if a collection is to be emptied, the client needs to call the get method and then call {@link uk.ac.man.cs.img.owl.model.OWLList#removeAll removeAll}. This ensures that change event notification (see {@link uk.ac.man.cs.img.owl.model.event uk.ac.man.cs.img.owl.model.event}) works as intended.