X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=resource%2Fcsdk%2Fconnectivity%2Flib%2Flibcoap-4.1.1%2Fencode.h;h=b1b2e57a9a21618057e95cb3633259b90fc0b0ae;hb=17c68b2fd1e74586f85e552eeab4e32dc121f8a0;hp=b9b304e69a2b81f285fb2aa64dbe654f75586305;hpb=8c01dff2c5bc5496f7dc1632c498943ec6ecb015;p=platform%2Fupstream%2Fiotivity.git diff --git a/resource/csdk/connectivity/lib/libcoap-4.1.1/encode.h b/resource/csdk/connectivity/lib/libcoap-4.1.1/encode.h index b9b304e..b1b2e57 100644 --- a/resource/csdk/connectivity/lib/libcoap-4.1.1/encode.h +++ b/resource/csdk/connectivity/lib/libcoap-4.1.1/encode.h @@ -17,6 +17,8 @@ #endif #endif +#include "option.h" + #define Nn 8 /* duplicate definition of N if built on sky motes */ #define E 4 #define HIBIT (1 << (Nn - 1)) @@ -51,4 +53,10 @@ unsigned int coap_decode_var_bytes(unsigned char *buf, unsigned int len); */ unsigned int coap_encode_var_bytes(unsigned char *buf, unsigned int val); +/** + * Tests whether the option definition has a type that allows variable byte encoding. + * Returns true when supported, false when not supported. + */ +bool coap_is_var_bytes(coap_option_def_t* def); + #endif /* _COAP_ENCODE_H_ */