hi all,
I have a question about object state.
I have a detached objet I'd like to reattach to the Session and it's persistence context.
here is the snipped code to do that.
Code:
...
Session session=sessionFactory.openSession;
Transaction tx=sessionFactory.beginTransaction();
session.lock(article,LockMode.NONE);
article.setDescription("new desc");
txcommit();
session.close();
At the end of this I assume that my article has been reassociated to the session and it's state is no more detached.
Does it means that it's state is now persistent even if I know that no database hit has been performed.
thanks in advance.
Meissa