Main Page   Modules   Class Hierarchy   Compound List   File List   Compound Members  

cLongHistogram Class Reference

#include <chist.h>

Inheritance diagram for cLongHistogram::

cEqdHistogramBase cHistogramBase cDensityEstBase cStdDev cStatistic cObject List of all members.

Public Methods

Constructors, destructor, assignment.
 cLongHistogram (const cLongHistogram &r)
 cLongHistogram (const char *name=NULL, int numcells=10)
virtual ~cLongHistogram ()
cLongHistogram& operator= (const cLongHistogram &)
Redefined cObject member functions.
virtual cObjectdup () const
virtual int netPack ()
virtual int netUnpack ()
Redefined member functions from cStatistic and its subclasses.
virtual void collect (double val)
virtual double random () const

Protected Methods

virtual void setupRange ()

Detailed Description

Equidistant histogram for integers. cLongHistogram is derived from cEqdHistogramBase which contains most of the functionality.

The histogram is set up in the following way:


Constructor & Destructor Documentation

cLongHistogram::cLongHistogram ( const cLongHistogram & r ) [inline]
 

Copy constructor.

cLongHistogram::cLongHistogram ( const char * name = NULL,
int numcells = 10 ) [explicit]
 

Constructor.

cLongHistogram::~cLongHistogram ( ) [virtual]
 

Destructor.


Member Function Documentation

void cLongHistogram::collect ( double val ) [virtual]
 

Collects one value. FIXME: truncates + collects

Reimplemented from cDensityEstBase.

cObject * cLongHistogram::dup ( ) const [inline, virtual]
 

Creates and returns an exact copy of this object. See cObject for more details.

Reimplemented from cStdDev.

int cLongHistogram::netPack ( ) [virtual]
 

Serializes the object into a PVM or MPI send buffer. Used by the simulation kernel for parallel execution. See cObject for more details.

Reimplemented from cEqdHistogramBase.

int cLongHistogram::netUnpack ( ) [virtual]
 

Deserializes the object from a PVM or MPI receive buffer Used by the simulation kernel for parallel execution. See cObject for more details.

Reimplemented from cEqdHistogramBase.

cLongHistogram & cLongHistogram::operator= ( const cLongHistogram & ) [inline]
 

Assignment is not supported by this class: this method throws a cException when called.

double cLongHistogram::random ( ) const [virtual]
 

Returns a random number based on the distribution collected. If no values have been collected, it returns 0; when in initial collection phase, it returns one of the stored observations; after the histogram has been set up, a random integer is returned.

Reimplemented from cDensityEstBase.

void cLongHistogram::setupRange ( ) [protected, virtual]
 

Called internally by transform(), this method should determine and set up the histogram range

Reimplemented from cEqdHistogramBase.


The documentation for this class was generated from the following file:
Generated at Mon Jun 16 23:37:32 2003 for OMNeT++ by doxygen1.2.8.1 written by Dimitri van Heesch, © 1997-2001