[jdom-interest] BUG: No attributes in new Elements
jhunter at acm.org
Wed Feb 7 12:17:11 PST 2001
Peter Franken wrote:
> If I create a new Element, the attributes from the DTD
> aren't added. (I cannot find any of the attributes defined in the DTD-file)
Default attributes from a DTD aren't added when you construct an
Element, nor is that a feasible feature to implement in my opinion.
Elements may exist separate from a document and be moved within a
document, which means your proposal would have attributes automatically
added or removed depending on element position.
The model is that JDOM ensures documents are well-formed at runtime, and
will (sometime in the future) allow validity to be checked on request.
More information about the jdom-interest