This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes delete record Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "delete record " Watch "delete record " New topic
Author

delete record

Goran Borozan
Greenhorn

Joined: May 26, 2004
Posts: 14
Preparing for the URLyBird.

I implemented the create and delete methods in the Data class but
i need never to use them in the gui (book = lock-update-unlock). Is it OK ?

Is it ok to set record to be deleted like this (0x800 - deleted record )



Tanks for help

[ June 03, 2004: Message edited by: Goran Borozan ]
[ June 03, 2004: Message edited by: Goran Borozan ]

SCJP, SCJD, SCA (in progress)
Vishwa Kumba
Ranch Hand

Joined: Aug 27, 2003
Posts: 1064
1. Yes
2. May be you are right. I am not entirely sure. I guess you have split the value into 2 bytes and updating them one after the other.

I find it easy to this:
raf.writeShort(DELETED_FLAG)
Where DELETED_FLAG is a constant with value. 0x8000. This allows the constant to be changed easily in the future.
Goran Borozan
Greenhorn

Joined: May 26, 2004
Posts: 14
Tanks Vishwa !

But i have to set deleted flag by
record.setDeleted(deletedRecord);
where deletedRecord is byte[].

How can i do it with raf.writeShort(.. ?

/Goran
Goran Borozan
Greenhorn

Joined: May 26, 2004
Posts: 14
Tanks Vishwa !

But i have to set deleted flag by
record.setDeleted(deletedRecord);
where deletedRecord is byte[].

How can i do it with raf.writeShort(.. ?

/Goran
Wickes Potgieter
Ranch Hand

Joined: Apr 05, 2002
Posts: 68
Apparently, you don't need to implement those methods. One of Ranchers has passed without implementing it.


Wickes Potgieter<br />SCJP<br />BEA Certified Specialist: Server, Integration, Portal, Tuxedo<br />BEA WebLogic Server 7 Certified Enterprise Developer<br />BEA Certified Architect<br /><a href="http://www.bea.com" target="_blank" rel="nofollow">www.bea.com</a>
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: delete record
 
Similar Threads
want to Take SCJD
delete method
nx: All of URLy Bird 1.1.3 read/write lock(2)
Passed java developer certification
How to write back an updated record to db file?