iLand
|
Activity is the base class for management activities. More...
#include <activity.h>
Public Types | |
enum | Phase { Invalid , Tending , Thinning , Regeneration , All } |
Public Member Functions | |
Activity (const FMSTP *parent) | |
virtual | ~Activity () |
const FMSTP * | program () const |
virtual QString | type () const |
QString | name () const |
name of the activity as provided by JS More... | |
int | index () const |
index of the activity within the STP More... | |
int | earliestSchedule (const double U=100.) const |
get earlist possible scheduled year (relative to rotation begin) More... | |
int | latestSchedule (const double U=100.) const |
get latest possible scheduled year (relative to rotation begin) More... | |
int | optimalSchedule (const double U=100.) const |
get optimal scheduled year (relative to rotation begin) More... | |
bool | isRepeatingActivity () const |
virtual void | setup (QJSValue value) |
setup of the activity (events, schedule, constraints). additional setup in derived classes. More... | |
virtual double | scheduleProbability (FMStand *stand, const int specific_year=-1) |
returns a value > 0 if the activity coult be scheduled now More... | |
virtual double | execeuteProbability (FMStand *stand) |
returns a probability for the activity to be executed (ie all constraints are fulfilled) return value is 0 if the activity can not be executed (maximum result is 1) More... | |
virtual bool | execute (FMStand *stand) |
executes the action (usually defined in derived classes) using the context of 'stand'. More... | |
virtual bool | evaluate (FMStand *stand) |
executes the evaluation of the forest stand. More... | |
virtual void | evaluateDyanamicExpressions (FMStand *stand) |
function that evaluates "bound" dynamic expressions More... | |
virtual QStringList | info () |
dumps some information for debugging More... | |
Static Public Member Functions | |
static Activity * | createActivity (const QString &type, FMSTP *stp) |
Activity factory - create activities for given 'type'. More... | |
Protected Member Functions | |
Schedule & | schedule () |
Constraints & | constraints () |
Events & | events () |
ActivityFlags & | standFlags (FMStand *stand=0) |
Protected Attributes | |
ActivityFlags | mBaseActivity |
Static Protected Attributes | |
static QStringList | mAllowedProperties = QStringList() << "schedule" << "constraint" << "type" |
Friends | |
class | FMSTP |
class | FMStand |
class | ActivityObj |
Activity is the base class for management activities.
An activity is the basic silvicultural building block; it holds state information and defines basic capabilities of all activities (such as having a given Schedule, or Events).
enum ABE::Activity::Phase |
ABE::Activity::Activity | ( | const FMSTP * | parent | ) |
|
virtual |
|
inlineprotected |
Activity factory - create activities for given 'type'.
|
inline |
get earlist possible scheduled year (relative to rotation begin)
|
virtual |
executes the evaluation of the forest stand.
returns true, when the stand should enter the scheduler.
Reimplemented in ABE::ActScheduled, and ABE::ActThinning.
|
virtual |
function that evaluates "bound" dynamic expressions
|
inlineprotected |
|
virtual |
returns a probability for the activity to be executed (ie all constraints are fulfilled) return value is 0 if the activity can not be executed (maximum result is 1)
|
virtual |
executes the action (usually defined in derived classes) using the context of 'stand'.
Reimplemented in ABE::ActGeneral, ABE::ActPlanting, ABE::ActSalvage, ABE::ActScheduled, and ABE::ActThinning.
|
inline |
index of the activity within the STP
|
virtual |
dumps some information for debugging
Reimplemented in ABE::ActGeneral, ABE::ActPlanting, ABE::ActSalvage, and ABE::ActScheduled.
|
inline |
|
inline |
get latest possible scheduled year (relative to rotation begin)
|
inline |
name of the activity as provided by JS
|
inline |
get optimal scheduled year (relative to rotation begin)
|
inline |
|
inlineprotected |
|
virtual |
returns a value > 0 if the activity coult be scheduled now
|
virtual |
setup of the activity (events, schedule, constraints). additional setup in derived classes.
Reimplemented in ABE::ActGeneral, ABE::ActPlanting, ABE::ActSalvage, ABE::ActScheduled, ABE::ActThinning, and ABE::Thinning.
|
protected |
|
virtual |
Reimplemented in ABE::ActGeneral, ABE::ActPlanting, ABE::ActSalvage, ABE::ActScheduled, and ABE::ActThinning.
|
friend |
|
friend |
|
friend |
|
staticprotected |
|
protected |