Object Serialization and File Pointer Handling.
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Sudhakar_Santhanam
Posted On:   Tuesday, May 7, 2002 11:34 PM

I would like to write serialized objects to a file.The file is split into three parts.The first part of the file would locate a global pointer to an object (which holds a key-pair values of serialized objects and their corresponding offsets) written at the end of the file.The offset is actually a long value computed from the size of the serialized objects.In addition the global offset poiinter would be succeeded by an encrypted key for security authentication. The second part of the file would contain the actual objects which are serialized and holds encrypted values in them.The object would be preceded by an offset pointer to be located at runtime. The third part of the file is a key-value pair which locates the actual object wi   More>>

I would like to write serialized objects to a file.The file is split into three parts.The first part of the file would locate a global pointer to an object (which holds a key-pair values of serialized objects and their corresponding offsets) written at the end of the file.The offset is actually a long value computed from the size of the serialized objects.In addition the global offset poiinter would be succeeded by an encrypted key for security authentication.

The second part of the file would contain the actual objects which are serialized and holds encrypted values in them.The object would be preceded by an offset pointer to be located at runtime.

The third part of the file is a key-value pair which locates the actual object with the key as objects offset.
The idea behind this is to randomly move thru the file and locate the object once the objects offset is read from the global key-value pair.I know RandomAccessFile only allows random access to a file but I would not be able to write out serialized objects using it.I would like to use ObjectInput and ObjectOutput Stream classes but then I would have to read the objects in the way I had written which may be time consuming to locate a particular object.


Is there any possiblity of achieving this?? OR is there a better way of achieving this.


YOur suggestions would be of immense help to me....


Thanks

SudhakarSanthanam

sudhakarsanthanam@rediffmail.com
   <<Less
About | Sitemap | Contact