Three states of objects in hibernate
1) Instantaneous state
There is no data in the database that matches it
Not included in the session management, complete the direct destruction
2) Persistent State
There is data in the database that matches it
Included in session management
When cleaning up the cache (Dirty data detection) is always in the database
Consistent Data Retention
3) Managed Status
There is data in the database that matches it
Not included in session management
Summary: Hibernate does the Save or update operation, usually based on the object
State to operate, enterprise development is generally used saveorupdate to replace
Save or Update method
650) this.width=650; "Src=" http://images.cnitblog.com/blog/432441/201310/21101906- B68babbf49d34e1aac6599fd2a9d97ae.jpg "width=" 594 "height=" 315 "alt=" 21101906-b68babbf49d34e1aac6599fd2a9d97a "/ >
360.doc
Several states of Hibernate