virtual ~LogEvent() { }
string get_type_str() const;
- static EventType str_to_type(std::string const &str);
+ static EventType str_to_type(boost::string_view str);
EventType get_type() const { return _type; }
void set_type(EventType t) { _type = t; }
* tools can examine metablobs while traversing lists of LogEvent.
*/
virtual EMetaBlob *get_metablob() { return NULL; }
+
+private:
+ static const std::map<std::string, LogEvent::EventType> types;
};
inline ostream& operator<<(ostream& out, const LogEvent &le) {