| [ Web Proxy ] |
| Viewing: https://raw.githubusercontent.com/dreamsql/python-patterns/master/chain.py | [Back] [Original] |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""http://www.testingperspective.com/wiki/doku.php/collaboration/chetan/designpatternsinpython/chain-of-responsibilitypattern"""
class Handler:
def successor(self, successor):
self.successor = successor
class ConcreteHandler1(Handler):
def handle(self, request):
if 0 < request
| Web Proxy Viewer | New URL | Original Page |