• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Creation of binary file

 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It might be very basic question. Please help me. How to create a binary file??
So far my understanding is, an object obj if we write in a file with writeObject method using ObjectOutputStream class then that file is called a binary file.
Is this correct??? Please help me.
Thanks in advance,
Rajini

 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Rajini wrote:
It might be very basic question. Please help me. How to create a binary file??
So far my understanding is, an object obj if we write in a file with writeObject method using ObjectOutputStream class then that file is called a binary file.
Is this correct??? Please help me.

In your assingment you are supposed to create a file that represents a database. Kindly look at your Data class 2nd constructor. This will give you an idea what ur database should contain.
So to make ur database, you may use the Data class constructor to write the header details and also in turn use the Data class methods to write each record that you have read from the dataset provided as an ascii file.
Best of luck.
regards,
LioneL
 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I really appreciate your reply.
Thanks,
Rajini
 
Jayakumar Thirumalai
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Lionel,
You have said it in a very simple, easy to understand way.
I appreciate that.
Jay
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic