merge
Merges a single entity in the persistence context in a transaction.
Return
The merged entity.
Parameters
entity
The entity to merge.
Throws
If entity is a primitive type.
If an error occurs during execution.
Merges multiple entities in the persistence context in a single transaction.
Return
The list of merged entities.
Parameters
entities
List of entities to be merged.
Throws
If entities contains any primitive types.
If an error occurs during execution.