> >> fine. r4607:
> >> def traverse_using(iterator, obj, visitors):
> >> """visit the given expression structure using the given
> >> iterator of objects."""
> >
> > yeah, i how i get the ClauseVisitor to use that...
> > The idea was for the ClauseVisitor's traverse to use
> > ClauseVisitor's iterate (or _iterate), pointing by default to
> > module's plain iterate(), so inheriting and replaceing _iterate
> > with e.g. iterate_depth_first (or whatever fancy) would work,
> > without a need to reinvent the traverse mechanism at all.
> > unless u're fading out those classes for a reason or another?
>
> no theyre hanging around. Just subclass ClauseVisitor for now.
ok, i need the traverse_using(), the iterate_depth_first (which i can
do myself as u said so its not really needed), and the pre-traverse
name[6:] filtering:
visitors = dict( (name[6:], getattr(self, name))
for name in dir(self)
if name.startswith('visit_') )
u have this filtering copied twice, i guess it has to be in one place.
so the actual traverse-call has to be one more method.. to be easy
replaceable.
that should make a good clean interface.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"sqlalchemy" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/sqlalchemy?hl=en
-~----------~----~----~----~------~----~------~--~---