#include <transitionruletransform.h>
Inherits ITransform.
|
void | configure (DynamicObject config, const flint::ILandUnitController &landUnitController, datarepository::DataRepository &dataRepository) override |
|
void | controllerChanged (const flint::ILandUnitController &controller) override |
|
const DynamicVar & | value () const override |
|
|
const std::string | buildSql (const DynamicObject &classifierSet) const |
|
|
const flint::ILandUnitController * | _landUnitController |
|
datarepository::DataRepository * | _dataRepository |
|
std::shared_ptr< datarepository::IProviderRelationalInterface > | _provider |
|
const flint::IVariable * | _csetVar |
|
DynamicVar | _value |
|
Poco::ThreadLocal< Poco::LRUCache< std::string, DynamicVar > > | _cache |
|
const std::string | _baseSql |
|
const std::string | _matchSql = "WHEN c.name LIKE '%1%' AND cv.value LIKE '%2%' THEN 4 " |
|
◆ buildSql()
const std::string buildSql |
( |
const DynamicObject & |
classifierSet | ) |
const |
|
private |
Create variables classifierNames, a vector of strings and classifierValuesSql, a string
For each classifier in parameter classifierSet, append classifier.first to classifierNames, concatenate classifierValuesSql with the SQL query TransitionRuleTransform._matchSql, placeholder values clasifier.first and classifier.second (gives the classifier value) Assign a variable classifierNamesSql the join vector classifierNames, separated by ","
Return the SQL query TransitionRuleTransform._baseSql with placeholders classifierNamesSql and classifierValuesSql
- Parameters
-
classifierSet | const DynamicObject& |
- Returns
- string
◆ configure()
void configure |
( |
DynamicObject |
config, |
|
|
const flint::ILandUnitController & |
landUnitController, |
|
|
datarepository::DataRepository & |
dataRepository |
|
) |
| |
|
override |
◆ controllerChanged()
void controllerChanged |
( |
const flint::ILandUnitController & |
controller | ) |
|
|
override |
◆ value()
const DynamicVar & value |
( |
| ) |
const |
|
override |
◆ _baseSql
const std::string _baseSql |
|
private |
◆ _cache
Poco::ThreadLocal<Poco::LRUCache<std::string, DynamicVar> > _cache |
|
mutableprivate |
◆ _csetVar
const flint::IVariable* _csetVar |
|
mutableprivate |
◆ _dataRepository
datarepository::DataRepository* _dataRepository |
|
private |
◆ _landUnitController
const flint::ILandUnitController* _landUnitController |
|
private |
◆ _matchSql
const std::string _matchSql = "WHEN c.name LIKE '%1%' AND cv.value LIKE '%2%' THEN 4 " |
|
private |
◆ _provider
std::shared_ptr<datarepository::IProviderRelationalInterface> _provider |
|
private |
◆ _value
The documentation for this class was generated from the following files: