Home  >  Article  >  Java  >  Is javabean an entity class?

Is javabean an entity class?

little bottle
little bottleOriginal
2019-05-20 17:17:495111browse

Java is an object-oriented language with convenient and simple features. JavaBean is a reusable component written in JAVA language. To be written as a JavaBean, a class must be concrete and public, and have a parameterless constructor. This article will talk to you about JavaBeans and entity classes.

Is javabean an entity class?

#Entity class: It is a class that corresponds one-to-one to the fields in the database.

And javabean: there are no restrictions on the variables inside.
Can manipulate additional fields in the data table.

It is somewhat similar to a mirror, manipulating javabeans, but does not affect entity classes.

javaBean is a special entity class.

JavaBean exposes member properties of internal fields by providing public methods that conform to consistent design patterns, and can be obtained by set and get methods. As we all know, the property names conform to this pattern, and other Java classes can discover and manipulate the properties of these JavaBeans through the introspection mechanism (reflection mechanism).

Related learning recommendations: java basic tutorial

The above is the detailed content of Is javabean an entity class?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn