Re: whatToShow and attributes

Joseph Kesselman wrote:
> >The treeWalker says that whatToShow skipping takes precidence over
> > the filter. Does that include if the filter returns FILTER_REJECT?
>
> Yes. That's why we were explicit about the order in which these tests are
> applied. There were good performance reasons for doing it this way. If you
> want the other behavior you can get it by moving the node-type test into
> your filter, so this shouldn't be a problem.
>
> >Does nodeIterator or treeWalker ever step into the attributes
> >of an element? I would expect not, but the whatToShow filter has a >bit
> for attribute nodes.
>
> See the descriptive text for SHOW_ATTRIBUTE.

Doh! I thought I've fine-combed the spec but I guess I've just skimmed over
the constant definitions.

However there is actually one minor detail that is a bit incorrect. The
attribute flag is also meaningful for the treeWalker when currentNode is set
to an attribute or a decendant thereof. But this is obvious (maybe an
editorial fix would be nice).

/ Jonas Sicking

Received on Wednesday, 23 May 2001 17:40:49 UTC