@MappedSuperclass public abstract class PanacheEntity extends PanacheEntityBase
Represents an entity with a generated ID field id
of type Long
. If your
Hibernate entities extend this class they gain the ID field and auto-generated accessors
to all their public fields (unless annotated with Transient
), as well as all
the useful methods from PanacheEntityBase
.
If you want a custom ID type or strategy, you can directly extend PanacheEntityBase
instead, and write your own ID field. You will still get auto-generated accessors and
all the useful methods.
PanacheEntityBase
Constructor and Description |
---|
PanacheEntity() |
Modifier and Type | Method and Description |
---|---|
String |
toString() |
count, count, count, count, delete, delete, delete, delete, deleteAll, deleteById, find, find, find, find, find, find, findAll, findAll, findById, findById, findByIdOptional, findByIdOptional, flush, getEntityManager, isPersistent, list, list, list, list, list, list, listAll, listAll, persist, persist, persist, persist, persistAndFlush, stream, stream, stream, stream, stream, stream, streamAll, streamAll, update, update, update
public Long id
PanacheEntityBase.persist()
Copyright © 2021 JBoss by Red Hat. All rights reserved.