Delegates in python Delegates in python python python

Delegates in python


One Python tip: you don't need to say:

func = getattr(self.handler, 'Handle')func(event)

just say:

self.handler.Handle(event)

I'm not sure what you are doing with your Handler class, it isn't used in your example.

And in Python, methods with upper-case names are very very unusual, usually a result of porting some existing API with names like that.


That's the basic concept, yes - passing on some incoming request to another object to take care of.