Sie sind auf Seite 1von 3

hibernate syllabus

-----------------------
1)formats in which we can store data(fixed with fieldsize, text, comma seperated
values, xml, relational)

2)types of databases

3)about jpa(implementations)

4)hibernate advantages and disadvantages over jdbc

5)normalization

6)class relationship
-INHERITENCE
-ASSOCIATION
-AGGREGATION
-COMPOSITION
-DEPENDENCY

7)TABLE RELATIONS
-ONE TO ONE
-ONE TO MANY
-MANY TO ONE
-MANY TO MANY

8)first hibernate

9)hbm2ddl.auto

10)bootstraping
-legacly
-modern(service registery)

11)methods
-save
-update
-persist
-save or update
-flush
-commit
-save
-merge

12)entity bean lifecycyle


-transient
-persisted
-detached

13) contextual session

14)id generators(10 id generators)

15)MAPPINGS
-INHERITENCE(table per class hirachy, table per sub class, table per concrete
class);

-ASSOCIATION
-many to one represented as one-one
-one-one
-AGGREGATION
-DEPENDENCY
-COMPONENT(COMPOSITION)

16)inverse(it is used when see in example)

-----------------------------------------------------------------------------------
--------
public cellphone{

int modelno;
int type;
list<manufacturer> Manufacturer;

//setters&getters
}

public Mnufacturers{

public in mfid;
public string mfname;

---if we update cellphone table the hibernate will also updaes the list of
manufacturers
---to eliminate that we use inverse in manufacturer mapping at table level so it
updates when only a child record had been updated
not all the times when we update parent table cellphone

-----------------------------------------------------------------------------------
--------------------------------

17)Component mapping
-----------------------------------------------------------------------------------
--------------------------------
public cellphone{

int model id;


int modelno;
int type;

@Emabadded
Manufacturer manufacturer;

//setters&getters
}

@Embedable
public Mnufacturers{

public int mfarea;


public string mfname;
}

table-:cellphone

id:

model_id:

model_no:

type:

mf_area:

mfname:

-if we have a single table divided in to two classes for reusability the child
class will not have primary key in such conditions
to say hibernate to create only one table for both child and parent table we use
(component mapping).

-----------------------------------------------------------------------------------
--------------------------
18)hql quiries

19)criteria api

20)named quries

21)secondlevel cache

22)transactions