@Entity declares a class as an Entity or table. @table declares the Table name. @basic specifies individual fields that are unconstrained explicit. @Embedded specifies that a class or its value is an attribute of an entity of an embeddable instance of a class. An attribute of a class specified by @id, used to identify (the primary key in a table). @GeneratedValue specifies how to identify a property that can be initialized, such as automatically, manually, or from a sequence table. @transient specifies an attribute that is not persistent; that is, the value is never stored in the database. @Column specifies persistent property bar properties. @SequenceGenerator specifies the value of the property specified in the @GeneratedValue annotation. It creates a sequence. @TableGenerator specifies the value generator for the specified property in the @GeneratedValue annotation. It creates a table of generated values. An annotation of this type, @Accesstype, is used to set the AccessType. If you set @accesstype (FIELD), you can access variables directly and don't need getters and setters, but they must be public. If you set @accesstype (PROPERTY), you access the Entity's variables through getter and setter methods. @JoinColumn specifies an entity organization or collection of entities. This is used for many-to-one and one-to-many associations. UniqueConstraint The specified field and the UniqueConstraint for the primary or secondary table. @ColumnResult refers to the column name in the SQL query that uses the SELECT clause. @manytomany defines many-to-many-to-many relationships between joined tables. @ManyToOne defines a many-to-one relationship between joined tables. @OneToAny defines a one-to-many relationship between join tables. @OneToOne defines a one-to-one relationship between join tables. @namedQueries Specifies a list of NamedQueries. @NamedQuery Specifies a query with a static name

Refer to the website

https://blog.csdn.net/wujiaqi…