123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130 |
- /*
- * @Description:
- * @Version: 1.0
- * @Autor: lishengyin
- * @Date: 2022-01-10 15:01:15
- * @LastEditors: lishengyin
- * @LastEditTime: 2022-01-12 09:30:02
- */
- #pragma once
- #include <iostream>
- #include <map>
- #include <time.h>
- #include <dirent.h>
- #include <time.h>
- #include <cstdlib>
- #include <dirent.h>
- #include <sys/types.h>
- #include <sys/stat.h>
- #include <unistd.h>
- #include "Util/logger.h"
- #include "Util/NoticeCenter.h"
- #include "Poller/EventPoller.h"
- #include "Player/PlayerProxy.h"
- #include "Rtmp/RtmpPusher.h"
- #include "Common/config.h"
- #include "Pusher/MediaPusher.h"
- #include "Extension/Frame.h"
- #include "Util/SqlPool.h"
- #include "Network/TcpClient.h"
- #include "Poller/Timer.h"
- #include "Shell.h"
- using namespace toolkit;
- using namespace std;
- namespace MIVA
- {
- class monitor
- {
- private:
- FILE *file = nullptr;
- public:
- monitor();
- ~monitor();
- /**
- * @description: 创建实例
- * @param {*}
- * @return {*}
- */
- static std::shared_ptr<monitor> CreateNew();
-
- /**
- * @description: 释放资源
- * @param {*}
- * @return {*}
- */
- void Destory();
- /**
- * @description: 获取内存使用情况
- * @param {*}
- * @return {*}
- */
- int32_t getMemoryUsage();
- /**
- * @description: 获取Cpu使用情况
- * TODO
- * @param {*}
- * @return {*}
- */
- int32_t getCpuUsage();
- /**
- * @description: 获取Cpu温度
- * TODO
- * @param {*}
- * @return {*}
- */
- int32_t getCpuTemp();
- /**
- * @description: 获取GPU温度
- * @param {*}
- * @return {*}
- */
- int32_t getGpuTemp();
- /**
- * @description: 获取AUX温度
- * @param {*}
- * @return {*}
- */
- int32_t getAUXTemp();
- /**
- * @description: 获取AO温度
- * @param {*}
- * @return {*}
- */
- int32_t getA0Temp();
- /**
- * @description: 获取Thermal
- * @param {*}
- * @return {*}
- */
- int32_t getThermalTemp();
- /**
- * @description: 获取Gpu使用情况
- * TODO
- * @param {*}
- * @return {*}
- */
- int32_t getGpuUsage();
- /**
- * @description: 获取文件句柄使用情况
- * @param {*}
- * @return {*}
- */
- int32_t getFdUsage();
- };
- } // namespace MIVA
|