7from .proxy_class
import Proxy_Classes_Container
28 print(
"Proxy Exercise")
30 print(
" Getting proxy object...")
31 proxyObject = Proxy_Classes_Container.CreateProxy()
33 print(
" Calling Dowork() on proxy...")
34 output = proxyObject.DoWork(
"Initial call")
35 print(
" Output from proxy = \"{0}\"".format(output))
37 print(
" Calling Dowork() on proxy...")
38 output = proxyObject.DoWork(
"Second call")
39 print(
" Output from proxy = \"{0}\"".format(output))
41 print(
" Calling Dowork() on proxy...")
42 output = proxyObject.DoWork(
"Third call");
43 print(
" Output from proxy = \"{0}\"".format(output))
def Proxy_Exercise()
Example of using the Proxy Pattern.