45 lines
1.2 KiB
C
45 lines
1.2 KiB
C
|
|
/******************************************************************************************************************
|
||
|
|
* Action instruction algorithm(study sample data online,compare with sample
|
||
|
|
*data)
|
||
|
|
*
|
||
|
|
* arg[0] action expression
|
||
|
|
* arg[1] feedback expression
|
||
|
|
* arg[2] expression of judgment result
|
||
|
|
*
|
||
|
|
* feedback expression
|
||
|
|
* arg[2] expression of judgment result
|
||
|
|
*
|
||
|
|
* 1.0 2020-12-17 zoufuzhou
|
||
|
|
******************************************************************************************************************/
|
||
|
|
#ifndef _H_ALGORITHM_EXPRESSION_SAMPLE_H
|
||
|
|
#define _H_ALGORITHM_EXPRESSION_SAMPLE_H
|
||
|
|
|
||
|
|
#include <eqpalg/AlgCommonDefine.h>
|
||
|
|
#include <eqpalg/alg_base.h>
|
||
|
|
#include <eqpalg/algs/AlgExp.h>
|
||
|
|
#include <iomanip>
|
||
|
|
#include <iostream>
|
||
|
|
#include <string>
|
||
|
|
|
||
|
|
// class AlgExpSample:virtual public AlgBase
|
||
|
|
class AlgExpSample : public AlgExp {
|
||
|
|
public:
|
||
|
|
AlgExpSample(const string &name, const Json::Value &rulejson,
|
||
|
|
const string &ruleId, const bool down_limit = 1);
|
||
|
|
|
||
|
|
virtual ~AlgExpSample();
|
||
|
|
|
||
|
|
public:
|
||
|
|
virtual int init() override;
|
||
|
|
virtual Json::Value exec_mon();
|
||
|
|
|
||
|
|
private:
|
||
|
|
int mon_proc(string &outjson, HD3Record *hdRec);
|
||
|
|
|
||
|
|
private:
|
||
|
|
MathExpression *exp_act_;
|
||
|
|
bool _down_limit;
|
||
|
|
};
|
||
|
|
|
||
|
|
#endif
|