mirror of
https://github.com/valitydev/osquery-1.git
synced 2024-11-07 09:58:54 +00:00
36 lines
744 B
C++
36 lines
744 B
C++
// Copyright 2004-present Facebook. All Rights Reserved.
|
|
|
|
#ifndef OSQUERY_LOGGER_PLUGIN_H
|
|
#define OSQUERY_LOGGER_PLUGIN_H
|
|
|
|
#include <memory>
|
|
|
|
#include "osquery/registry.h"
|
|
#include "osquery/status.h"
|
|
|
|
namespace osquery { namespace logger {
|
|
|
|
class LoggerPlugin {
|
|
public:
|
|
virtual osquery::Status logString(const std::string& s) {
|
|
return osquery::Status(1, "Not implemented");
|
|
}
|
|
virtual ~LoggerPlugin() {}
|
|
protected:
|
|
LoggerPlugin() {};
|
|
};
|
|
|
|
}}
|
|
|
|
DECLARE_REGISTRY(
|
|
LoggerPlugins,
|
|
std::string,
|
|
std::shared_ptr<osquery::logger::LoggerPlugin>)
|
|
|
|
#define REGISTERED_LOGGER_PLUGINS REGISTRY(LoggerPlugins)
|
|
|
|
#define REGISTER_LOGGER_PLUGIN(name, decorator) \
|
|
REGISTER(LoggerPlugins, name, decorator)
|
|
|
|
#endif /* OSQUERY_LOGGER_PLUGIN_H */
|