Entity is the persistence (POJO) objects that represent one record in the table. The Entity is simple annoted POJO class, which is easy to develop. Here are the characteristics of an Entity:
See Entity in JPA.
- Entity can be persisted to the relational database
- Entity is identified by persistence identity (the primary key of the table)
- Entity supports transactions
- Entity supports inheritance
class MobileEntity{
private String model;
private String manufacturer;
private Double price;
private String imeiNo;
…..
// Getters and Setters go here.
}
No comments:
Post a Comment