Kevin,
Ah, as usual keeping consistent design when adding new features is quiet
an effort. So how about a small checklist of rules:
* We want to use JDOM internally for various XML operations, but exposing
too much JDOM in public Cayenne API is undesirable.
* Cayenne runtime should be able to operate without jdom.jar (at least for
now).
* XMLEncoding API (and the Modeler) are allowed to have JDOM dependencies.
XMLEncoder:
I agree, switching XMLEncoder to JDOM is a good thing (going from "object
-> XML stream" behavior to "object -> JDOM tree -> XML stream". So I'd say
just keep the old API (we can deprecate it later, once cayenne.map package
is switched to JDOM for encoding), and add a "root" and "current" JDOM
Element properties (and corresponding getter/setter methods), and maybe
also "printTo(PrintWriter)".
XMLSerializable:
XMLSerializable should not include JDOM classes in the method signature,
but the implementation can retrieve Elements from the XMLEncoder
internally.
DataObject and XMLSerializable:
I agree with your suggestion. So how about CayenneDataObject class will
implement XMLSerializable, but DataObject interface will not.
Does it make sense?
Andrus
This archive was generated by hypermail 2.0.0 : Fri Dec 10 2004 - 14:04:57 EST