FMT 0.9.8
Forest management tools for forest planning
Loading...
Searching...
No Matches
Public Member Functions | List of all members
Core::FMTactioncomparator Class Reference

#include <FMTaction.hpp>

Public Member Functions

 FMTactioncomparator (std::string name, bool lcheckaggregate=false)
 
std::vector< const FMTaction * > getallaggregates (const std::vector< FMTaction > &actions, bool aggregateonly=false) const
 
std::unordered_set< int > getallaggregatesset (const std::vector< FMTaction > &actions, bool aggregateonly=false) const
 
bool operator() (const FMTaction &action) const
 

Detailed Description

FMTactioncomparator to check if the action_name already exist in a std container. It can also check for aggregates.

Constructor & Destructor Documentation

◆ FMTactioncomparator()

Core::FMTactioncomparator::FMTactioncomparator ( std::string  name,
bool  lcheckaggregate = false 
)

FMTactioncomparator constructor name is the name of the action we want to match if checkaggregate = true it will also return actions within the named aggregate.

Member Function Documentation

◆ getallaggregates()

std::vector< const FMTaction * > Core::FMTactioncomparator::getallaggregates ( const std::vector< FMTaction > &  actions,
bool  aggregateonly = false 
) const

Looking at the actions vector if aggregateonly = false it will returns actions mathching the action_name if aggregateonly = true it will return only matching aggregates.

◆ getallaggregatesset()

std::unordered_set< int > Core::FMTactioncomparator::getallaggregatesset ( const std::vector< FMTaction > &  actions,
bool  aggregateonly = false 
) const

Looking at the actions vector if aggregateonly = false it will returns actions ids mathching the action_name if aggregateonly = true it will return only matching aggregates.

◆ operator()()

bool Core::FMTactioncomparator::operator() ( const FMTaction action) const

Matching test operator for FMTactioncomparator.


The documentation for this class was generated from the following file: