mirror of https://github.com/Icinga/icinga2.git
parent
c7b5e4c31e
commit
12c8814bd8
|
@ -51,11 +51,9 @@ SERVICE_STATUS_HANDLE l_SvcStatusHandle;
|
||||||
|
|
||||||
static String LoadAppType(const String& typeSpec)
|
static String LoadAppType(const String& typeSpec)
|
||||||
{
|
{
|
||||||
int index;
|
|
||||||
|
|
||||||
Log(LogInformation, "icinga-app", "Loading application type: " + typeSpec);
|
Log(LogInformation, "icinga-app", "Loading application type: " + typeSpec);
|
||||||
|
|
||||||
index = typeSpec.FindFirstOf('/');
|
String::SizeType index = typeSpec.FindFirstOf('/');
|
||||||
|
|
||||||
if (index == String::NPos)
|
if (index == String::NPos)
|
||||||
return typeSpec;
|
return typeSpec;
|
||||||
|
|
|
@ -359,7 +359,7 @@ Dictionary::Ptr DynamicObject::GetVars(void) const
|
||||||
return GetVarsRaw();
|
return GetVarsRaw();
|
||||||
}
|
}
|
||||||
|
|
||||||
void DynamicObject::SetVars(const Dictionary::Ptr& vars, const String& authority)
|
void DynamicObject::SetVars(const Dictionary::Ptr& vars)
|
||||||
{
|
{
|
||||||
SetOverrideVars(vars);
|
SetOverrideVars(vars);
|
||||||
|
|
||||||
|
@ -374,7 +374,7 @@ int DynamicObject::GetModifiedAttributes(void) const
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void DynamicObject::SetModifiedAttributes(int flags)
|
void DynamicObject::SetModifiedAttributes(int)
|
||||||
{
|
{
|
||||||
/* does nothing by default */
|
/* does nothing by default */
|
||||||
}
|
}
|
||||||
|
|
|
@ -94,7 +94,7 @@ public:
|
||||||
void ClearExtension(const String& key);
|
void ClearExtension(const String& key);
|
||||||
|
|
||||||
Dictionary::Ptr GetVars(void) const;
|
Dictionary::Ptr GetVars(void) const;
|
||||||
void SetVars(const Dictionary::Ptr& vars, const String& authority = String());
|
void SetVars(const Dictionary::Ptr& vars);
|
||||||
|
|
||||||
virtual int GetModifiedAttributes(void) const;
|
virtual int GetModifiedAttributes(void) const;
|
||||||
virtual void SetModifiedAttributes(int flags);
|
virtual void SetModifiedAttributes(int flags);
|
||||||
|
|
|
@ -61,7 +61,7 @@ public:
|
||||||
DynamicType::Ptr type = GetByName(T::GetTypeName());
|
DynamicType::Ptr type = GetByName(T::GetTypeName());
|
||||||
return std::make_pair(
|
return std::make_pair(
|
||||||
DynamicTypeIterator<T>(type, 0),
|
DynamicTypeIterator<T>(type, 0),
|
||||||
DynamicTypeIterator<T>(type, -1)
|
DynamicTypeIterator<T>(type, UINT_MAX)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -121,8 +121,8 @@ private:
|
||||||
{
|
{
|
||||||
ObjectLock olock(m_Type);
|
ObjectLock olock(m_Type);
|
||||||
|
|
||||||
if ((other.m_Index == -1 || other.m_Index >= other.m_Type->m_ObjectVector.size()) &&
|
if ((other.m_Index == UINT_MAX || other.m_Index >= other.m_Type->m_ObjectVector.size()) &&
|
||||||
(m_Index == -1 || m_Index >= m_Type->m_ObjectVector.size()))
|
(m_Index == UINT_MAX || m_Index >= m_Type->m_ObjectVector.size()))
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -28,7 +28,7 @@ REGISTER_TYPE(FileLogger);
|
||||||
|
|
||||||
REGISTER_STATSFUNCTION(FileLoggerStats, &FileLogger::StatsFunc);
|
REGISTER_STATSFUNCTION(FileLoggerStats, &FileLogger::StatsFunc);
|
||||||
|
|
||||||
Value FileLogger::StatsFunc(Dictionary::Ptr& status, Dictionary::Ptr& perfdata)
|
Value FileLogger::StatsFunc(Dictionary::Ptr& status, Dictionary::Ptr&)
|
||||||
{
|
{
|
||||||
Dictionary::Ptr nodes = make_shared<Dictionary>();
|
Dictionary::Ptr nodes = make_shared<Dictionary>();
|
||||||
|
|
||||||
|
|
|
@ -75,12 +75,13 @@ const Type *Object::GetReflectionType(void) const
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Object::SetField(int id, const Value& value)
|
void Object::SetField(int, const Value&)
|
||||||
{
|
{
|
||||||
throw std::runtime_error("Invalid field ID.");
|
BOOST_THROW_EXCEPTION(std::runtime_error("Invalid field ID."));
|
||||||
}
|
}
|
||||||
|
|
||||||
Value Object::GetField(int id) const
|
Value Object::GetField(int) const
|
||||||
{
|
{
|
||||||
throw std::runtime_error("Invalid field ID.");
|
BOOST_THROW_EXCEPTION(std::runtime_error("Invalid field ID."));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
|
|
||||||
using namespace icinga;
|
using namespace icinga;
|
||||||
|
|
||||||
const size_t String::NPos = std::string::npos;
|
const String::SizeType String::NPos = std::string::npos;
|
||||||
|
|
||||||
String::String(void)
|
String::String(void)
|
||||||
: m_Data()
|
: m_Data()
|
||||||
|
@ -41,7 +41,7 @@ String::String(const std::string& data)
|
||||||
: m_Data(data)
|
: m_Data(data)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
String::String(size_t n, char c)
|
String::String(String::SizeType n, char c)
|
||||||
: m_Data(n, c)
|
: m_Data(n, c)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
|
@ -67,12 +67,12 @@ String& String::operator=(const char *rhs)
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
const char& String::operator[](size_t pos) const
|
const char& String::operator[](String::SizeType pos) const
|
||||||
{
|
{
|
||||||
return m_Data[pos];
|
return m_Data[pos];
|
||||||
}
|
}
|
||||||
|
|
||||||
char& String::operator[](size_t pos)
|
char& String::operator[](String::SizeType pos)
|
||||||
{
|
{
|
||||||
return m_Data[pos];
|
return m_Data[pos];
|
||||||
}
|
}
|
||||||
|
@ -126,7 +126,7 @@ void String::Clear(void)
|
||||||
m_Data.clear();
|
m_Data.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t String::GetLength(void) const
|
String::SizeType String::GetLength(void) const
|
||||||
{
|
{
|
||||||
return m_Data.size();
|
return m_Data.size();
|
||||||
}
|
}
|
||||||
|
@ -141,42 +141,42 @@ const std::string& String::GetData(void) const
|
||||||
return m_Data;
|
return m_Data;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t String::Find(const String& str, size_t pos) const
|
String::SizeType String::Find(const String& str, String::SizeType pos) const
|
||||||
{
|
{
|
||||||
return m_Data.find(str, pos);
|
return m_Data.find(str, pos);
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t String::RFind(const String& str, size_t pos) const
|
String::SizeType String::RFind(const String& str, String::SizeType pos) const
|
||||||
{
|
{
|
||||||
return m_Data.rfind(str, pos);
|
return m_Data.rfind(str, pos);
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t String::FindFirstOf(const char *s, size_t pos) const
|
String::SizeType String::FindFirstOf(const char *s, String::SizeType pos) const
|
||||||
{
|
{
|
||||||
return m_Data.find_first_of(s, pos);
|
return m_Data.find_first_of(s, pos);
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t String::FindFirstOf(char ch, size_t pos) const
|
String::SizeType String::FindFirstOf(char ch, String::SizeType pos) const
|
||||||
{
|
{
|
||||||
return m_Data.find_first_of(ch, pos);
|
return m_Data.find_first_of(ch, pos);
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t String::FindFirstNotOf(const char *s, size_t pos) const
|
String::SizeType String::FindFirstNotOf(const char *s, String::SizeType pos) const
|
||||||
{
|
{
|
||||||
return m_Data.find_first_not_of(s, pos);
|
return m_Data.find_first_not_of(s, pos);
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t String::FindFirstNotOf(char ch, size_t pos) const
|
String::SizeType String::FindFirstNotOf(char ch, String::SizeType pos) const
|
||||||
{
|
{
|
||||||
return m_Data.find_first_not_of(ch, pos);
|
return m_Data.find_first_not_of(ch, pos);
|
||||||
}
|
}
|
||||||
|
|
||||||
String String::SubStr(size_t first, size_t len) const
|
String String::SubStr(String::SizeType first, String::SizeType len) const
|
||||||
{
|
{
|
||||||
return m_Data.substr(first, len);
|
return m_Data.substr(first, len);
|
||||||
}
|
}
|
||||||
|
|
||||||
void String::Replace(size_t first, size_t second, const String& str)
|
void String::Replace(String::SizeType first, String::SizeType second, const String& str)
|
||||||
{
|
{
|
||||||
m_Data.replace(first, second, str);
|
m_Data.replace(first, second, str);
|
||||||
}
|
}
|
||||||
|
|
|
@ -45,10 +45,12 @@ public:
|
||||||
typedef std::string::iterator iterator;
|
typedef std::string::iterator iterator;
|
||||||
typedef std::string::const_iterator const_iterator;
|
typedef std::string::const_iterator const_iterator;
|
||||||
|
|
||||||
|
typedef std::string::size_type SizeType;
|
||||||
|
|
||||||
String(void);
|
String(void);
|
||||||
String(const char *data);
|
String(const char *data);
|
||||||
String(const std::string& data);
|
String(const std::string& data);
|
||||||
String(size_t n, char c);
|
String(SizeType n, char c);
|
||||||
|
|
||||||
template<typename InputIterator>
|
template<typename InputIterator>
|
||||||
String(InputIterator begin, InputIterator end)
|
String(InputIterator begin, InputIterator end)
|
||||||
|
@ -61,8 +63,8 @@ public:
|
||||||
String& operator=(const std::string& rhs);
|
String& operator=(const std::string& rhs);
|
||||||
String& operator=(const char *rhs);
|
String& operator=(const char *rhs);
|
||||||
|
|
||||||
const char& operator[](size_t pos) const;
|
const char& operator[](SizeType pos) const;
|
||||||
char& operator[](size_t pos);
|
char& operator[](SizeType pos);
|
||||||
|
|
||||||
String& operator+=(const String& rhs);
|
String& operator+=(const String& rhs);
|
||||||
String& operator+=(const char *rhs);
|
String& operator+=(const char *rhs);
|
||||||
|
@ -77,19 +79,19 @@ public:
|
||||||
|
|
||||||
const char *CStr(void) const;
|
const char *CStr(void) const;
|
||||||
void Clear(void);
|
void Clear(void);
|
||||||
size_t GetLength(void) const;
|
SizeType GetLength(void) const;
|
||||||
|
|
||||||
std::string& GetData(void);
|
std::string& GetData(void);
|
||||||
const std::string& GetData(void) const;
|
const std::string& GetData(void) const;
|
||||||
|
|
||||||
size_t Find(const String& str, size_t pos = 0) const;
|
SizeType Find(const String& str, SizeType pos = 0) const;
|
||||||
size_t RFind(const String& str, size_t pos = NPos) const;
|
SizeType RFind(const String& str, SizeType pos = NPos) const;
|
||||||
size_t FindFirstOf(const char *s, size_t pos = 0) const;
|
SizeType FindFirstOf(const char *s, SizeType pos = 0) const;
|
||||||
size_t FindFirstOf(char ch, size_t pos = 0) const;
|
SizeType FindFirstOf(char ch, SizeType pos = 0) const;
|
||||||
size_t FindFirstNotOf(const char *s, size_t pos = 0) const;
|
SizeType FindFirstNotOf(const char *s, SizeType pos = 0) const;
|
||||||
size_t FindFirstNotOf(char ch, size_t pos = 0) const;
|
SizeType FindFirstNotOf(char ch, SizeType pos = 0) const;
|
||||||
String SubStr(size_t first, size_t len = NPos) const;
|
String SubStr(SizeType first, SizeType len = NPos) const;
|
||||||
void Replace(size_t first, size_t second, const String& str);
|
void Replace(SizeType first, SizeType second, const String& str);
|
||||||
|
|
||||||
void Trim(void);
|
void Trim(void);
|
||||||
bool Contains(const String& str) const;
|
bool Contains(const String& str) const;
|
||||||
|
@ -108,7 +110,7 @@ public:
|
||||||
Iterator End(void);
|
Iterator End(void);
|
||||||
ConstIterator End(void) const;
|
ConstIterator End(void) const;
|
||||||
|
|
||||||
static const size_t NPos;
|
static const SizeType NPos;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
std::string m_Data;
|
std::string m_Data;
|
||||||
|
|
|
@ -28,7 +28,7 @@ REGISTER_TYPE(SyslogLogger);
|
||||||
|
|
||||||
REGISTER_STATSFUNCTION(SyslogLoggerStats, &SyslogLogger::StatsFunc);
|
REGISTER_STATSFUNCTION(SyslogLoggerStats, &SyslogLogger::StatsFunc);
|
||||||
|
|
||||||
Value SyslogLogger::StatsFunc(Dictionary::Ptr& status, Dictionary::Ptr& perfdata)
|
Value SyslogLogger::StatsFunc(Dictionary::Ptr& status, Dictionary::Ptr&)
|
||||||
{
|
{
|
||||||
Dictionary::Ptr nodes = make_shared<Dictionary>();
|
Dictionary::Ptr nodes = make_shared<Dictionary>();
|
||||||
|
|
||||||
|
|
|
@ -50,7 +50,7 @@ ThreadPool::~ThreadPool(void)
|
||||||
|
|
||||||
void ThreadPool::Start(void)
|
void ThreadPool::Start(void)
|
||||||
{
|
{
|
||||||
for (int i = 0; i < sizeof(m_Queues) / sizeof(m_Queues[0]); i++)
|
for (size_t i = 0; i < sizeof(m_Queues) / sizeof(m_Queues[0]); i++)
|
||||||
m_Queues[i].SpawnWorker(m_ThreadGroup);
|
m_Queues[i].SpawnWorker(m_ThreadGroup);
|
||||||
|
|
||||||
m_ThreadGroup.create_thread(boost::bind(&ThreadPool::ManagerThreadProc, this));
|
m_ThreadGroup.create_thread(boost::bind(&ThreadPool::ManagerThreadProc, this));
|
||||||
|
@ -58,7 +58,7 @@ void ThreadPool::Start(void)
|
||||||
|
|
||||||
void ThreadPool::Stop(void)
|
void ThreadPool::Stop(void)
|
||||||
{
|
{
|
||||||
for (int i = 0; i < sizeof(m_Queues) / sizeof(m_Queues[0]); i++) {
|
for (size_t i = 0; i < sizeof(m_Queues) / sizeof(m_Queues[0]); i++) {
|
||||||
boost::mutex::scoped_lock lock(m_Queues[i].Mutex);
|
boost::mutex::scoped_lock lock(m_Queues[i].Mutex);
|
||||||
m_Queues[i].Stopped = true;
|
m_Queues[i].Stopped = true;
|
||||||
m_Queues[i].CV.notify_all();
|
m_Queues[i].CV.notify_all();
|
||||||
|
@ -79,7 +79,7 @@ void ThreadPool::Join(bool wait_for_stop)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (int i = 0; i < sizeof(m_Queues) / sizeof(m_Queues[0]); i++) {
|
for (size_t i = 0; i < sizeof(m_Queues) / sizeof(m_Queues[0]); i++) {
|
||||||
boost::mutex::scoped_lock lock(m_Queues[i].Mutex);
|
boost::mutex::scoped_lock lock(m_Queues[i].Mutex);
|
||||||
|
|
||||||
while (!m_Queues[i].Items.empty())
|
while (!m_Queues[i].Items.empty())
|
||||||
|
|
|
@ -25,7 +25,7 @@ namespace icinga
|
||||||
static bool l_SSLInitialized = false;
|
static bool l_SSLInitialized = false;
|
||||||
static boost::mutex *l_Mutexes;
|
static boost::mutex *l_Mutexes;
|
||||||
|
|
||||||
static void OpenSSLLockingCallback(int mode, int type, const char *file, int line)
|
static void OpenSSLLockingCallback(int mode, int type, const char *, int)
|
||||||
{
|
{
|
||||||
if (mode & CRYPTO_LOCK)
|
if (mode & CRYPTO_LOCK)
|
||||||
l_Mutexes[type].lock();
|
l_Mutexes[type].lock();
|
||||||
|
|
|
@ -116,7 +116,7 @@ size_t WorkQueue::GetLength(void)
|
||||||
return m_Items.size();
|
return m_Items.size();
|
||||||
}
|
}
|
||||||
|
|
||||||
void WorkQueue::DefaultExceptionCallback(boost::exception_ptr exp)
|
void WorkQueue::DefaultExceptionCallback(boost::exception_ptr)
|
||||||
{
|
{
|
||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
|
|
|
@ -109,7 +109,7 @@ Value AExpression::EvaluateOperand2(const Dictionary::Ptr& locals) const
|
||||||
return static_cast<AExpression::Ptr>(m_Operand2)->Evaluate(locals);
|
return static_cast<AExpression::Ptr>(m_Operand2)->Evaluate(locals);
|
||||||
}
|
}
|
||||||
|
|
||||||
Value AExpression::OpLiteral(const AExpression *expr, const Dictionary::Ptr& locals)
|
Value AExpression::OpLiteral(const AExpression *expr, const Dictionary::Ptr&)
|
||||||
{
|
{
|
||||||
return expr->m_Operand1;
|
return expr->m_Operand1;
|
||||||
}
|
}
|
||||||
|
@ -263,7 +263,6 @@ Value AExpression::OpFunctionCall(const AExpression *expr, const Dictionary::Ptr
|
||||||
|
|
||||||
Array::Ptr arr = expr->EvaluateOperand2(locals);
|
Array::Ptr arr = expr->EvaluateOperand2(locals);
|
||||||
std::vector<Value> arguments;
|
std::vector<Value> arguments;
|
||||||
int index = 0;
|
|
||||||
for (Array::SizeType index = 0; index < arr->GetLength(); index++) {
|
for (Array::SizeType index = 0; index < arr->GetLength(); index++) {
|
||||||
const AExpression::Ptr& aexpr = arr->Get(index);
|
const AExpression::Ptr& aexpr = arr->Get(index);
|
||||||
arguments.push_back(aexpr->Evaluate(locals));
|
arguments.push_back(aexpr->Evaluate(locals));
|
||||||
|
@ -278,7 +277,6 @@ Value AExpression::OpArray(const AExpression *expr, const Dictionary::Ptr& local
|
||||||
Array::Ptr result = make_shared<Array>();
|
Array::Ptr result = make_shared<Array>();
|
||||||
|
|
||||||
if (arr) {
|
if (arr) {
|
||||||
int index = 0;
|
|
||||||
for (Array::SizeType index = 0; index < arr->GetLength(); index++) {
|
for (Array::SizeType index = 0; index < arr->GetLength(); index++) {
|
||||||
const AExpression::Ptr& aexpr = arr->Get(index);
|
const AExpression::Ptr& aexpr = arr->Get(index);
|
||||||
result->Add(aexpr->Evaluate(locals));
|
result->Add(aexpr->Evaluate(locals));
|
||||||
|
@ -297,7 +295,6 @@ Value AExpression::OpDict(const AExpression *expr, const Dictionary::Ptr& locals
|
||||||
result->Set("__parent", locals);
|
result->Set("__parent", locals);
|
||||||
|
|
||||||
if (arr) {
|
if (arr) {
|
||||||
int index = 0;
|
|
||||||
for (Array::SizeType index = 0; index < arr->GetLength(); index++) {
|
for (Array::SizeType index = 0; index < arr->GetLength(); index++) {
|
||||||
const AExpression::Ptr& aexpr = arr->Get(index);
|
const AExpression::Ptr& aexpr = arr->Get(index);
|
||||||
Dictionary::Ptr alocals = in_place ? locals : result;
|
Dictionary::Ptr alocals = in_place ? locals : result;
|
||||||
|
|
|
@ -138,7 +138,7 @@ void ConfigCompiler::HandleInclude(const String& include, bool search, const Deb
|
||||||
* @param pattern The file pattern.
|
* @param pattern The file pattern.
|
||||||
* @param debuginfo Debug information.
|
* @param debuginfo Debug information.
|
||||||
*/
|
*/
|
||||||
void ConfigCompiler::HandleIncludeRecursive(const String& include, const String& pattern, const DebugInfo& debuginfo)
|
void ConfigCompiler::HandleIncludeRecursive(const String& include, const String& pattern, const DebugInfo&)
|
||||||
{
|
{
|
||||||
String path;
|
String path;
|
||||||
|
|
||||||
|
|
|
@ -44,7 +44,7 @@ using namespace icinga;
|
||||||
|
|
||||||
INITIALIZE_ONCE(&ExternalCommandProcessor::StaticInitialize);
|
INITIALIZE_ONCE(&ExternalCommandProcessor::StaticInitialize);
|
||||||
|
|
||||||
typedef boost::function<void (double time, const std::vector<String>& arguments)> ExternalCommandCallback;
|
typedef boost::function<void (double, const std::vector<String>& arguments)> ExternalCommandCallback;
|
||||||
|
|
||||||
struct ExternalCommandInfo
|
struct ExternalCommandInfo
|
||||||
{
|
{
|
||||||
|
@ -1560,91 +1560,91 @@ void ExternalCommandProcessor::DisableSvcFlapping(double, const std::vector<Stri
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::EnableNotifications(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::EnableNotifications(double, const std::vector<String>&)
|
||||||
{
|
{
|
||||||
Log(LogInformation, "icinga", "Globally enabling notifications.");
|
Log(LogInformation, "icinga", "Globally enabling notifications.");
|
||||||
|
|
||||||
IcingaApplication::GetInstance()->SetEnableNotifications(true);
|
IcingaApplication::GetInstance()->SetEnableNotifications(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::DisableNotifications(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::DisableNotifications(double, const std::vector<String>&)
|
||||||
{
|
{
|
||||||
Log(LogInformation, "icinga", "Globally disabling notifications.");
|
Log(LogInformation, "icinga", "Globally disabling notifications.");
|
||||||
|
|
||||||
IcingaApplication::GetInstance()->SetEnableNotifications(false);
|
IcingaApplication::GetInstance()->SetEnableNotifications(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::EnableFlapDetection(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::EnableFlapDetection(double, const std::vector<String>&)
|
||||||
{
|
{
|
||||||
Log(LogInformation, "icinga", "Globally enabling flap detection.");
|
Log(LogInformation, "icinga", "Globally enabling flap detection.");
|
||||||
|
|
||||||
IcingaApplication::GetInstance()->SetEnableFlapping(true);
|
IcingaApplication::GetInstance()->SetEnableFlapping(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::DisableFlapDetection(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::DisableFlapDetection(double, const std::vector<String>&)
|
||||||
{
|
{
|
||||||
Log(LogInformation, "icinga", "Globally disabling flap detection.");
|
Log(LogInformation, "icinga", "Globally disabling flap detection.");
|
||||||
|
|
||||||
IcingaApplication::GetInstance()->SetEnableFlapping(false);
|
IcingaApplication::GetInstance()->SetEnableFlapping(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::EnableEventHandlers(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::EnableEventHandlers(double, const std::vector<String>&)
|
||||||
{
|
{
|
||||||
Log(LogInformation, "icinga", "Globally enabling event handlers.");
|
Log(LogInformation, "icinga", "Globally enabling event handlers.");
|
||||||
|
|
||||||
IcingaApplication::GetInstance()->SetEnableEventHandlers(true);
|
IcingaApplication::GetInstance()->SetEnableEventHandlers(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::DisableEventHandlers(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::DisableEventHandlers(double, const std::vector<String>&)
|
||||||
{
|
{
|
||||||
Log(LogInformation, "icinga", "Globally disabling event handlers.");
|
Log(LogInformation, "icinga", "Globally disabling event handlers.");
|
||||||
|
|
||||||
IcingaApplication::GetInstance()->SetEnableEventHandlers(false);
|
IcingaApplication::GetInstance()->SetEnableEventHandlers(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::EnablePerformanceData(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::EnablePerformanceData(double, const std::vector<String>&)
|
||||||
{
|
{
|
||||||
Log(LogInformation, "icinga", "Globally enabling performance data processing.");
|
Log(LogInformation, "icinga", "Globally enabling performance data processing.");
|
||||||
|
|
||||||
IcingaApplication::GetInstance()->SetEnablePerfdata(true);
|
IcingaApplication::GetInstance()->SetEnablePerfdata(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::DisablePerformanceData(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::DisablePerformanceData(double, const std::vector<String>&)
|
||||||
{
|
{
|
||||||
Log(LogInformation, "icinga", "Globally disabling performance data processing.");
|
Log(LogInformation, "icinga", "Globally disabling performance data processing.");
|
||||||
|
|
||||||
IcingaApplication::GetInstance()->SetEnablePerfdata(false);
|
IcingaApplication::GetInstance()->SetEnablePerfdata(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::StartExecutingSvcChecks(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::StartExecutingSvcChecks(double, const std::vector<String>&)
|
||||||
{
|
{
|
||||||
Log(LogInformation, "icinga", "Globally enabling service checks.");
|
Log(LogInformation, "icinga", "Globally enabling service checks.");
|
||||||
|
|
||||||
IcingaApplication::GetInstance()->SetEnableServiceChecks(true);
|
IcingaApplication::GetInstance()->SetEnableServiceChecks(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::StopExecutingSvcChecks(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::StopExecutingSvcChecks(double, const std::vector<String>&)
|
||||||
{
|
{
|
||||||
Log(LogInformation, "icinga", "Globally disabling service checks.");
|
Log(LogInformation, "icinga", "Globally disabling service checks.");
|
||||||
|
|
||||||
IcingaApplication::GetInstance()->SetEnableServiceChecks(false);
|
IcingaApplication::GetInstance()->SetEnableServiceChecks(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::StartExecutingHostChecks(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::StartExecutingHostChecks(double, const std::vector<String>&)
|
||||||
{
|
{
|
||||||
Log(LogInformation, "icinga", "Globally enabling host checks.");
|
Log(LogInformation, "icinga", "Globally enabling host checks.");
|
||||||
|
|
||||||
IcingaApplication::GetInstance()->SetEnableHostChecks(true);
|
IcingaApplication::GetInstance()->SetEnableHostChecks(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::StopExecutingHostChecks(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::StopExecutingHostChecks(double, const std::vector<String>&)
|
||||||
{
|
{
|
||||||
Log(LogInformation, "icinga", "Globally disabling host checks.");
|
Log(LogInformation, "icinga", "Globally disabling host checks.");
|
||||||
|
|
||||||
IcingaApplication::GetInstance()->SetEnableHostChecks(false);
|
IcingaApplication::GetInstance()->SetEnableHostChecks(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeSvcModattr(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeSvcModattr(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
||||||
|
|
||||||
|
@ -1662,7 +1662,7 @@ void ExternalCommandProcessor::ChangeSvcModattr(double time, const std::vector<S
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeHostModattr(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeHostModattr(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Host::Ptr host = Host::GetByName(arguments[0]);
|
Host::Ptr host = Host::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -1680,7 +1680,7 @@ void ExternalCommandProcessor::ChangeHostModattr(double time, const std::vector<
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeUserModattr(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeUserModattr(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
User::Ptr user = User::GetByName(arguments[0]);
|
User::Ptr user = User::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -1698,7 +1698,7 @@ void ExternalCommandProcessor::ChangeUserModattr(double time, const std::vector<
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeCheckcommandModattr(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeCheckcommandModattr(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
CheckCommand::Ptr command = CheckCommand::GetByName(arguments[0]);
|
CheckCommand::Ptr command = CheckCommand::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -1708,7 +1708,7 @@ void ExternalCommandProcessor::ChangeCheckcommandModattr(double time, const std:
|
||||||
ChangeCommandModattrInternal(command, Convert::ToLong(arguments[1]));
|
ChangeCommandModattrInternal(command, Convert::ToLong(arguments[1]));
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeEventcommandModattr(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeEventcommandModattr(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
EventCommand::Ptr command = EventCommand::GetByName(arguments[0]);
|
EventCommand::Ptr command = EventCommand::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -1718,7 +1718,7 @@ void ExternalCommandProcessor::ChangeEventcommandModattr(double time, const std:
|
||||||
ChangeCommandModattrInternal(command, Convert::ToLong(arguments[1]));
|
ChangeCommandModattrInternal(command, Convert::ToLong(arguments[1]));
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeNotificationcommandModattr(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeNotificationcommandModattr(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
NotificationCommand::Ptr command = NotificationCommand::GetByName(arguments[0]);
|
NotificationCommand::Ptr command = NotificationCommand::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -1739,7 +1739,7 @@ void ExternalCommandProcessor::ChangeCommandModattrInternal(const Command::Ptr&
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeNormalSvcCheckInterval(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeNormalSvcCheckInterval(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
||||||
|
|
||||||
|
@ -1757,7 +1757,7 @@ void ExternalCommandProcessor::ChangeNormalSvcCheckInterval(double time, const s
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeNormalHostCheckInterval(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeNormalHostCheckInterval(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Host::Ptr host = Host::GetByName(arguments[0]);
|
Host::Ptr host = Host::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -1775,7 +1775,7 @@ void ExternalCommandProcessor::ChangeNormalHostCheckInterval(double time, const
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeRetrySvcCheckInterval(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeRetrySvcCheckInterval(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
||||||
|
|
||||||
|
@ -1793,7 +1793,7 @@ void ExternalCommandProcessor::ChangeRetrySvcCheckInterval(double time, const st
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeRetryHostCheckInterval(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeRetryHostCheckInterval(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Host::Ptr host = Host::GetByName(arguments[0]);
|
Host::Ptr host = Host::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -1811,7 +1811,7 @@ void ExternalCommandProcessor::ChangeRetryHostCheckInterval(double time, const s
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::EnableHostEventHandler(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::EnableHostEventHandler(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Host::Ptr host = Host::GetByName(arguments[0]);
|
Host::Ptr host = Host::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -1827,7 +1827,7 @@ void ExternalCommandProcessor::EnableHostEventHandler(double time, const std::ve
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::DisableHostEventHandler(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::DisableHostEventHandler(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Host::Ptr host = Host::GetByName(arguments[0]);
|
Host::Ptr host = Host::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -1843,7 +1843,7 @@ void ExternalCommandProcessor::DisableHostEventHandler(double time, const std::v
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::EnableSvcEventHandler(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::EnableSvcEventHandler(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
||||||
|
|
||||||
|
@ -1859,7 +1859,7 @@ void ExternalCommandProcessor::EnableSvcEventHandler(double time, const std::vec
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::DisableSvcEventHandler(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::DisableSvcEventHandler(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
||||||
|
|
||||||
|
@ -1875,7 +1875,7 @@ void ExternalCommandProcessor::DisableSvcEventHandler(double time, const std::ve
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeHostEventHandler(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeHostEventHandler(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Host::Ptr host = Host::GetByName(arguments[0]);
|
Host::Ptr host = Host::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -1901,7 +1901,7 @@ void ExternalCommandProcessor::ChangeHostEventHandler(double time, const std::ve
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeSvcEventHandler(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeSvcEventHandler(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
||||||
|
|
||||||
|
@ -1927,7 +1927,7 @@ void ExternalCommandProcessor::ChangeSvcEventHandler(double time, const std::vec
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeHostCheckCommand(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeHostCheckCommand(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Host::Ptr host = Host::GetByName(arguments[0]);
|
Host::Ptr host = Host::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -1948,7 +1948,7 @@ void ExternalCommandProcessor::ChangeHostCheckCommand(double time, const std::ve
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeSvcCheckCommand(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeSvcCheckCommand(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
||||||
|
|
||||||
|
@ -1969,7 +1969,7 @@ void ExternalCommandProcessor::ChangeSvcCheckCommand(double time, const std::vec
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeMaxHostCheckAttempts(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeMaxHostCheckAttempts(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Host::Ptr host = Host::GetByName(arguments[0]);
|
Host::Ptr host = Host::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -1987,7 +1987,7 @@ void ExternalCommandProcessor::ChangeMaxHostCheckAttempts(double time, const std
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeMaxSvcCheckAttempts(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeMaxSvcCheckAttempts(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
||||||
|
|
||||||
|
@ -2005,7 +2005,7 @@ void ExternalCommandProcessor::ChangeMaxSvcCheckAttempts(double time, const std:
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeHostCheckTimeperiod(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeHostCheckTimeperiod(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Host::Ptr host = Host::GetByName(arguments[0]);
|
Host::Ptr host = Host::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -2026,7 +2026,7 @@ void ExternalCommandProcessor::ChangeHostCheckTimeperiod(double time, const std:
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeSvcCheckTimeperiod(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeSvcCheckTimeperiod(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
||||||
|
|
||||||
|
@ -2047,7 +2047,7 @@ void ExternalCommandProcessor::ChangeSvcCheckTimeperiod(double time, const std::
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeCustomHostVar(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeCustomHostVar(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Host::Ptr host = Host::GetByName(arguments[0]);
|
Host::Ptr host = Host::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -2072,7 +2072,7 @@ void ExternalCommandProcessor::ChangeCustomHostVar(double time, const std::vecto
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeCustomSvcVar(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeCustomSvcVar(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]);
|
||||||
|
|
||||||
|
@ -2099,7 +2099,7 @@ void ExternalCommandProcessor::ChangeCustomSvcVar(double time, const std::vector
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeCustomUserVar(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeCustomUserVar(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
User::Ptr user = User::GetByName(arguments[0]);
|
User::Ptr user = User::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -2124,7 +2124,7 @@ void ExternalCommandProcessor::ChangeCustomUserVar(double time, const std::vecto
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeCustomCheckcommandVar(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeCustomCheckcommandVar(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
CheckCommand::Ptr command = CheckCommand::GetByName(arguments[0]);
|
CheckCommand::Ptr command = CheckCommand::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -2134,7 +2134,7 @@ void ExternalCommandProcessor::ChangeCustomCheckcommandVar(double time, const st
|
||||||
ChangeCustomCommandVarInternal(command, arguments[1], arguments[2]);
|
ChangeCustomCommandVarInternal(command, arguments[1], arguments[2]);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeCustomEventcommandVar(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeCustomEventcommandVar(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
EventCommand::Ptr command = EventCommand::GetByName(arguments[0]);
|
EventCommand::Ptr command = EventCommand::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -2144,7 +2144,7 @@ void ExternalCommandProcessor::ChangeCustomEventcommandVar(double time, const st
|
||||||
ChangeCustomCommandVarInternal(command, arguments[1], arguments[2]);
|
ChangeCustomCommandVarInternal(command, arguments[1], arguments[2]);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::ChangeCustomNotificationcommandVar(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::ChangeCustomNotificationcommandVar(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
NotificationCommand::Ptr command = NotificationCommand::GetByName(arguments[0]);
|
NotificationCommand::Ptr command = NotificationCommand::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -2174,7 +2174,7 @@ void ExternalCommandProcessor::ChangeCustomCommandVarInternal(const Command::Ptr
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::EnableHostgroupHostNotifications(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::EnableHostgroupHostNotifications(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
HostGroup::Ptr hg = HostGroup::GetByName(arguments[0]);
|
HostGroup::Ptr hg = HostGroup::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -2192,7 +2192,7 @@ void ExternalCommandProcessor::EnableHostgroupHostNotifications(double time, con
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::EnableHostgroupSvcNotifications(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::EnableHostgroupSvcNotifications(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
HostGroup::Ptr hg = HostGroup::GetByName(arguments[0]);
|
HostGroup::Ptr hg = HostGroup::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -2212,7 +2212,7 @@ void ExternalCommandProcessor::EnableHostgroupSvcNotifications(double time, cons
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::DisableHostgroupHostNotifications(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::DisableHostgroupHostNotifications(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
HostGroup::Ptr hg = HostGroup::GetByName(arguments[0]);
|
HostGroup::Ptr hg = HostGroup::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -2230,7 +2230,7 @@ void ExternalCommandProcessor::DisableHostgroupHostNotifications(double time, co
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::DisableHostgroupSvcNotifications(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::DisableHostgroupSvcNotifications(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
HostGroup::Ptr hg = HostGroup::GetByName(arguments[0]);
|
HostGroup::Ptr hg = HostGroup::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -2250,7 +2250,7 @@ void ExternalCommandProcessor::DisableHostgroupSvcNotifications(double time, con
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::EnableServicegroupHostNotifications(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::EnableServicegroupHostNotifications(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
ServiceGroup::Ptr sg = ServiceGroup::GetByName(arguments[0]);
|
ServiceGroup::Ptr sg = ServiceGroup::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -2270,7 +2270,7 @@ void ExternalCommandProcessor::EnableServicegroupHostNotifications(double time,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::EnableServicegroupSvcNotifications(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::EnableServicegroupSvcNotifications(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
ServiceGroup::Ptr sg = ServiceGroup::GetByName(arguments[0]);
|
ServiceGroup::Ptr sg = ServiceGroup::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -2288,7 +2288,7 @@ void ExternalCommandProcessor::EnableServicegroupSvcNotifications(double time, c
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::DisableServicegroupHostNotifications(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::DisableServicegroupHostNotifications(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
ServiceGroup::Ptr sg = ServiceGroup::GetByName(arguments[0]);
|
ServiceGroup::Ptr sg = ServiceGroup::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
@ -2308,7 +2308,7 @@ void ExternalCommandProcessor::DisableServicegroupHostNotifications(double time,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExternalCommandProcessor::DisableServicegroupSvcNotifications(double time, const std::vector<String>& arguments)
|
void ExternalCommandProcessor::DisableServicegroupSvcNotifications(double, const std::vector<String>& arguments)
|
||||||
{
|
{
|
||||||
ServiceGroup::Ptr sg = ServiceGroup::GetByName(arguments[0]);
|
ServiceGroup::Ptr sg = ServiceGroup::GetByName(arguments[0]);
|
||||||
|
|
||||||
|
|
|
@ -53,28 +53,28 @@ size_t ClassCompiler::ReadInput(char *buffer, size_t max_size)
|
||||||
return static_cast<size_t>(m_Input->gcount());
|
return static_cast<size_t>(m_Input->gcount());
|
||||||
}
|
}
|
||||||
|
|
||||||
void ClassCompiler::HandleInclude(const std::string& path, const ClassDebugInfo& locp)
|
void ClassCompiler::HandleInclude(const std::string& path, const ClassDebugInfo&)
|
||||||
{
|
{
|
||||||
std::cout << "#include \"" << path << "\"" << std::endl << std::endl;
|
std::cout << "#include \"" << path << "\"" << std::endl << std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
void ClassCompiler::HandleAngleInclude(const std::string& path, const ClassDebugInfo& locp)
|
void ClassCompiler::HandleAngleInclude(const std::string& path, const ClassDebugInfo&)
|
||||||
{
|
{
|
||||||
std::cout << "#include <" << path << ">" << std::endl << std::endl;
|
std::cout << "#include <" << path << ">" << std::endl << std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
void ClassCompiler::HandleNamespaceBegin(const std::string& name, const ClassDebugInfo& locp)
|
void ClassCompiler::HandleNamespaceBegin(const std::string& name, const ClassDebugInfo&)
|
||||||
{
|
{
|
||||||
std::cout << "namespace " << name << std::endl
|
std::cout << "namespace " << name << std::endl
|
||||||
<< "{" << std::endl << std::endl;
|
<< "{" << std::endl << std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
void ClassCompiler::HandleNamespaceEnd(const ClassDebugInfo& locp)
|
void ClassCompiler::HandleNamespaceEnd(const ClassDebugInfo&)
|
||||||
{
|
{
|
||||||
std::cout << "}" << std::endl;
|
std::cout << "}" << std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
void ClassCompiler::HandleCode(const std::string& code, const ClassDebugInfo& locp)
|
void ClassCompiler::HandleCode(const std::string& code, const ClassDebugInfo&)
|
||||||
{
|
{
|
||||||
std::cout << code << std::endl;
|
std::cout << code << std::endl;
|
||||||
}
|
}
|
||||||
|
@ -100,7 +100,7 @@ unsigned long ClassCompiler::SDBM(const std::string& str, size_t len = std::stri
|
||||||
return hash;
|
return hash;
|
||||||
}
|
}
|
||||||
|
|
||||||
void ClassCompiler::HandleClass(const Klass& klass, const ClassDebugInfo& locp)
|
void ClassCompiler::HandleClass(const Klass& klass, const ClassDebugInfo&)
|
||||||
{
|
{
|
||||||
std::vector<Field>::const_iterator it;
|
std::vector<Field>::const_iterator it;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue