Provides the ODMG 3.0 API ({@link org.odmg}) of ozone. In fact, this is an
ODMG-like interface that tries to follow the ODMG design as far as possible.
However, some of the assumptions of ODMG are simply not true for ozone.
Especially the {@link org.odmg.Database#makePersistent} method cannot be
implemented on top of ozone. This is due the use of proxy objects in ozone.
ODMG ist not aware of such an architecture and it does not support it. Also
the need to subclass database classes from {@link OzoneObject} or implement
the {@link OzoneCompatible} interface is not ODMG compliant.
In other words: It is not possible to use ozone as an out-of-the-box
replacement for another ODMG database without code changes. (I'm in doubt if
this is possible with any combination of different ODMG implementations) But
you will find the ODMG object and programming model in the ozone ODMG
interface, which makes it easier to start with ozone if you are familiar with
ODMG.
If you really need to keep your client code independent of ozone, we suggest
to make a wrapper that hides the actual ODMG implementation classes from the
client code. This wrapper should provide an explicit notion for creating
objects, like the {@link OzoneODMGDatabase}. The database dependent
implementation of the wrapper can decide how to actual create objects and
handle other database specific things.
See also the samples included in the ozone distribution to learn how to
program against the ozone ODMG API.
ODMG collections
The ozone implementations of the ODMG colllections are simple wrapper to the
Java2 collections yet. That means each collection is stored as one database
object. This architecture does not scale well. Future implementation have to
improve this by distributing one collection over several database objects if
necessery.
|