Interface PanacheManagedRepositoryOperations<Entity,Session,Completion,Confirmation,Id>
- All Known Subinterfaces:
PanacheManagedBlockingRepository<Entity>,PanacheManagedBlockingRepositoryBase<Entity,,Id> PanacheManagedBlockingRepositoryOperations<Entity,,Id> PanacheManagedReactiveRepository<Entity>,PanacheManagedReactiveRepositoryBase<Entity,,Id> PanacheManagedReactiveRepositoryOperations<Entity,,Id> PanacheRepository<Entity>,PanacheRepository.Managed<Entity,,Id> PanacheRepository.Reactive<Entity,Id>
public interface PanacheManagedRepositoryOperations<Entity,Session,Completion,Confirmation,Id>
-
Method Summary
Modifier and TypeMethodDescriptionDelete the given entity from the database, if it is already persisted.flush()Flushes all pending changes to the database using the Session for theentity class. Returns thePanacheManagedRepositoryOperationsfor theentity class for extra operations (eg. isPersistent(Entity entity) Returns true if the given entity is persistent in the database.Persist the given entity in the database, if not already persisted.Persist all given entities.Persist all given entities.Persist all given entities.persistAndFlush(Entity entity) Persist the given entity in the database, if not already persisted.
-
Method Details
-
getSession
Session getSession()Returns thePanacheManagedRepositoryOperationsfor theentity class for extra operations (eg. CriteriaQueries) - Returns:
- the
PanacheManagedRepositoryOperationsfor theentity class
-
persist
Persist the given entity in the database, if not already persisted.- Parameters:
entity- the entity to persist.- See Also:
-
persistAndFlush
Persist the given entity in the database, if not already persisted. Then flushes all pending changes to the database.- Parameters:
entity- the entity to persist.- See Also:
-
delete
Delete the given entity from the database, if it is already persisted.- Parameters:
entity- the entity to delete.- See Also:
-
isPersistent
Returns true if the given entity is persistent in the database. If yes, all modifications to its persistent fields will be automatically committed to the database at transaction commit time.- Parameters:
entity- the entity to check- Returns:
- true if the entity is persistent in the database.
-
flush
Completion flush()Flushes all pending changes to the database using the Session for theentity class. -
persist
Persist all given entities.- Parameters:
entities- the entities to persist- See Also:
-
persist
Persist all given entities.- Parameters:
entities- the entities to persist- See Also:
-
persist
Persist all given entities.- Parameters:
entities- the entities to persist- See Also:
-