31 lines
746 B
C++
31 lines
746 B
C++
#ifndef VIBRATIONDATA_H
|
|
#define VIBRATIONDATA_H
|
|
#include <memory>
|
|
#include <vector>
|
|
#include "cardbase.h"
|
|
|
|
|
|
class VibrationData : public CardBase {
|
|
public:
|
|
VibrationData();
|
|
void FromJson(const Json::Value &cfg) {
|
|
version_ = cfg["version"].asInt();
|
|
slot_ = cfg["slot"].asInt();
|
|
card_type_ = static_cast<CardType>(cfg["type"].asInt());
|
|
}
|
|
|
|
Json::Value ToJson() {
|
|
Json::Value ch;
|
|
ch[NAME(version)] = version_;
|
|
ch[NAME(slot)] = slot_;
|
|
ch[NAME(type)] = card_type_;
|
|
return ch;
|
|
}
|
|
// private:
|
|
SeismicMonitor base_config_[CHANNEL_COUNT];
|
|
AllFilter filter_[CHANNEL_COUNT];
|
|
std::vector<std::shared_ptr<VariableBase>> variables_;
|
|
};
|
|
|
|
#endif // VIBRATIONDATA_H
|