RSS feed
[root]
/
c04
/
code
/
TI Python
/
scripts
/
document
statemachine
mousetrap2
mousetrap1
mouse
login:
password:
title search:
Search this site
Enter your search terms
Web
www.carfield.com.hk
Submit search form
Prev
Next
Wed Dec 26 16:00:00 GMT 2001
ProxyDemo
#: c04:ProxyDemo.py # Simple demonstration of the Proxy pattern. class Implementation: def f(self): print "Implementation.f()" def g(self): print "Implementation.g()" def h(self): print "Implementation.h()" class Proxy: def __init__(self): self.__implementation = Implementation() # Pass method calls to the implementation: def f(self): self.__implementation.f() def g(self): self.__implementation.g() def h(self): self.__implementation.h() p = Proxy() p.f(); p.g(); p.h() #:~
(google search)
(amazon search)
1
2
3
second
download zip of files only
Prev
Next