Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for an old version of Boost. Click here to view this page for the latest version.
PrevUpHomeNext
count
Description

A metafunction that returns the result type of count given the sequence and search types.

Synopsis
template<
    typename Sequence,
    typename T
    >
struct count
{
    typedef int type;
};

Table 1.62. Parameters

Parameter

Requirement

heading Description

Sequence

A model of Forward Sequence

Operation's argument

T

Any type

Operation's argument


Expression Semantics
result_of::count<T>::type

Return type: int.

Semantics: Returns the return type of count. The return type is always int.

Complexity

Constant.

Header
#include <boost/fusion/algorithm/query/count.hpp>
#include <boost/fusion/include/count.hpp>

PrevUpHomeNext