6,8c6
< //#include <list>
< //#include <map>
< //#include <fstream>
---
> #include <iostream>
11a10,11
> 
> #include "TimberClassStruct.h"
12a13,14
> #include "BlockStruct.h"
> #include "AUStruct.h"
21d22
<     enum { LABEL_SIZE = FssimApp::MAX_LABEL_LENGTH };
22a24
> 
24,26c26,28
<     TimberClass(TIMBER_CLASS* pTimberClassStruct = 0,
<                 Zone* pParentZone = 0, BLOCK* pParentBlock = 0,
<                 AU* pParentAu = 0/*, Zone* pZoneOfParentAu = 0*/)
---
>     TimberClass(Zone* pParentZone, AUStruct* pParentAu,
>                 TimberClassStruct* pTimberClassStruct = 0,
>                 BlockStruct* pParentBlock = 0 )
28,29c30,31
<           m_pParentAU(pParentAu), // m_pZoneOfParentAU(pZoneOfParentAu),
<           m_pParentBLOCK(pParentBlock), m_index(++m_timberClassCount)
---
>           m_pParentAU(pParentAu), m_pParentBlock(pParentBlock),
>           m_index(++m_timberClassCount)
34c36
<             /*if(0 != m_pStruct->parent_zone && 0 == m_pParentZone)
---
>             if (0 != m_pStruct->parent_au && 0 == m_pParentAU)
36,39d37
<                 m_pParentZone = m_pStruct->parent_zone;
<             }*/
<             if(0 != m_pStruct->parent_au && 0 == m_pParentAU)
<             {
42c40
<             if(0 != m_pStruct->parent_block && 0 == m_pParentBLOCK)
---
>             if (0 != m_pStruct->parent_block && 0 == m_pParentBlock)
44c42
<                 m_pParentBLOCK = m_pStruct->parent_block;
---
>                 m_pParentBlock = m_pStruct->parent_block;
46a45,47
> #ifdef _TSB_AGE_DEBUG
>         cout << endl << "constructed timber class with parent_au: " << m_pParentAU->label << endl;
> #endif
53,60d53
<     // static & float groups are not serialized,
<     // since they are populated within the simulation loop
<     //bool hasStaticGroups() { return (0 != m_pStruct->static_group_list); }
<     //bool hasFloatGroups() { return (0 != m_pStruct->float_group_list); }
< 
<     //void createFloatGroupIndexList();
<     //void createStaticGroupIndexList();
< 
62c55,56
<     TIMBER_CLASS* getStruct() { return m_pStruct; }
---
>     TimberClassStruct* getStruct() { return m_pStruct; }
> 
64c58,60
<     //void serializeIDList(Serializer& binaryArchive, list<int>& idList);
---
>     void recreateStruct( const int age, const int width, const double area, const int classType,
>                          const int reversionAge, const int reEntryLag,
>                          const bool roaded, const int randomValue );
66,71d61
<     void recreateStruct(int age, int width, double area, int class_type,
<                         int reversion_age, int ReEntryLag,
<                         LIST_PTR *float_group_list, LIST_PTR *static_group_list,
<                         int roaded, int RandValue);
< 
<     //static int lookupTimberClassID(const string& label);
73c63
<     TIMBER_CLASS* m_pStruct;
---
>     TimberClassStruct* m_pStruct;
77,82c67,68
<     // parent_zone ID, parent_au ID, and parent_block ID are written from m_pStruct
<     // and read using lookups by id of new ZONE, AU, and BLOCK struct addresses
<     Zone* m_pParentZone;
<     AU* m_pParentAU;
<     //Zone* m_pZoneOfParentAU;
<     BLOCK* m_pParentBLOCK;
---
>     // parent_zone ID, and parent_block ID are written from m_pStruct
>     // and read using lookups by id of new ZoneStruct, AUStruct, and BlockStruct struct addresses
84c70
<     int m_index;
---
>     // parent_au ID is not serialized, but is passed to constructor by zone
86,88c72
<     // classes do NOT have custody of their groups
<     //list<int> m_staticGroupIndices;
<     //list<int> m_floatGroupIndices;
---
>     // float and static group lists are not serialized, since they are populated within the main loop
90c74,77
<     static int m_timberClassCount;
---
>     Zone* m_pParentZone;
>     AUStruct* m_pParentAU;
>     BlockStruct* m_pParentBlock;
>     int m_index;
92,94c79
<     //static map<string, int> m_labelIndex;
<     //typedef map<string, int>::iterator AIndexIterator;
<     //typedef map<string, int>::const_iterator AConstIndexIterator;
---
>     static int m_timberClassCount;
97,136d81
< // static & float groups are not serialized,
< // since they are populated within the simulation loop
< /*inline void TimberClass::createFloatGroupIndexList() // called before binary write
< {
< #ifdef _TSB_SERIALIZER_DEBUG
<     cout << "TimberClass " << m_index << " has "
<          << m_pStruct->float_group_list->size << " float groups" << endl;
< #endif
<     m_pStruct->float_group_list = (LIST_PTR *)List::reset(m_pStruct->float_group_list);
<     GROUP* pGROUP = 0;
<     do
<     {
<         pGROUP = static_cast<GROUP*>(List::next(m_pStruct->float_group_list));
<         if (0 != pGROUP)
<         {
<             m_floatGroupIndices.push_back(pGROUP->id);
<         }
< 
<     } while (0 != pGROUP);
< }
< 
< inline void TimberClass::createStaticGroupIndexList() // called before binary write
< {
< #ifdef _TSB_SERIALIZER_DEBUG
<     cout << "TimberClass " << m_index << " has "
<          << m_pStruct->static_group_list->size << " static groups" << endl;
< #endif
<     m_pStruct->static_group_list = (LIST_PTR *)List::reset(m_pStruct->static_group_list);
<     GROUP* pGROUP = 0;
<     do
<     {
<         pGROUP = static_cast<GROUP*>(List::next(m_pStruct->static_group_list));
<         if (0 != pGROUP)
<         {
<             m_staticGroupIndices.push_back(pGROUP->id);
<         }
< 
<     } while (0 != pGROUP);
< }
< */
