1232 |
23 Oct 10 |
peter |
1 |
#ifndef _theplu_svndigest_tiny_stats_ |
1232 |
23 Oct 10 |
peter |
2 |
#define _theplu_svndigest_tiny_stats_ |
1232 |
23 Oct 10 |
peter |
3 |
|
1232 |
23 Oct 10 |
peter |
// $Id$ |
1232 |
23 Oct 10 |
peter |
5 |
|
1232 |
23 Oct 10 |
peter |
6 |
/* |
1635 |
30 Mar 23 |
peter |
Copyright (C) 2010 Peter Johansson |
1232 |
23 Oct 10 |
peter |
8 |
|
1232 |
23 Oct 10 |
peter |
This file is part of svndigest, http://dev.thep.lu.se/svndigest |
1232 |
23 Oct 10 |
peter |
10 |
|
1232 |
23 Oct 10 |
peter |
svndigest is free software; you can redistribute it and/or modify it |
1232 |
23 Oct 10 |
peter |
under the terms of the GNU General Public License as published by |
1232 |
23 Oct 10 |
peter |
the Free Software Foundation; either version 3 of the License, or |
1232 |
23 Oct 10 |
peter |
(at your option) any later version. |
1232 |
23 Oct 10 |
peter |
15 |
|
1232 |
23 Oct 10 |
peter |
svndigest is distributed in the hope that it will be useful, but |
1232 |
23 Oct 10 |
peter |
WITHOUT ANY WARRANTY; without even the implied warranty of |
1232 |
23 Oct 10 |
peter |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
1232 |
23 Oct 10 |
peter |
General Public License for more details. |
1232 |
23 Oct 10 |
peter |
20 |
|
1232 |
23 Oct 10 |
peter |
You should have received a copy of the GNU General Public License |
1232 |
23 Oct 10 |
peter |
along with svndigest. If not, see <http://www.gnu.org/licenses/>. |
1232 |
23 Oct 10 |
peter |
23 |
*/ |
1232 |
23 Oct 10 |
peter |
24 |
|
1232 |
23 Oct 10 |
peter |
25 |
#include "LineTypeParser.h" |
1232 |
23 Oct 10 |
peter |
26 |
|
1232 |
23 Oct 10 |
peter |
27 |
#include <map> |
1232 |
23 Oct 10 |
peter |
28 |
#include <string> |
1232 |
23 Oct 10 |
peter |
29 |
|
1232 |
23 Oct 10 |
peter |
30 |
namespace theplu{ |
1232 |
23 Oct 10 |
peter |
31 |
namespace svndigest{ |
1232 |
23 Oct 10 |
peter |
32 |
|
1232 |
23 Oct 10 |
peter |
33 |
class StatsCollection; |
1232 |
23 Oct 10 |
peter |
34 |
|
1232 |
23 Oct 10 |
peter |
35 |
/** |
1232 |
23 Oct 10 |
peter |
36 |
*/ |
1232 |
23 Oct 10 |
peter |
37 |
class TinyStats |
1232 |
23 Oct 10 |
peter |
38 |
{ |
1232 |
23 Oct 10 |
peter |
39 |
public: |
1232 |
23 Oct 10 |
peter |
40 |
unsigned int operator()(const std::string& stats_type, |
1232 |
23 Oct 10 |
peter |
41 |
const std::string& user, |
1232 |
23 Oct 10 |
peter |
42 |
LineTypeParser::line_type lt) const; |
1232 |
23 Oct 10 |
peter |
43 |
|
1232 |
23 Oct 10 |
peter |
44 |
void init(const StatsCollection&); |
1232 |
23 Oct 10 |
peter |
45 |
|
1232 |
23 Oct 10 |
peter |
46 |
private: |
1232 |
23 Oct 10 |
peter |
47 |
typedef std::vector<unsigned int> Vector; |
1232 |
23 Oct 10 |
peter |
48 |
typedef std::map<std::string, Vector> Map; |
1232 |
23 Oct 10 |
peter |
49 |
std::map<std::string, Map> data_; |
1232 |
23 Oct 10 |
peter |
50 |
}; |
1232 |
23 Oct 10 |
peter |
51 |
}} // end of namespace svndigest end of namespace theplu |
1232 |
23 Oct 10 |
peter |
52 |
|
1513 |
23 Sep 12 |
peter |
53 |
#endif |