diff options
Diffstat (limited to 'ml/Dimension.h')
-rw-r--r-- | ml/Dimension.h | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/ml/Dimension.h b/ml/Dimension.h index 44b348e9..e4f8bd1c 100644 --- a/ml/Dimension.h +++ b/ml/Dimension.h @@ -30,6 +30,16 @@ public: return SS.str(); } + bool isActive() const { + if (rrdset_flag_check(RD->rrdset, RRDSET_FLAG_OBSOLETE)) + return false; + + if (rrddim_flag_check(RD, RRDDIM_FLAG_OBSOLETE)) + return false; + + return true; + } + void setAnomalyRateRD(RRDDIM *ARRD) { AnomalyRateRD = ARRD; } RRDDIM *getAnomalyRateRD() const { return AnomalyRateRD; } @@ -38,14 +48,14 @@ public: } virtual ~RrdDimension() { - rrddim_free_custom(AnomalyRateRD->rrdset, AnomalyRateRD, 0); + rrddim_free(AnomalyRateRD->rrdset, AnomalyRateRD); } private: RRDDIM *RD; RRDDIM *AnomalyRateRD; - struct rrddim_volatile::rrddim_query_ops *Ops; + struct rrddim_query_ops *Ops; std::string ID; }; |