hpp-statistics: hpp::statistics::Bin Class Reference

hpp-statistics 9.0.2 Classes for doing statistics.

Public Member Functions | Protected Member Functions | List of all members
hpp::statistics::Bin Class Referenceabstract

`#include <hpp/statistics/bin.hh>`

Inheritance diagram for hpp::statistics::Bin:
[legend]

## Public Member Functions
const std::size_t & | freq () const
| Return the number of element in the bin. More...
std::size_t | operator++ ()
std::size_t | operator++ (int)
virtual std::ostream & | print (std::ostream &os) const
| Print the bin. More...
virtual std::ostream & | printValue (std::ostream &os) const =0
| Print the inner value of the bin. More...

## Protected Member Functions
| Bin ()
| Constructor. More...
virtual | ~Bin ()

## Detailed Description

Abstract class representing a bin.

Bins are use for statistics. They keep the number of of apparition of a given value. Inherited class should also implement comparison and equality operators.

## Constructor & Destructor Documentation

## ◆ Bin()

hpp::statistics::Bin::Bin | ( |  | ) |
| inlineprotected

Constructor.

## ◆ ~Bin()

virtual hpp::statistics::Bin::~Bin | ( |  | ) |
| inlineprotectedvirtual

## Member Function Documentation

## ◆ freq()

const std::size_t& hpp::statistics::Bin::freq | ( |  | ) | const
| inline

Return the number of element in the bin.

## ◆ operator++() [1/2]

std::size_t hpp::statistics::Bin::operator++ | ( |  | ) |
| inline

Add an occurence

Returns
  The frequency after increment;

## ◆ operator++() [2/2]

std::size_t hpp::statistics::Bin::operator++ | ( | int |  | ) |
| inline

Add an occurence

Returns
  The frequency before increment;

## ◆ print()

virtual std::ostream& hpp::statistics::Bin::print | ( | std::ostream & | os | ) | const
| inlinevirtual

Print the bin.

## ◆ printValue()

virtual std::ostream& hpp::statistics::Bin::printValue | ( | std::ostream & | os | ) | const
| pure virtual

Print the inner value of the bin.

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

- include/hpp/statistics/bin.hh