But NodeCreateRule *assumes* that if localname is non-null then namespace
parsing is enabled and it should therefore generate DOM2 nodes. Clearly Xerces
doesn't provide localname, so parsing with namespace-aware=false results in DOM1
However it seems that Aelfred provides localname even when namespace-aware is
false. And the specs say this is allowed.
So question: should we generate DOM1 or DOM2 nodes when parsing with Aelfred and
namespace-aware false? We do have the information available to generate DOM2
nodes (I think). But this would be inconsistent with the behaviour of other
parsers, so I think that we should generate DOM1 *always* when namespace-aware
So I believe that this qualifies as a bug in NodeCreateRule.
Jack, I've attached a patch. Could you try this with Aelfred and see what happens?
Note: there is *potentially* a change in behaviour (ie breaks existing code). I
don't think it does, but I would appreciate a review of this code by someone
before I commit it to Digester.