blob: dc935da903815493d2c41850a9d762ab3a9148db [file] [log] [blame]
akmhoque59980a52012-08-09 12:36:09 -05001#ifndef _UTILITY_H_
2#define _UTILITY_H_
3
4char * getLocalTimeStamp(void);
akmhoquec9286692012-08-16 09:57:58 -05005char * getGmTimeStamp(void);
akmhoquef71d9082012-08-22 12:51:53 -04006long int get_current_time_sec(void);
akmhoque03004e62012-09-06 01:12:28 -05007void get_current_timestamp_micro(char * microSec);
akmhoqueda5b6832012-09-13 22:33:55 -05008long int get_time_diff(const char *time1, const char *time2);
akmhoque53f64222012-09-05 13:57:51 -05009
akmhoquebfefef22012-09-26 10:09:34 -050010void startLogging(char *loggingDir);
11void writeLogg(const char *source_file, const char *function, const int line, const char *format, ...);
akmhoqueb77b95f2013-02-08 12:28:47 -060012struct sockaddr_in * get_ip_from_hostname(char *hostname);
13int get_ip_from_hostname_02(char * hostname , char* ip);
akmhoque7adb2772013-03-05 16:30:59 -060014char * get_current_timestamp_micro_v2(void);
15char * get_current_user_home(void);
16char * get_current_user_default_keystore(void);
akmhoqueedb68d92013-03-05 10:18:16 -060017
18int add_ccn_uri_name(struct ccn_charbuf *res_name, struct ccn_charbuf *add);
19
akmhoque59980a52012-08-09 12:36:09 -050020#endif