Main Page Modules Class Hierarchy Compound List File List Compound Members

# cHistogramBase Class Reference

`#include <chist.h>`

Inheritance diagram for cHistogramBase::

List of all members.

## Public Methods

Constructors, destructor, assignment.
| cHistogramBase (const cHistogramBase &r)
| cHistogramBase (const char *name, int numcells)
virtual | ~cHistogramBase ()
cHistogramBase& | operator= (const cHistogramBase &res)
Redefined cObject member functions.
virtual int | netPack ()
virtual int | netUnpack ()
Redefined member functions from cStatistic and its subclasses.
virtual void | clearResult ()
virtual void | transform ()
virtual int | cells () const
virtual void | saveToFile (FILE *) const
virtual void | loadFromFile (FILE *)
New member functions.
virtual void | setNumCells (int numcells)

## Detailed Description

Base class for histogram classes. It adds a vector of counters to cDensityEstBase.

## Constructor & Destructor Documentation

cHistogramBase::cHistogramBase ( | const cHistogramBase & r )`[inline]`

| Copy constructor.

cHistogramBase::cHistogramBase ( | const char * name,
| int numcells )

| Constructor.

cHistogramBase::~cHistogramBase ( | )`[virtual]`

| Destructor.

## Member Function Documentation

int cHistogramBase::cells ( | ) const`[virtual]`

| Returns the number of histogram cells used. Reimplemented from cDensityEstBase.

void cHistogramBase::clearResult ( | )`[virtual]`

| Clears the results collected so far. Reimplemented from cDensityEstBase. Reimplemented in cVarHistogram.

void cHistogramBase::loadFromFile ( | FILE * )`[virtual]`

| Reads the object data from a file, in the format written out by saveToFile(). Reimplemented from cDensityEstBase. Reimplemented in cEqdHistogramBase, and cVarHistogram.

int cHistogramBase::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 cDensityEstBase. Reimplemented in cEqdHistogramBase, cLongHistogram, cDoubleHistogram, and cVarHistogram.

int cHistogramBase::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 cDensityEstBase. Reimplemented in cEqdHistogramBase, cLongHistogram, cDoubleHistogram, and cVarHistogram.

cHistogramBase & cHistogramBase::operator= ( | const cHistogramBase & res )

| Assignment operator. The name member doesn't get copied; see cObject's operator=() for more details.

void cHistogramBase::saveToFile ( | FILE * ) const`[virtual]`

| Writes the contents of the object into a text file. Reimplemented from cDensityEstBase. Reimplemented in cEqdHistogramBase, and cVarHistogram.

void cHistogramBase::setNumCells ( | int numcells )`[virtual]`

| Sets the number of cells. Cannot be called when the cells have been set up already.

void cHistogramBase::transform ( | )`[virtual]`

| Transforms the table of pre-collected values into an internal histogram structure. Reimplemented from cDensityEstBase. Reimplemented in cVarHistogram.

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

- chist.h