Skip to Content.
Sympa Menu

xom-interest - Re: [XOM-interest] checkDetach vs. checkRemoveChild

xom-interest AT lists.ibiblio.org

Subject: XOM API for Processing XML with Java

List archive

Chronological Thread  
  • From: Elliotte Rusty Harold <elharo AT metalab.unc.edu>
  • To: John Cowan <cowan AT ccil.org>
  • Cc: xom-interest AT lists.ibiblio.org
  • Subject: Re: [XOM-interest] checkDetach vs. checkRemoveChild
  • Date: Wed, 10 Mar 2004 04:28:58 -0500

At 11:38 PM -0500 3/9/04, John Cowan wrote:
Elliotte Rusty Harold scripsit:

Is it that you'd like an HTMLElement
that could only be a child of an HTMLElement or an HTMLDocument, but
could not be a child of a generic Document or Element?

Exactly.


OK. I see what you're trying to do. How badly do you need to do this? And are you sure you want to do this? For instance, would your system be designed to handle pages of mixed HTML, SVG, and MathML? Would it handle HTML embedded in other applications? Would it handle well-formed but invalid pages like http://www.cafeaulait.org/ that deliberately use non-standard elements such as "today"? Writing a checkAttach method that only let html elements be attached to other html elements, would prevent all this; but maybe that's what you want to do.

The proposal is two extra methods, which I don't like; but they're protected which ameliorates the impact somewhat. Possibly I could leave them to 1.1. However, they're not hard to add now. I'm just a little worried that I might add them and no one will use them. If you say, yes, you definitely want to use them and need them now, then I'm leaning toward adding them. They shouldn't get in anybody's way. However, if you're not quite sure yet, I'd prefer to leave them until someone definitely needs them.
--

Elliotte Rusty Harold
elharo AT metalab.unc.edu
Effective XML (Addison-Wesley, 2003)
http://www.cafeconleche.org/books/effectivexml
http://www.amazon.com/exec/obidos/ISBN%3D0321150406/ref%3Dnosim/cafeaulaitA




Archive powered by MHonArc 2.6.24.

Top of Page