Fawkes API  Fawkes Development Version
fawkes::RRDArchive Class Reference

RRD Archive description. More...

#include <>>

List of all members.

Public Types

enum  ConsolidationFunction { AVERAGE, MIN, MAX, LAST }
 Consolidation function type. More...

Public Member Functions

 RRDArchive (ConsolidationFunction cf, float xff, unsigned int steps, unsigned int rows)
 Constructor.
 RRDArchive (const RRDArchive &rra)
 Copy constructor.
 ~RRDArchive ()
 Destructor.
const char * to_string () const
 Get string representation.
RRDArchiveoperator= (const RRDArchive &rra)
 Assignment operator.
ConsolidationFunction get_cf () const
 Get consolidation function type.
float get_xff () const
 Get xfiles factor.
unsigned int get_steps () const
 Get number of steps.
unsigned int get_rows () const
 Get number of rows.

Static Public Member Functions

static const char * cf_to_string (ConsolidationFunction cf)
 Convert consolidation function type to string.

Detailed Description

RRD Archive description.

Author:
Tim Niemueller

Member Enumeration Documentation

Consolidation function type.

Enumerator:
AVERAGE 

Averaging consolidation function.

MIN 

Minimum consolidation function.

MAX 

Maximum consolidation function.

LAST 

Last value consolidation function.

Definition at line 90 of file rrd_descriptions.h.


Constructor & Destructor Documentation

fawkes::RRDArchive::RRDArchive ( ConsolidationFunction  cf,
float  xff,
unsigned int  steps,
unsigned int  rows 
)

Constructor.

Parameters:
cfconsolidation function
xffThe xfiles factor defines what part of a consolidation interval may be made up from *UNKNOWN* data while the consolidated value is still regarded as known. It is given as the ratio of allowed *UNKNOWN* PDPs to the number of PDPs in the interval. Thus, it ranges from 0 to 1 (exclusive).
stepsdefines how many of these primary data points are used to build a consolidated data point which then goes into the archive.
rowsdefines how many generations of data values are kept in an RRA. Obviously, this has to be greater than zero.

Definition at line 179 of file rrd_descriptions.cpp.

fawkes::RRDArchive::RRDArchive ( const RRDArchive rra)

Copy constructor.

Parameters:
rrainstance to copy

Definition at line 189 of file rrd_descriptions.cpp.

fawkes::RRDArchive::~RRDArchive ( )

Destructor.

Definition at line 197 of file rrd_descriptions.cpp.


Member Function Documentation

const char * fawkes::RRDArchive::cf_to_string ( ConsolidationFunction  cf) [static]

Convert consolidation function type to string.

Parameters:
cfconsolidation function type
Returns:
string representation of cf, suitable for RRA lines.

Definition at line 246 of file rrd_descriptions.cpp.

References MIN, MAX, and LAST.

Referenced by fawkes::RRDGraphDataDefinition::to_string(), and fawkes::RRDGraphGPrint::to_string().

ConsolidationFunction fawkes::RRDArchive::get_cf ( ) const [inline]

Get consolidation function type.

Returns:
consolidation function type

Definition at line 108 of file rrd_descriptions.h.

unsigned int fawkes::RRDArchive::get_rows ( ) const [inline]

Get number of rows.

Returns:
number of rows

Definition at line 114 of file rrd_descriptions.h.

unsigned int fawkes::RRDArchive::get_steps ( ) const [inline]

Get number of steps.

Returns:
number of steps

Definition at line 112 of file rrd_descriptions.h.

float fawkes::RRDArchive::get_xff ( ) const [inline]

Get xfiles factor.

Returns:
xfiles factor

Definition at line 110 of file rrd_descriptions.h.

RRDArchive & fawkes::RRDArchive::operator= ( const RRDArchive rra)

Assignment operator.

Parameters:
rrainstance to copy from
Returns:
reference to this instance

Definition at line 207 of file rrd_descriptions.cpp.

const char * fawkes::RRDArchive::to_string ( ) const

Get string representation.

Returns:
string representation suitable to be passed to rrd_create().

Definition at line 222 of file rrd_descriptions.cpp.

References MIN, MAX, and LAST.


The documentation for this class was generated from the following files: