Class UpdateEntityAction
java.lang.Object
io.github.blyznytsiaorg.bibernate.actionqueue.impl.UpdateEntityAction
- All Implemented Interfaces:
EntityAction
Represents an entity action for updating entities in the Bibernate framework. This action is associated with
a specific entity class, a collection of entities to be updated, and a list of column snapshots representing
the changes to be applied during the update.
Upon execution, the action updates each entity in the collection using the provided column snapshots.
- Since:
- 1.0
- Author:
- Blyzhnytsia Team
-
Field Summary
Modifier and TypeFieldDescriptionprivate final BibernateSession
The Bibernate session associated with the UpdateEntityAction, providing access to the underlying data access operations and the execution context for the update action.private final List
<ColumnSnapshot> A list of column snapshots representing the changes to be applied during the update.private final Collection
<Object> A collection of entities to be updated.private final Class
<?> The Class object representing the type of entities to be updated. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
execute()
Executes the entity action by updating each entity in the collection using the provided column snapshots.Gets the type of action, which isUPDATE
.Collection
<?> Gets the collection of entities to be updated.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.github.blyznytsiaorg.bibernate.actionqueue.EntityAction
getEntityClass
-
Field Details
-
bibernateSession
The Bibernate session associated with the UpdateEntityAction, providing access to the underlying data access operations and the execution context for the update action. -
entityClass
The Class object representing the type of entities to be updated. -
entities
A collection of entities to be updated. -
diff
A list of column snapshots representing the changes to be applied during the update.
-
-
Constructor Details
-
UpdateEntityAction
public UpdateEntityAction()
-
-
Method Details
-
execute
public void execute()Executes the entity action by updating each entity in the collection using the provided column snapshots.- Specified by:
execute
in interfaceEntityAction
-
getEntities
Gets the collection of entities to be updated.- Specified by:
getEntities
in interfaceEntityAction
- Returns:
- A collection of entities associated with the update action.
-
getActionType
Gets the type of action, which isUPDATE
.- Specified by:
getActionType
in interfaceEntityAction
- Returns:
- The ActionType representing the type of entity action.
-