X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Frrd_format.c;h=501b2676d95b6661966b85eadc9ba2b849285f99;hb=1be77c55cf81738e057f1b1180357edecda89e6f;hp=16e4f1f4d05db39f56edded7b9ee0a46daea01c5;hpb=56d67cdd0c5b2c27c9242a3d5810c7184917f663;p=rrdtool.git diff --git a/src/rrd_format.c b/src/rrd_format.c index 16e4f1f..501b267 100644 --- a/src/rrd_format.c +++ b/src/rrd_format.c @@ -1,5 +1,5 @@ /***************************************************************************** - * RRDtool 1.4.0 Copyright by Tobi Oetiker, 1997-2009 + * RRDtool 1.4.3 Copyright by Tobi Oetiker, 1997-2010 ***************************************************************************** * rrd_format.c RRD Database Format helper functions ***************************************************************************** @@ -84,6 +84,26 @@ enum cf_en cf_conv( return (enum cf_en)(-1); } +const char *cf_to_string (enum cf_en cf) +{ + switch (cf) + { + case CF_AVERAGE: return "AVERAGE"; + case CF_MINIMUM: return "MIN"; + case CF_MAXIMUM: return "MAX"; + case CF_LAST: return "LAST"; + case CF_HWPREDICT: return "HWPREDICT"; + case CF_SEASONAL: return "SEASONAL"; + case CF_DEVPREDICT: return "DEVPREDICT"; + case CF_DEVSEASONAL: return "DEVSEASONAL"; + case CF_FAILURES: return "FAILURES"; + case CF_MHWPREDICT: return "MHWPREDICT"; + + default: + return NULL; + } +} /* char *cf_to_string */ + #undef converter long ds_match(