[libxml++] Re: [Libxmlplusplus-general] Adding STL-container-like methods to Node instead of returning a container instance



On Thu, 2003-02-06 at 18:31, Stefan Seefeld wrote:
> Murray Cumming wrote:
> > If it's absolutely necessary then maybe we could consider an auxillary
> > object, just to separate that part of the API.
> > 
> > For instance,
> > 
> > NodeChildren& nodeChildren = node.children();
> > for(NodeChildren::iterator iter = nodeChildren.begin(), iter !=
> > nodeChildren.end(); ++iter)
> > {
> >    ...
> > }
> 
> Well, it's this temporary object creation which I tried to avoid.

No, it's more of a proxy. It would have a pointer to the Node rather
than a snapshot of the Node's data structure at the time that children()
was called.

-- 
Murray Cumming
murray usa net
www.murrayc.com





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]