/******************************************************************************
* Icinga 2 *
- * Copyright (C) 2012-2017 Icinga Development Team (https://www.icinga.com/) *
+ * Copyright (C) 2012-2018 Icinga Development Team (https://www.icinga.com/) *
* *
* This program is free software; you can redistribute it and/or *
* modify it under the terms of the GNU General Public License *
using namespace icinga;
-CommandsTable::CommandsTable(void)
+CommandsTable::CommandsTable()
{
AddColumns(this);
}
void CommandsTable::AddColumns(Table *table, const String& prefix,
- const Column::ObjectAccessor& objectAccessor)
+ const Column::ObjectAccessor& objectAccessor)
{
table->AddColumn(prefix + "name", Column(&CommandsTable::NameAccessor, objectAccessor));
table->AddColumn(prefix + "line", Column(&CommandsTable::LineAccessor, objectAccessor));
table->AddColumn(prefix + "modified_attributes_list", Column(&Table::ZeroAccessor, objectAccessor));
}
-String CommandsTable::GetName(void) const
+String CommandsTable::GetName() const
{
return "commands";
}
-String CommandsTable::GetPrefix(void) const
+String CommandsTable::GetPrefix() const
{
return "command";
}
vars = CompatUtility::GetCustomAttributeConfig(command);
}
- if (!vars)
- return Empty;
-
Array::Ptr cv = new Array();
+ if (!vars)
+ return cv;
+
{
ObjectLock xlock(vars);
for (const auto& kv : vars) {
vars = CompatUtility::GetCustomAttributeConfig(command);
}
- if (!vars)
- return Empty;
-
Array::Ptr cv = new Array();
+ if (!vars)
+ return cv;
+
{
ObjectLock xlock(vars);
for (const auto& kv : vars) {
vars = CompatUtility::GetCustomAttributeConfig(command);
}
- if (!vars)
- return Empty;
-
Array::Ptr cv = new Array();
+ if (!vars)
+ return cv;
+
{
ObjectLock xlock(vars);
for (const auto& kv : vars) {