SlideServe
Menu
Preferences
© SlideServe · v2026

Proxy Pattern: Enhancing Object Security & Resource Management

wwaldron avatar
5 slides · 110 Views · Jan 04, 2020

Learn how Proxy pattern works by allowing objects to interact through proxies, ensuring security, resource control, and efficient access management. Proxy Types include Protection, Remote, Virtual, and Smart Reference Proxies.

Proxy Pattern: Enhancing Object Security & Resource Management - slide 1
01 / 5Proxy Pattern: Enhancing Object Security & Resource Management
1 / 17

Download Presentation

Proxy Pattern: Enhancing Object Security & Resource Management
An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

More Related Content

Presentation Transcript
  1. Proxy Pattern • Definition of “Proxy”: Authority or power to act for another • Original Gang of Four pattern, much used • Stands in for a “real object” (similar to a pointer) • Provides a public interface to the real object

  2. Proxy Services • Local interface • Access control • Resource instantiation cost reduction

  3. Types of Proxies • Protection Proxies grant or deny client access to the real subject (i.e., check permissions) • Remote Proxies are a local representation of a real subject in a different host (e.g., RMI) • Virtual Proxies represent expensive objects, such as images (e.g., replies to getHeight()) • Smart Reference Proxies can count number of times referenced, act as lock or semaphore

  4. Abstract Class Interaction Subject Client Request () ...() Generalization RealSubject Proxy Request () Request () ...() ...() realSubject Aggregation Proxy UML Representation

  5. Code Example private void init() { imgProxy = new ImageProxy (); } //Do stuff to image public ImageManipulation1() { InitializeComponent(); init(); } //Then instantiate image private initiate(object, args) { Real.Image = imgProxy.getImage (); }