proxy pattern protection proxy many programs have different user roles with different levels of access by placing proxy between the target object and the client objectyou can restrict access to information and methods on the target object parting shots you saw how proxy could take many formsfrom the cache proxy we dealt with in this to the network connection whenever we want to control how an object or resource is accessed in way that is transparent from the client' perspectivethe proxy pattern should be considered in this you saw how the proxy pattern wraps other objects and alters the way they execute in way that is invisible to the user of these functionssince they still take the same parameters as input and returns the same results as output the proxy pattern typically has three partsthe client that requires access to some object the object the client wants to access the proxy that controls access to the object the client instantiates the proxy and makes calls to the proxy as if it were the object itself because python is dynamically typedwe are not concerned with defining some common interface or abstract classsince we are only required to provide the same attributes as the target object in order for the proxy to be treated exactly like the target object by the client code it is helpful to think about proxies in terms we are already familiar withlike web proxy once connected to the proxyyouthe clientare not aware of the proxyyou can access the internet and other network resources as if there were no proxy this is the key differentiator between the proxy pattern and the adapter pattern with the proxy patternyou want the interface to remain constantwith some actions taking place in the background converselythe adapter pattern is targeted at changing the interface