Class GeneratedIdEntity<I extends Comparable<I> & Serializable>

java.lang.Object
org.omnifaces.persistence.model.BaseEntity<I>
org.omnifaces.persistence.model.GeneratedIdEntity<I>
Type Parameters:
I - The generic ID type.
All Implemented Interfaces:
Serializable, Comparable<BaseEntity<I>>, Identifiable<I>
Direct Known Subclasses:
TimestampedEntity

@MappedSuperclass public abstract class GeneratedIdEntity<I extends Comparable<I> & Serializable> extends BaseEntity<I>

Mapped superclass for entity with generated ID. It extends from BaseEntity. It specifies a Id column, named "id". JPA will automatically take care of the ID.

Author:
Bauke Scholtz
See Also:
  • Constructor Details

    • GeneratedIdEntity

      public GeneratedIdEntity()
  • Method Details

    • getId

      public I getId()
      Description copied from interface: Identifiable
      Returns the ID.
      Returns:
      The ID.
    • setId

      public void setId(I id)
      Description copied from interface: Identifiable
      Sets the ID.
      Parameters:
      id - The ID.