Skip to content

Commit

Permalink
argh, forgot to add client.py -.-
Browse files Browse the repository at this point in the history
  • Loading branch information
fredreichbier committed Sep 12, 2009
1 parent af4b175 commit f0a5684
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions babbisch/client.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
class ObjectVisitor(object):
def visit_objects(self, objects):
for tag, obj in objects.iteritems():
self.visit(obj)

def generic_visit(self, obj):
pass

def visit(self, obj):
visitor_name = 'visit_%s' % obj['class']
return getattr(self, visitor_name, self.generic_visit)(obj)

0 comments on commit f0a5684

Please sign in to comment.