check_sensors.h 615 Bytes
#ifndef CHECK_SENSORS_H
#define CHECK_SENSORS_H

#include <iostream>
#include <map>
#include <string>
#include <vector>

#include <stdlib.h>
#include <string.h>
#include <sys/time.h>
#include <unistd.h>

#include "auxiliar.h"

#include <sensors/sensors.h>

#define OK 0
#define WARN 1
#define CRIT 2
#define UNKN 3

#define VERSION "1.0"

int getTemps(const std::string& sensorName, std::map<std::string, double>& temps);
int evalStatus(const std::string& sensorName, double warn, double crit, std::string& status);
void printVersion();
void printHelp(bool longVersion);
void set_timeout(unsigned int sec);

#endif