Skip to Main Content
Design Patterns and Best Practices in Java
book

Design Patterns and Best Practices in Java

by Kamalmeet Singh, Adrian Ianculescu, Lucian-Paul Torje
June 2018
Intermediate to advanced content levelIntermediate to advanced
280 pages
7h 46m
English
Packt Publishing
Content preview from Design Patterns and Best Practices in Java

Layered architecture with an example

To understand the layered architecture style further, let's take a look at the code and design example. Let's take a very simple requirement, where we need to get a list of employees from a database.

First of all, let's try to visualize the requirement in terms of layers by looking at this diagram:

We have created four layers, in this case. The presentation layer can be thought of as a simple HTML with JavaScript. You may want to use sophisticated frameworks, such as ReactJS or AngularJS, to keep things organized at the presentation layer, but in this example we have a simple presentation layer, where, ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Practical Design Patterns for Java Developers

Practical Design Patterns for Java Developers

Miroslav Wengner
Java Design Patterns

Java Design Patterns

Vaskaran Sarcar

Publisher Resources

ISBN: 9781786463593Supplemental Content