iFun Engine API  1.0.0-b3630
Great Technology for Great Games
 All Classes Files Functions Variables Typedefs Macros
logging.h
Go to the documentation of this file.
1 // Copyright (C) 2013-2015 iFunFactory Inc. All Rights Reserved.
2 //
3 // This work is confidential and proprietary to iFunFactory Inc. and
4 // must not be used, disclosed, copied, or distributed without the prior
5 // consent of iFunFactory Inc.
6 
9 #ifndef INCLUDE_FUNAPI_SYSTEM_LOGGING_H_
10 #define INCLUDE_FUNAPI_SYSTEM_LOGGING_H_
11 
12 #include <boost/noncopyable.hpp>
13 #include <boost/shared_ptr.hpp>
14 #include <boost/uuid/uuid.hpp>
15 #include <funapi/types.h>
16 #include <glog/logging.h>
17 
18 #include <vector>
19 #include <string>
20 
21 
22 namespace fun {
23 
24 enum LogColumnCppType {
25  LCT_BOOL,
26  LCT_TIME_T,
27  LCT_WALLCLOCK_VALUE,
28  LCT_DOUBLE,
29  LCT_INT64,
30  LCT_STRING,
31 };
32 
33 
34 typedef std::vector<string> LoggerColumnNames;
35 typedef std::vector<string> LoggerColumnValues;
36 typedef std::vector<bool> LoggerColumnQuotes;
37 typedef std::vector<LogColumnCppType> LoggerColumnCppTypes;
38 
39 
43  public:
51  LoggerRegistryHelper(const string &activityType,
52  const string &schema,
53  const LoggerColumnNames &columns,
54  const LoggerColumnCppTypes &types,
55  const LoggerColumnQuotes &quotes);
56 };
57 
58 
59 void LogActivity(const string &activityType, const LoggerColumnValues &values);
60 
61 } // namespace fun
62 
63 #endif // INCLUDE_FUNAPI_SYSTEM_LOGGING_H_
LoggerRegistryHelper(const string &activityType, const string &schema, const LoggerColumnNames &columns, const LoggerColumnCppTypes &types, const LoggerColumnQuotes &quotes)
Helper class to register user-defined activity log.
Definition: logging.h:42