• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Questions on the Data File

 
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I have the following questions on the Data File provided and the instructions given:

1. The instructions say:
"All numeric values are stored in the header information use the formats of the DataInputStream and DataOutputStream classes".

I am assuming here it is just for our information and not really meant to read the data using the DataInputStream Class. I am planning to use RandomFileAccess class to read the file. Please let me know if my understanding is not correct

2. Magic Cookie Value:
Is it ok to store the Magic cookie value in some properties file and use it to validate the value stored in the data file to match file. Or is there any other suggested way to validate this value? Or do you think we don't need to worry about it?

Thank you for your help.

Thanks
Ravi
 
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
YOu got it...
 
Ravikiran Vishnuvajhala
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks a lot Tim for your confirmation.
[ March 13, 2007: Message edited by: Ravikiran Vishnuvajhala ]
 
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
1. Yep, you can use RandomFileAccess.
2. I ignored the magic cookie... think it's okay to ignore it as long as you explain why in your choices.txt
reply
    Bookmark Topic Watch Topic
  • New Topic