Subversion Repositories public iLand

Rev

Rev 1221 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1033 werner 1
/********************************************************************************************
2
**    iLand - an individual based forest landscape and disturbance model
3
**    http://iland.boku.ac.at
4
**    Copyright (C) 2009-  Werner Rammer, Rupert Seidl
5
**
6
**    This program is free software: you can redistribute it and/or modify
7
**    it under the terms of the GNU General Public License as published by
8
**    the Free Software Foundation, either version 3 of the License, or
9
**    (at your option) any later version.
10
**
11
**    This program is distributed in the hope that it will be useful,
12
**    but WITHOUT ANY WARRANTY; without even the implied warranty of
13
**    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14
**    GNU General Public License for more details.
15
**
16
**    You should have received a copy of the GNU General Public License
17
**    along with this program.  If not, see <http://www.gnu.org/licenses/>.
18
********************************************************************************************/
19
 
837 werner 20
#ifndef LANDSCAPEOUT_H
21
#define LANDSCAPEOUT_H
22
 
23
#include "output.h"
24
#include "expression.h"
25
#include "standstatistics.h"
26
#include <QMap>
27
 
28
/** LandscapeOut is aggregated output for the total landscape per species. All values are per hectare values. */
29
class LandscapeOut : public Output
30
{
31
public:
32
    LandscapeOut();
33
    virtual void exec();
34
    virtual void setup();
35
private:
36
    Expression mCondition;
37
    QMap<QString,StandStatistics> mLandscapeStats;
38
};
39
 
1114 werner 40
 
41
/** LandscapeRemovedOut is aggregated output for removed trees on the full landscape. All values are per hectare values. */
42
class LandscapeRemovedOut : public Output
43
{
44
public:
45
    LandscapeRemovedOut();
46
    void execRemovedTree(const Tree *t, int reason);
47
    virtual void exec();
48
    virtual void setup();
49
private:
50
    bool mIncludeDeadTrees;
51
    bool mIncludeHarvestTrees;
52
    Expression mCondition;
53
    struct LROdata {
54
        LROdata() { clear(); }
55
        void clear() { volume=0.; basal_area=0.; n=0.; }
56
        double volume;
57
        double basal_area;
58
        double n;
59
    };
60
 
61
    QHash<int,LROdata> mLandscapeRemoval;
62
};
63
 
837 werner 64
#endif // LANDSCAPEOUT_H