Rev 311 | Rev 393 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
1 | |||
106 | Werner | 2 | #ifndef STANDLOADER_H |
3 | #define STANDLOADER_H |
||
287 | werner | 4 | #include <QtCore/QString> |
106 | Werner | 5 | |
6 | class Model; |
||
187 | iland | 7 | class ResourceUnit; |
290 | werner | 8 | class RandomCustomPDF; |
9 | class Species; |
||
106 | Werner | 10 | class StandLoader |
11 | { |
||
12 | public: |
||
290 | werner | 13 | StandLoader(Model *model): mModel(model), mRandom(0) {} |
14 | ~StandLoader(); |
||
106 | Werner | 15 | void processInit(); |
294 | werner | 16 | void loadPicusFile(const QString &fileName, ResourceUnit *ru=NULL); |
287 | werner | 17 | void loadiLandFile(const QString &fileName, ResourceUnit *ru=NULL); |
389 | werner | 18 | int loadSingleTreeList(const QString &content, ResourceUnit*ru = NULL, const QString &fileName=""); |
294 | werner | 19 | void loadDistributionList(const QString &content, ResourceUnit *ru = NULL, const QString &fileName=""); |
106 | Werner | 20 | private: |
290 | werner | 21 | struct InitFileItem |
22 | { |
||
23 | Species *species; |
||
24 | int count; |
||
25 | double dbh_from, dbh_to; |
||
26 | double hd; |
||
27 | int age; |
||
311 | werner | 28 | double density; |
290 | werner | 29 | }; |
284 | werner | 30 | void loadInitFile(const QString &fileName, const QString &type, ResourceUnit *ru=NULL); |
290 | werner | 31 | void executeiLandInit(ResourceUnit *ru); |
281 | werner | 32 | void loadForUnit(); |
33 | void copyTrees(); |
||
34 | void evaluateDebugTrees(); |
||
106 | Werner | 35 | Model *mModel; |
290 | werner | 36 | RandomCustomPDF *mRandom; |
37 | QVector<InitFileItem> mInitItems; |
||
106 | Werner | 38 | }; |
39 | |||
40 | #endif // STANDLOADER_H |