aboutsummaryrefslogtreecommitdiffstats
path: root/pcp/Instance.h
diff options
context:
space:
mode:
authorDaniel Lange <DLange@git.local>2024-01-10 12:40:37 +0100
committerDaniel Lange <DLange@git.local>2024-01-10 12:40:37 +0100
commit7271b076b82785ffca73ee9e4ae84cabb77018ee (patch)
treee8270dd60ec096bee8157dbadf029e15ed584592 /pcp/Instance.h
parentf288666edc9180a2e81e6655951878124f321df6 (diff)
downloaddebian_htop-7271b076b82785ffca73ee9e4ae84cabb77018ee.tar.gz
debian_htop-7271b076b82785ffca73ee9e4ae84cabb77018ee.tar.bz2
debian_htop-7271b076b82785ffca73ee9e4ae84cabb77018ee.zip
New upstream version 3.3.0upstream/3.3.0upstream
Diffstat (limited to 'pcp/Instance.h')
-rw-r--r--pcp/Instance.h37
1 files changed, 37 insertions, 0 deletions
diff --git a/pcp/Instance.h b/pcp/Instance.h
new file mode 100644
index 0000000..aefd642
--- /dev/null
+++ b/pcp/Instance.h
@@ -0,0 +1,37 @@
+#ifndef HEADER_Instance
+#define HEADER_Instance
+/*
+htop - Instance.h
+(C) 2022-2023 htop dev team
+(C) 2022-2023 Sohaib Mohammed
+Released under the GNU GPLv2+, see the COPYING file
+in the source distribution for its full text.
+*/
+
+#include "Hashtable.h"
+#include "Object.h"
+#include "Platform.h"
+#include "Row.h"
+
+
+typedef struct Instance_ {
+ Row super;
+
+ char* name; /* external instance name */
+ const struct InDomTable_* indom; /* instance domain */
+
+ /* default result offset to use for searching metrics with instances */
+ unsigned int offset;
+} Instance;
+
+#define InDom_getId(i_) ((i_)->indom->id)
+#define Instance_getId(i_) ((i_)->super.id)
+#define Instance_setId(i_, id_) ((i_)->super.id = (id_))
+
+extern const RowClass Instance_class;
+
+Instance* Instance_new(const Machine* host, const struct InDomTable_* indom);
+
+void Instance_done(Instance* this);
+
+#endif

© 2014-2024 Faster IT GmbH | imprint | privacy policy