Exemplo n.º 1
0
        public ProxyPatternClient()
        {
            // The client instantiates the actual subject and the proxy (the proxy takes the actual subject via
            // constructor. The client calls the underlying proxy method DoSomething, which in turn calls the
            // actual subject method do something)
            ActualSubject realSubject = new ActualSubject();

            proxy = new Proxy(realSubject);
        }
Exemplo n.º 2
0
 public Proxy(ActualSubject actualSubject)
 {
     this._actualSubject = actualSubject;
 }