Java EE PO VO BO DTO POJO DAO Finishing Summary (GO)

Source: Internet
Author: User

Read Catalogue

    • 1.dao[data Access Object] data Access objects
    • 2.dto[data Transfer Object] data transfer objects
    • 3.po[persistant Object] Persistence layer objects
    • 4.bo[bussiness Object] Business objects
    • 5.vo[value Object] Value objects
    • 4.pojo[plain ordiary Java Object] Simple Java objects

Admire the ability to be complex and difficult to understand the technology, abstract into simple and easy to understand things people.

Aversion to the easy-to-understand technology that adds a bunch of jargon to people who get dizzy.

PO VO BO DTO POJO DAO General list:

1.dao[data Access Object] data Access Objects

DAO layer to developer black box, encapsulated by architect Design.

Over a long period of time, I have understood it as a database access, followed by the accumulation of projects.

Finding their own understanding is relatively narrow, and data access is not just about accessing the database.

If a system invokes the service of system B to obtain data, then the encapsulation of a system to the access data object of System B can also be called DAO.

2.dto[data Transfer Object] data transfer Objects

Suppose there are 20 fields in the data table, but in the case of the page display list, none of the 20 fields will be used.

I want to show 5 of these fields, and these 5 fields are not what they were in the database when they were shown.

There is also a need for calculations, interception, business code transfer names ..... Wait a minute

Data transfer objects are therefore born, one is to improve the speed of data transmission, two can hide the back-end table structure.

3.po[persistant Object] Persistence layer objects

Persistent object properties and fields in the database correspond to one by one, and a data in the database can be interpreted as a persistent object.

It is introduced into the design of Java EE Project because of the wide use of ORM framework.

4.bo[bussiness Object] Business Objects

The business object, as the name implies, is an abstraction in the business process, and in addition to the Get/set method, there is a way to do business with the field.

Suppose you want to do business with a class, where students, teachers, and even chairs are part of the business object.

Of course, the students, classrooms .... can be the PO corresponding to the database.

5.vo[value Object] Value objects

A value object can also be called a Page object, and if it is called a Page object, it represents the object of the entire page presentation layer.

Conversions that can be made by the desired business object.

If he is called a value object, that door can be understood as a place to store business objects.

If pots and pans were the corresponding business objects, the whole cupboard was a value object.

4.pojo[plain ordiary Java Object] Simple Java objects

A simple Java object should be the most flexible object in the Java EE world.

In a simple system, it can be a dto if it is pojo from the database to the page display.

If it is pojo from the database to the business process, he can also be bo.

It can also be VO if it is displayed from the database to the entire page.

Summary:

The conversion between the individual data objects is quite flexible, and in the project you can define all and several types of the above objects, depending on the architect and requirements.

In a large project, the architect's task in the early stages of the project, in addition to building the entire development environment, defines the data structure objects that flow through the system as well as heavy.

This work requires the accumulation of many projects and long-term thinking of software development, more practice, more thinking, to provide the most appropriate data object solutions, to show the architect's charm.

Java EE PO VO BO DTO POJO DAO Finishing Summary (GO)

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.