Add isds_box_state_period structure
[libisds.git] / client / common.h
blob956634e09820b9a1ccdb6931f1d75fbf14319ffd
1 #ifndef __COMMON_H__
2 #define __COMMON_H__
4 #include <isds.h>
6 #define url isds_testing_locator
7 const char *username(void);
8 const char *password(void);
10 void print_bool(const _Bool *boolean);
11 void print_longint(const long int *number);
12 void print_DbState(const long int state);
13 void print_date(const struct tm *date);
14 void print_DbOwnerInfo(const struct isds_DbOwnerInfo *info);
15 void print_DbUserInfo(const struct isds_DbUserInfo *info);
16 void print_timeval(const struct timeval *time);
17 void print_hash(const struct isds_hash *hash);
18 void print_envelope(const struct isds_envelope *envelope);
19 void print_message(const struct isds_message *message);
20 void print_copies(const struct isds_list *copies);
21 void print_message_status_change(
22 const struct isds_message_status_change *changed_status);
23 void print_sender_type(const isds_sender_type *type);
25 void compare_hashes(const struct isds_hash *hash1,
26 const struct isds_hash *hash2);
27 int progressbar(double upload_total, double upload_current,
28 double download_total, double download_current,
29 void *data);
31 int mmap_file(const char *file, int *fd, void **buffer, size_t *length);
32 int munmap_file(int fd, void *buffer, size_t length);
33 int save_data(const char *message, const void *data, const size_t length);
35 #endif