hello saheed,
what is your problem? maybe it's easier if you post some pseudo-code, and others can help you with it...
if
you should be concerned about locking / unlocking - you can assume that this is done outside of the update() method.
looking forward to help you,
jan