Subversion Repositories HomeAutomation

Rev

Rev 1310 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | SVN | RSS feed

Rev 1310 Rev 1311
Line 15... Line 15...
15
#include <stdexcept>
15
#include <stdexcept>
16
#include <iostream>
16
#include <iostream>
17
#include <cmath>
17
#include <cmath>
18
#include <sys/types.h>
18
#include <sys/types.h>
19
#include <dirent.h>
19
#include <dirent.h>
20
#include "../types.h"
20
#include "types.h"
21
 
21
 
22
using namespace std;
22
using namespace std;
23
 
23
 
24
namespace atom {
24
namespace atom {
25
namespace utils {
25
namespace utils {
Line 32... Line 32...
32
float bin2float(string bin);
32
float bin2float(string bin);
33
string float2bin(float num, unsigned int length);
33
string float2bin(float num, unsigned int length);
34
unsigned int bin2uint(string bin);
34
unsigned int bin2uint(string bin);
35
string uint2bin(unsigned int num, unsigned int length);
35
string uint2bin(unsigned int num, unsigned int length);
36
string uint2hex(unsigned int num, unsigned int length);
36
string uint2hex(unsigned int num, unsigned int length);
37
vector<string> explode(string delimiter, string str);
37
string_list explode(string delimiter, string str);
38
string strtoupper(string s);
38
string strtoupper(string s);
39
string strtolower(string s);
39
string strtolower(string s);
-
 
40
 
40
string trim(string s);
41
//string trim(string s);
41
string trim(const string s, char c);
42
//string trim(const string s, char c);
-
 
43
 
42
bool stob(const string s);
44
bool stob(const string s);
43
int stoi(const string s);
45
int stoi(const string s);
44
string itos(int i);
46
string itos(int i);
45
string utos(unsigned int i);
47
string utos(unsigned int i);
46
unsigned int stou(const string s);
48
unsigned int stou(const string s);