9c9
< //#include <fstream>
---
> #include <strstream> // ostringstream
11d10
< #include "FssimApp.h"
14c13
< using namespace std;
---
> #include "DataNotFoundException.h"
16,19c15,16
<     class Zone
<     {
<     public:
<         enum { LABEL_SIZE = FssimApp::MAX_LABEL_LENGTH };
---
> #include "ZoneStruct.h" // TargetStruct, etc.
> #include "AUStruct.h"
21,23c18
< 	    // constructor
< 	    Zone(ZONE* pZoneStruct = 0) : m_pStruct(pZoneStruct) { }
< 	    virtual ~Zone(); // destructor
---
> using namespace std;
25,26d19
<         void serialize( Serializer& binaryArchive ); //throw (FileException);
<         static void serializeZoneList(Serializer& binaryArchive);
28,29c21,26
<         bool hasAUs() { return (0 != m_pStruct->aulist); }
<         bool hasAXSDEFs() { return (0 != m_pStruct->axslist); }
---
> class Zone
> {
> public:
>     // constructor
>     Zone(ZoneStruct* pZoneStruct = 0) : m_pStruct(pZoneStruct) { }
>     virtual ~Zone() {} // destructor
31c28,29
<         ZONE* getStruct() { return m_pStruct; }
---
>     void serialize( Serializer& binaryArchive ); //throw (FileException);
>     static void serializeZoneList(Serializer& binaryArchive);
33,36c31,32
<         static Zone* lookupZoneAddress(int id)
<         {
<             return m_objectMemoryAddresses[id];
<         }
---
>     bool hasAUs() { return !(m_pStruct->aulist.empty()); }
>     bool hasAXSDEFs() { return !(m_pStruct->axslist.empty()); }
38,41c34
<         AU* lookupAUAddress(int id)
<         {
<             return m_aulistStructMemoryAddresses[id];
<         }
---
>     ZoneStruct* getStruct() { return m_pStruct; }
43,46c36,40
<         void appendAUAddressToVector(AU* pAU)
<         {
<             m_aulistStructMemoryAddresses.push_back(pAU);
<         }
---
> private: // utility functions
>     // zone has custody of its AXSDEFs
>     void serializeAxsList(Serializer& binaryArchive);
>     // zone has custody of its AUs
>     void serializeAuList(Serializer& binaryArchive);
48,52c42
<     private: // utility functions
<         // zone has custody of its AXSDEFs
<         void serializeAxsList(Serializer& binaryArchive);
<         // zone has custody of its AUs
<         void serializeAuList(Serializer& binaryArchive);
---
>     void serializeIDList(Serializer& binaryArchive, list<int>& idList);
54c44
<         void serializeIDList(Serializer& binaryArchive, list<int>& idList);
---
>     void recreateStruct(char* label, int id);
56c46,48
<         void recreateStruct(char* label, int id);
---
> private:
>     ZoneStruct* m_pStruct;
>     // id and label are serialized through m_pStruct
58c50
<         //void createAUIndexList();
---
>     // area and m_auCount are not serialized
60,63c52
<         //static int lookupZoneID(const string& label);
<     private:
< 	    ZONE* m_pStruct;
< 	    // id, label, area, and LastAUID are serialized through m_pStruct
---
>     // priority, target, and reportFlags are not serialized (always read from file)
65c54,55
<         // priority, target, and reportFlags are not serialized (always read from file)
---
>     // achieved struct has default values and is
>     // therefore not serialized, but must be re-allocated on read
67,68c57,59
<         // achieved struct has default values and is
<         // therefore not serialized, but must be re-allocated on read
---
>     // a zone owns its AxsDefs and has custody of them through Zone::serializeAxsList
>     // a zone owns its AUs and has custody of them through Zone::serializeAUList
> };
70,81d60
<         //list<int> m_AUIndices;
< 
<         // a zone owns its AxsDefs and has custody of them through Zone::serializeAxsList
< 
< 	    //static map<string, int> m_labelIndex;
< 	    //typedef map<string, int>::iterator AIndexIterator;
<         //typedef map<string, int>::const_iterator AConstIndexIterator;
< 
<         vector<AU*> m_aulistStructMemoryAddresses;
<         static vector<Zone*> m_objectMemoryAddresses;
<     };
< 
