Posts

Showing posts from January, 2018

Intercepting Filter Pattern

The presentation-tier request handling mechanism receives many different types of requests, which require varied types of processing. Some requests are simply forwarded to the appropriate handler component, while other requests must be modified, audited, or uncompressed before being further processed. One of the best example for Intercepting Filter Pattern is Spring Security's DelegatingFilterProxy , which will intercept the HTTP request and do the authentication check. Spring security build on chain of filters. Let's see how the  Intercepting Filter Pattern solve the problem with examples. This pattern is divided into a number of sections for simplicity like problem, forces, solution etc. Table of contents Problem Forces Solution Explanation Structure - Class Diagram, Sequence Diagram Participants and Responsibilities Implementation Consequences Applicability Real world examples References Read above topics on http://www.javaguides.net/2018/08/intercepting-filter-design-patt...

Front Controller Pattern

The front controller design pattern is used to provide a centralized request handling mechanism so that all requests will be handled by a single handler. This handler can do the authentication/ authorization/ logging or tracking of request and then pass the requests to corresponding handlers. Following are the entities of this type of design pattern. Table of contents Problem Forces Solution Explanation Structure - Class Diagram, Sequence Diagram Participants and Responsibilities Implementation Consequences Applicability Real world examples References Read more about Front Controller Pattern on http://www.javaguides.net/2018/08/front-controller-design-pattern-in-java.html

Data Transfer Object

Data Transfer Object Design Pattern is frequently used design pattern. It is basically used to pass data with multiple attributes in one shot from client to server, to avoid multiple calls to remote server. Table of contents Intent/Definition Problem Forces Solution Explanation Structure - Class Diagram, Sequence Diagram Implementation Consequences Applicability References Intent Pass data with multiple attributes in one shot from client to server, to avoid multiple calls to remote server. Problem Read more on http://www.javaguides.net/2018/08/data-transfer-object-design-pattern-in-java.html

Data Access Object

The object provides an abstract interface to some type of database or another persistence mechanism. Let's discuss how DAO encapsulates data access and manipulation in a separate layer.  It is hard to understand this pattern so my suggestion is to go to  source code section  and have a look at code step by step gives you more clarity.  This pattern is divided into a number of sections for simplicity like problem, forces, solution, implementation etc. Table of contents Problem Forces Solution Structure - Class Diagram, Sequence Diagram Participants and Responsibilities Implementation Consequences Applicability References Problem (Problem section describes the design issues faced by the developer) You want to encapsulate data access and manipulation in a separate layer. Read more on http://www.javaguides.net/2018/08/data-access-object-pattern-in-java.html

Object Oriented Design Principles

Object-Oriented Design Principles Encapsulate What Varies Code to an Interface Rather Than to an Implementation Delegation Principle The Open Closed Principle (OCP) Dry- Don't Repeat Yourself Single Responsibility Principle (SRP) Liskov's Substitution Principle (LSP) Interface Segregation Principle (ISP) Dependency Injection or Inversion Principle Learn these  Object Oriented Design Principles in depth  on : http://www.javaguides.net/2018/08/object-oriented-design-principles-in-java.html Related Posts Open Closed Principle Single Responsibility Principle Interface Segregation Principle Dependency Inversion Principle Liskov's Substitution Principle