aboutsummaryrefslogtreecommitdiffstats
path: root/Process.h
diff options
context:
space:
mode:
authorDaniel Lange <DLange@git.local>2016-04-11 13:00:22 +0200
committerDaniel Lange <DLange@git.local>2016-04-11 13:00:22 +0200
commitc74c38760df69bb87e93dff18cf91464e5d02f37 (patch)
treeee2a19a0ef3a808bdfc8c1e6a00e96d79966dcb0 /Process.h
parent9379132a8234eeedf62d37ef57713e52c12db6ab (diff)
downloaddebian_htop-c74c38760df69bb87e93dff18cf91464e5d02f37.tar.gz
debian_htop-c74c38760df69bb87e93dff18cf91464e5d02f37.tar.bz2
debian_htop-c74c38760df69bb87e93dff18cf91464e5d02f37.zip
Imported Upstream version 0.8.1upstream/0.8.1
Diffstat (limited to 'Process.h')
-rw-r--r--Process.h47
1 files changed, 34 insertions, 13 deletions
diff --git a/Process.h b/Process.h
index 778d464..3cac731 100644
--- a/Process.h
+++ b/Process.h
@@ -14,6 +14,7 @@ in the source distribution for its full text.
#include "Object.h"
#include "CRT.h"
#include "String.h"
+#include "RichString.h"
#include "debug.h"
@@ -30,6 +31,8 @@ in the source distribution for its full text.
#include <pwd.h>
#include <sched.h>
+#include <plpa.h>
+
// This works only with glibc 2.1+. On earlier versions
// the behavior is similar to have a hardcoded page size.
#ifndef PAGE_SIZE
@@ -48,6 +51,12 @@ typedef enum ProcessField_ {
#ifdef HAVE_OPENVZ
VEID, VPID,
#endif
+ #ifdef HAVE_VSERVER
+ VXID,
+ #endif
+ #ifdef HAVE_TASKSTATS
+ RCHAR, WCHAR, SYSCR, SYSCW, RBYTES, WBYTES, CNCLWB, IO_READ_RATE, IO_WRITE_RATE, IO_RATE,
+ #endif
LAST_PROCESSFIELD
} ProcessField;
@@ -120,6 +129,22 @@ typedef struct Process_ {
unsigned int veid;
unsigned int vpid;
#endif
+ #ifdef HAVE_VSERVER
+ unsigned int vxid;
+ #endif
+ #ifdef HAVE_TASKSTATS
+ unsigned long long io_rchar;
+ unsigned long long io_wchar;
+ unsigned long long io_syscr;
+ unsigned long long io_syscw;
+ unsigned long long io_read_bytes;
+ unsigned long long io_write_bytes;
+ unsigned long long io_cancelled_write_bytes;
+ double io_rate_read_bps;
+ unsigned long long io_rate_read_time;
+ double io_rate_write_bps;
+ unsigned long long io_rate_write_time;
+ #endif
} Process;
@@ -131,34 +156,30 @@ extern char* PROCESS_CLASS;
extern char *Process_fieldNames[];
-Process* Process_new(struct ProcessList_ *pl);
+extern char *Process_fieldTitles[];
-Process* Process_clone(Process* this);
+#define ONE_K 1024
+#define ONE_M (ONE_K * ONE_K)
+#define ONE_G (ONE_M * ONE_K)
void Process_delete(Object* cast);
-void Process_display(Object* cast, RichString* out);
+Process* Process_new(struct ProcessList_ *pl);
+
+Process* Process_clone(Process* this);
void Process_toggleTag(Process* this);
-void Process_setPriority(Process* this, int priority);
+bool Process_setPriority(Process* this, int priority);
unsigned long Process_getAffinity(Process* this);
-void Process_setAffinity(Process* this, unsigned long mask);
+bool Process_setAffinity(Process* this, unsigned long mask);
void Process_sendSignal(Process* this, int signal);
-#define ONE_K 1024
-#define ONE_M (ONE_K * ONE_K)
-#define ONE_G (ONE_M * ONE_K)
-
-void Process_writeField(Process* this, RichString* str, ProcessField field);
-
int Process_pidCompare(const void* v1, const void* v2);
int Process_compare(const void* v1, const void* v2);
-char* Process_printField(ProcessField field);
-
#endif

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