• Post Reply Bookmark Topic Watch Topic
  • New Topic

Object Serialization  RSS feed

 
Satheesh Thekku Veethil
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Consider a class containing a data set in Vector. I need to store it in a file thru serialzation so i can use a writeObject. Once this is in the file, whenever the data set changes i need to update the file. However with WriteObject, everytime the whole data set is written into the file. This can become a performance issue. For example if the Vector has 1000 entries and if it has been updated by 1, then to save it in the file i will still need to write 1000 entries + 1 which i feel is an overhead.
Can anyone tell me of a workaround to boost performance?? Need your comments asap.
 
Dale DeMott
Ranch Hand
Posts: 515
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hmm.. Good question. I'm thinking if you knew exactly where the data was and it was a static length, you could write it using Random Access Files. I'm learning about file access so I can be totally off. .. hmmm Something to look into.
-Dale
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!