1 // ANNA - Anna is Not Nothingness Anymore //
3 // (c) Copyright 2005-2015 Eduardo Ramos Testillano & Francisco Ruiz Rayo //
5 // See project site at http://redmine.teslayout.com/projects/anna-suite //
6 // See accompanying file LICENSE or copy at http://www.teslayout.com/projects/public/anna.LICENSE //
9 #ifndef example_diameter_launcher_MyCounterRecorder_hpp
10 #define example_diameter_launcher_MyCounterRecorder_hpp
13 #include <sys/stat.h> // chmod
14 #include <fcntl.h> // open / write
18 #include <MyCounterRecorderClock.hpp>
21 class MyCounterRecorder : public anna::oam::CounterRecorder {
25 std::string a_fileNamePrefix;
26 std::string a_fileName;
27 time_t a_previousTime;
28 std::string a_fixedLine;
30 // pure virtual definitions:
31 void open() throw(anna::RuntimeException);
32 void apply(const anna::oam::Counter& counter) throw(anna::RuntimeException);
34 std::string asString() const throw();
37 MyCounterRecorder(const std::string &fnp);