Submitted by heartin on Wed, 09/11/2013 - 11:27
Here we will discuss most commonly used basic annotations in hibernate - @Entity, @Table, @Id, @GeneratedValue, @Basic, @Transient, @Temporal and @Lob.
@Entity
@Entity annotation (javax.persistence.Entity) over the class tell hibernate to treat this class as our entity class that needs to be saved.
Submitted by heartin on Wed, 09/11/2013 - 11:09
Here we will see all the CRUD operations, and also object states and transitions in hibernate. CRUD operations are Create(save), Read(select), Update(update) and Delete(delete). We will see object states in hibernate such a new/transient, attached/persistent and detached.
Submitted by heartin on Wed, 09/11/2013 - 10:31
We will write a simple hibernate application to get started with hibernate.
Before starting, you should:
Submitted by heartin on Mon, 09/09/2013 - 07:19
Inversion of control (IoC) is an object oriented programming technique in which object coupling is bound at run time by an assembler object and is typically not known at compile time. This binding process is usually achieved through dependency injection. You can achieve this by designing to interfaces. Read more @ www.javajee.com/inversion-of-control-and-dependency-injection.
Submitted by heartin on Thu, 08/29/2013 - 08:06
Hibernate provide Criteria Queries as an object-oriented alternative to HQL. Criteria Query is used to modify the objects and provide restriction for the objects. Many complex queries in HQL or even SQL may become larger over a period of time and spread over many lines; and will be difficult to update and maintain. We have already seen HQL in www.javajee.com/introduction-to-hibernate-query-language-hql.
Pages