common.h
1 
21 #ifndef NDN_COMMON_H
22 #define NDN_COMMON_H
23 
24 #include "../ndn-cpp-config.h"
25 #include <stdint.h>
26 #include <stddef.h>
27 
28 #if NDN_CPP_HAVE_ATTRIBUTE_DEPRECATED
29  #define DEPRECATED_IN_NDN_CPP __attribute__((deprecated))
30 #else
31  #define DEPRECATED_IN_NDN_CPP
32 #endif
33 
34 #if !NDN_CPP_HAVE_ROUND
35 #define round(x) floor((x) + 0.5)
36 #endif
37 
38 #ifdef __cplusplus
39 extern "C" {
40 #endif
41 
45 typedef double ndn_Milliseconds;
46 
50 typedef double ndn_MillisecondsSince1970;
51 
59 static const size_t MAX_NDN_PACKET_SIZE = 8800;
60 
65 static const size_t ndn_SHA256_DIGEST_SIZE = 32;
66 
67 #ifdef __cplusplus
68 }
69 #endif
70 
71 #endif