Hitachi

uCosminexus Application Server Compatibility Guide


8.4.1 Methods provided with EntityManager

The EntityManager provides methods. The typical methods are as follows:

The entity objects searched using the find method from EntityManager and the entity objects passed to EntityManager using the persist method are managed by EntityManager. If a field value of an entity object managed by EntityManager is changed, EntityManager automatically detects the change and applies the change to the database table.

With the JPA, an entity object managed by EntityManager is called a managed entity. By default, when a transaction is concluded, the entity is no longer managed by EntityManager. An entity that is no longer managed by EntityManager is called a detached entity.