IODA Bundle
RowsCounter.cc
Go to the documentation of this file.
1
/*
2
* (C) Copyright 1996-2012 ECMWF.
3
*
4
* This software is licensed under the terms of the Apache Licence Version 2.0
5
* which can be obtained at http://www.apache.org/licenses/LICENSE-2.0.
6
* In applying this licence, ECMWF does not waive the privileges and immunities
7
* granted to it by virtue of its status as an intergovernmental organisation nor
8
* does it submit to any jurisdiction.
9
*/
10
11
#include "eckit/eckit.h"
12
#include "
odc/core/MetaData.h
"
13
#include "
odc/core/TablesReader.h
"
14
#include "
odc/Reader.h
"
15
#include "
odc/RowsCounter.h
"
16
17
using namespace
eckit
;
18
19
namespace
odc
{
20
21
unsigned
long
long
RowsCounter::fastRowCount(
const
PathName &db)
22
{
23
unsigned
long
long
n = 0;
24
25
core::TablesReader
reader(db);
26
27
auto
it = reader.
begin
();
28
auto
end = reader.
end
();
29
for
(; it != end; ++it)
30
n += it->
rowCount
();
31
return
n;
32
}
33
34
35
}
// namespace odc
36
MetaData.h
Reader.h
RowsCounter.h
TablesReader.h
odc::core::Table::rowCount
size_t rowCount() const
Definition:
Table.cc:50
odc::core::TablesReader
Definition:
TablesReader.h:77
odc::core::TablesReader::end
iterator end()
Definition:
TablesReader.cc:98
odc::core::TablesReader::begin
iterator begin()
Definition:
TablesReader.cc:94
eckit
Definition:
DistributionUtils.h:15
odc
Definition:
ColumnInfo.h:23
odc
src
odc
RowsCounter.cc
Generated on Fri Aug 20 2021 11:49:10 for IODA Bundle by
1.9.1