File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

lock & read or just read?

 
Alex Sharkoff
Ranch Hand
Posts: 209
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

My assignment has the following comment on the lock(int) method: Locks a record so that it can only be updated or deleted by this client.. So what I am thinking is to only use the physical locking (ie locking on the database file) when reading a record. An additional record locking (along with physical locking) will be only used when updating/deleting a record.

DBClient class



Data class:


Do you think it is an appropriate approach to the read method?


[ December 08, 2005: Message edited by: Alex Sharkoff ]
 
Andrew Monkhouse
author and jackaroo
Marshal Commander
Pie
Posts: 11833
181
C++ Firefox Browser IntelliJ IDE Java Mac Oracle
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Alex,

I think that is suitable for the read method.

Regards, Andrew
 
Alex Sharkoff
Ranch Hand
Posts: 209
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks a lot, Andrew.

 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic