About detached

release

2.0.4

... Fixed a bug in modifying enhanced detached embedded objects. Fixed a spring transformer ...

 
issue

Read only hint for query

Second thing after @FetchGroup I've found is read-only hint for EM. You can specify this hint to EM when executing query meaning that returned data will never be edited or persisted. My understanding of this is that each entity returned from query is in detached state as default state. query.setHint("odb.read-only", "true"); This could be useful in situation when you are sure, that you won't modify those entities - like listing entities, paging, logging, reporting. ... of this is that each entity returned from query is in detached state as default state. query. setHint ( ...

 
manual

Deleting JPA Entity Objects

Explains how to use JPA to delete (remove) entity objects from the database.... is not a an instance of an entity class or if it is a detached entity. A TransactionRequiredException ...

 
api-jpa

remove(entity)

Remove the entity instance.(Method of javax.persistence.EntityManager)

 
api-jdo

jdoPreAttach()

This method is called during the execution of javax.jdo.PersistenceManager.makePersistent on the detached instance before the copy is made.(Method of javax.jdo.listener.AttachCallback)

 
api-jdo

getDetachmentOptions()

Get options used during detachment.(Method of javax.jdo.FetchPlan)

 
api-jdo

getSource()

The source object of the Event.(Method of javax.jdo.listener.InstanceLifecycleEvent)

 
api-jdo

setDetachmentRoots(roots)

Set the roots for DetachAllOnCommit.(Method of javax.jdo.FetchPlan)

 
api-jpa

lock(entity, lockMode)

Lock an entity instance that is contained in the persistence context with the specified lock mode type.(Method of javax.persistence.EntityManager)

 
api-jdo

getDetachmentRootClasses()

Get the root classes for DetachAllOnCommit.(Method of javax.jdo.FetchPlan)