aboutsummaryrefslogtreecommitdiffstats
path: root/pcp/PCPDynamicColumn.h
diff options
context:
space:
mode:
authorDaniel Lange <DLange@git.local>2021-09-21 08:35:20 +0200
committerDaniel Lange <DLange@git.local>2021-09-21 08:35:20 +0200
commita2b6942d15d220bb0518003d4f818a922d88e9f9 (patch)
tree7f60a44dec34af24da75b8d5b68c88eca94b9f6a /pcp/PCPDynamicColumn.h
parent37d8824862a2f6b9375022e1c45ba4548162650f (diff)
parent69f439eff387a6ecb52734e400b297a3c85f2285 (diff)
downloaddebian_htop-a2b6942d15d220bb0518003d4f818a922d88e9f9.tar.gz
debian_htop-a2b6942d15d220bb0518003d4f818a922d88e9f9.tar.bz2
debian_htop-a2b6942d15d220bb0518003d4f818a922d88e9f9.zip
Update upstream source from tag 'upstream/3.1.0'
Update to upstream version '3.1.0' with Debian dir d4ecdd99a38d7105de46689cebcb051bf0046a76
Diffstat (limited to 'pcp/PCPDynamicColumn.h')
-rw-r--r--pcp/PCPDynamicColumn.h35
1 files changed, 35 insertions, 0 deletions
diff --git a/pcp/PCPDynamicColumn.h b/pcp/PCPDynamicColumn.h
new file mode 100644
index 0000000..d0ffe71
--- /dev/null
+++ b/pcp/PCPDynamicColumn.h
@@ -0,0 +1,35 @@
+#ifndef HEADER_PCPDynamicColumn
+#define HEADER_PCPDynamicColumn
+
+#include <stddef.h>
+
+#include "DynamicColumn.h"
+#include "Hashtable.h"
+#include "Process.h"
+#include "RichString.h"
+
+#include "pcp/PCPProcess.h"
+
+
+typedef struct PCPDynamicColumn_ {
+ DynamicColumn super;
+ char* metricName;
+ size_t id; /* identifier for metric array lookups */
+} PCPDynamicColumn;
+
+typedef struct PCPDynamicColumns_ {
+ Hashtable* table;
+ size_t count; /* count of dynamic meters discovered by scan */
+ size_t offset; /* start offset into the Platform metric array */
+ size_t cursor; /* identifier allocator for each new metric used */
+} PCPDynamicColumns;
+
+void PCPDynamicColumns_init(PCPDynamicColumns* columns);
+
+void PCPDynamicColumns_done(Hashtable* table);
+
+void PCPDynamicColumn_writeField(PCPDynamicColumn* this, const Process* proc, RichString* str);
+
+int PCPDynamicColumn_compareByKey(const PCPProcess* p1, const PCPProcess* p2, ProcessField key);
+
+#endif

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