bob mcwhirter writes:

 > we added 
 > 
 >      Object getDocument(String url);
 > 
 > Right not part of core XPath functions, but darn useful.

Any recommendations on how to handle this for W3C DOM level 2?  Given
an arbitrary DOM context node, I have no way of determining how to
build a new object tree -- DOM has no getNewDocument() method, and
at level 2, there's still no general factory interface.  Here are the
options as I see it:

1. Throw an exception and give up.

2. Require Xerces to be available and use it to make the new document,
   no matter what DOM library the caller was originally using for the
   context node.

3. Create a new DOMFactory interface, and allow the caller to pass an
   implementation of it to the DocumentNavigator.

Personally, I prefer #3, perhaps with a default to #1 or #2
(preferences?) if the caller hasn't supplied a factory.


All the best,


David

-- 
David Megginson
[EMAIL PROTECTED]


_______________________________________________
Jaxen-interest mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jaxen-interest

Reply via email to