| 119 | |
| 120 | template <typename InputColumnType, typename OutputColumnType> |
| 121 | class count : public aggregator_base<InputColumnType, OutputColumnType> { |
| 122 | public: |
| 123 | typedef InputColumnType input_type; |
| 124 | typedef OutputColumnType output_type; |
| 125 | |
| 126 | count() : m_data(), m_grouping(false) {} |
| 127 | void begin_group() { m_data = 0; } |
| 128 | template <typename T> void group(const T &t) { |
| 129 | m_data += 1; |
| 130 | m_grouping = true; |
| 131 | } |
| 132 | void end_group() { m_grouping = false; } |
| 133 | bool grouping() { return m_grouping; } |
| 134 | typename ::ff::util::internal::nt_traits<output_type>::type output() const { |
| 135 | return m_data; |
| 136 | } |
| 137 | |
| 138 | protected: |
| 139 | typename ::ff::util::internal::nt_traits<OutputColumnType>::type m_data; |
| 140 | bool m_grouping; |
| 141 | }; |
| 142 | |
| 143 | template <typename InputObjType, typename OutputObjType, typename GroupByType, |
| 144 | typename AggregatorType> |
nothing calls this directly
no outgoing calls
no test coverage detected