Abstract class representing a bin. More...
#include <hpp/statistics/bin.hh>
Public Member Functions | |
const std::size_t & | freq () const |
Return the number of element in the bin. | |
std::size_t | operator++ () |
Add an occurence. | |
std::size_t | operator++ (int) |
Add an occurence. | |
virtual std::ostream & | print (std::ostream &os) const |
Print the bin. | |
virtual std::ostream & | printValue (std::ostream &os) const =0 |
Print the inner value of the bin. | |
Protected Member Functions | |
Bin () | |
Constructor. |
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.
hpp::statistics::Bin::Bin | ( | ) | [inline, protected] |
Constructor.
const std::size_t& hpp::statistics::Bin::freq | ( | ) | const [inline] |
Return the number of element in the bin.
std::size_t hpp::statistics::Bin::operator++ | ( | ) | [inline] |
Add an occurence.
std::size_t hpp::statistics::Bin::operator++ | ( | int | ) | [inline] |
Add an occurence.
virtual std::ostream& hpp::statistics::Bin::print | ( | std::ostream & | os | ) | const [inline, virtual] |
Print the bin.
Referenced by hpp::statistics::operator<<().
virtual std::ostream& hpp::statistics::Bin::printValue | ( | std::ostream & | os | ) | const [pure virtual] |
Print the inner value of the bin.