java-logo

Serialization in Java

Java provides a mechanism called Serialization nothing but conevrting Java object as a stream of bytes which includes the object’s data as well as information about the object’s type and the types of data stored in the object. By using Serialization mechanism we can persist the object state in file or DB,the reverse mechanism i.e reading […]

hibernate1

Hibernate Persistence/Entity object life cycle

Persistence Object has three life cycle states 1. Transient state 2. Persistent state 3. Detached state Transient state: Object is neither associated with Session nor present in Database. Persistent state: Object is associated with Session and also present in Database. Detached state: Object is not associated with Session, but present in Database. Transient state Example: EMPLOYEE table Application […]