Solved

Serializing SDI document data into two parts.

Posted on 2004-08-08
1
265 Views
Last Modified: 2013-11-20
Hi,

I am working on a SDI application. My CDocument derived class holds a linked list of pointers to CObject derived objects which contains other linked lists of CObject derived objects. The first linked list contains data that almost never changes. The other linked lists  are much more variable.
Is it possible to serialize this document data into two parts for an SDI application. Lets say the more static data in a file with extension .ext1 and the more variable data in a file with extension .ext2. Is this good programming design and if it is, how presisely could this be achieved ?
0
Comment
Question by:bs161900
1 Comment
 
LVL 55

Accepted Solution

by:
Jaime Olivares earned 100 total points
ID: 11746569
>Is it possible to serialize this document data into two parts for an SDI application. Lets say the more static data in a file with
> extension .ext1 and the more variable data in a file with extension .ext2. Is this good programming design and if it is, how
> presisely could this be achieved ?
Yes, sure you can do it and could be a good programming practice if the case is proper.
By example, you can open a file with some extension, let say (.map, a city map), but as you create interest points, you can save them in a separate file (.ipt) because you don't want or you can't alter map file.
To achieve that, you have to build your own serialization functions (CDocument::Serialize is not the unique way). Also you can trap the OnNewDocument(), OnOpenDocument(), OnSaveDocument() and OnCloseDocument() document's events you manage serialization as you desire (even can not store in a standard file but in a database, or update a portion of an existing file).

0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
wait notify demo infinite loop 3 134
withoutTen challenge 14 137
Making an alias 7 110
moto 4g phone enable finger print 4 42
Introduction: Ownerdraw of the grid button.  A singleton class implentation and usage. Continuing from the fifth article about sudoku.   Open the project in visual studio. Go to the class view – CGridButton should be visible as a class.  R…
Introduction: Hints for the grid button.  Nested classes, templated collections.  Squash that darned bug! Continuing from the sixth article about sudoku.   Open the project in visual studio. First we will finish with the SUD_SETVALUE messa…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

680 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question