private EntityManager em:-Defines an Interface instance. The interface Entity manager is associated with the persistence context.
em.persist(newsEntity):-This method makes an entity instance managed and persistent.
em.merge(newsEntity):-This method merge the state of the given entity into the current persistence context.
em.remove(em.merge(newsEntity)):-By using this method we can remove the entity instance.
em.find(ejb.NewsEntity.class, id):-This methods find the entity instance by the primary key. Here primary key is id.
Rs. 20,000 US$ 300
Today: Rs. 10,000 US$150
Course Duration: 30 hrs
Posted on: January 12, 2009 If you enjoyed this post then why not add us on Google+? Add us to your Circles