Module: check_mk
Branch: master
Commit: 0d3ab38efdc176ca7519b6403f4f4d16ca53c6ec
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=0d3ab38efdc176…
Author: Sven Panne <sp(a)mathias-kettner.de>
Date: Thu Jan 14 14:32:23 2016 +0100
Add extra_offset to DynamicColumn.
---
livestatus/src/DynamicColumn.cc | 2 +-
livestatus/src/DynamicColumn.h | 7 ++++---
2 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/livestatus/src/DynamicColumn.cc b/livestatus/src/DynamicColumn.cc
index e281e0a..9efd7dc 100644
--- a/livestatus/src/DynamicColumn.cc
+++ b/livestatus/src/DynamicColumn.cc
@@ -30,5 +30,5 @@ DynamicColumn::~DynamicColumn()
Column *DynamicColumn::createColumn(const char *arguments)
{
- return createColumn(_indirect_offset, arguments);
+ return createColumn(_indirect_offset, _extra_offset, arguments);
}
diff --git a/livestatus/src/DynamicColumn.h b/livestatus/src/DynamicColumn.h
index 3c3771f..92d9738 100644
--- a/livestatus/src/DynamicColumn.h
+++ b/livestatus/src/DynamicColumn.h
@@ -35,14 +35,15 @@ class DynamicColumn
std::string _name;
std::string _description;
int _indirect_offset;
+ int _extra_offset;
public:
- DynamicColumn(std::string name, std::string description, int indirect_offset) :
- _name(name), _description(description), _indirect_offset(indirect_offset) {}
+ DynamicColumn(std::string name, std::string description, int indirect_offset, int
extra_offset) :
+ _name(name), _description(description), _indirect_offset(indirect_offset),
_extra_offset(extra_offset) {}
virtual ~DynamicColumn();
const char *name() const { return _name.c_str(); }
const char *description() const { return _description.c_str(); }
Column *createColumn(const char *arguments);
- virtual Column *createColumn(int indirect_offset, const char *arguments) = 0;
+ virtual Column *createColumn(int indirect_offset, int extra_offset, const char
*arguments) = 0;
};
#endif // DynamicColumn_h