FreeBSDProcess.h 889 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. #ifndef HEADER_FreeBSDProcess
  2. #define HEADER_FreeBSDProcess
  3. /*
  4. htop - FreeBSDProcess.h
  5. (C) 2015 Hisham H. Muhammad
  6. Released under the GNU GPLv2+, see the COPYING file
  7. in the source distribution for its full text.
  8. */
  9. #include <stdbool.h>
  10. #include "Object.h"
  11. #include "Process.h"
  12. #include "Machine.h"
  13. typedef enum {
  14. SCHEDCLASS_UNKNOWN = 0,
  15. SCHEDCLASS_INTR_THREAD, /* interrupt thread */
  16. SCHEDCLASS_REALTIME,
  17. SCHEDCLASS_TIMESHARE, /* Regular scheduling */
  18. SCHEDCLASS_IDLE,
  19. MAX_SCHEDCLASS,
  20. } FreeBSDSchedClass;
  21. typedef struct FreeBSDProcess_ {
  22. Process super;
  23. int jid;
  24. char* jname;
  25. char* emul;
  26. FreeBSDSchedClass sched_class;
  27. } FreeBSDProcess;
  28. extern const ProcessClass FreeBSDProcess_class;
  29. extern const ProcessFieldData Process_fields[LAST_PROCESSFIELD];
  30. Process* FreeBSDProcess_new(const Machine* host);
  31. void Process_delete(Object* cast);
  32. #endif