Code Monkey home page Code Monkey logo

blogs's People

Contributors

amnesialambs avatar

Watchers

 avatar  avatar

blogs's Issues

java 代理模式

代理模式的定义:为一个对象(实例)找一个或多个替身或占位符,通过操作这些替身或占位符,来对这个对象进行控制

代理模式用来创建代表对象,通过控制代表对象达到控制真实对象的目的,比如如果想对真实对象进行安全性的补充,可以不修改真实对象,创建一个安全代表对象,对这个安全代表对象无论怎么改都不会影响到真实对象的代码。
代表对象本质还是去调用真实对象,只是一些特有的东西全部写在代表对象里,代表对象对数据进行一系列处理后再调用真实对象。

几种代理控制访问的方式:

                                        1.远程代理控制访问远程对象
                                        2.虚拟代理控制访问创建开销大的资源
                                        3.保护代理基于权限控制对资源的访问

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.