*/
API int bundle_compare(bundle *b1, bundle *b2);
+/**
+ * @brief Initializes a byte array type key-value pair into a bundle.
+ * @details To set the value of the byte array element, you should use bundle_set_byte_array_element().
+ * This function is only for creating a buffer of the byte array.
+ * @since_tizen 5.5
+ *
+ * @param[in] b The bundle object
+ * @param[in] key The key
+ * @param[in] len The length of the array to be created
+ * @return @c 0 on success,
+ * otherwise a negative error value
+ * @retval #BUNDLE_ERROR_NONE Successful
+ * @retval #BUNDLE_ERROR_INVALID_PARAMETEr Invalid parameter
+ * @retval #BUNDLE_ERROR_KEY_EXISTS Key already exists
+ * @retval #BUNDLE_ERROR_OUT_OF_MEMORY Out of memory
+ *
+ * @see bundle_set_byte_array_element()
+ */
+API int bundle_init_byte_array(bundle *b, const char *key, const unsigned int len);
+
#ifdef __cplusplus
}
#endif
BUNDLE_TYPE_BYTE_ARRAY, len);
}
+int bundle_init_byte_array(bundle *b, const char *key, const unsigned int len)
+{
+ return _bundle_add_kv(b, key, NULL, 0, BUNDLE_TYPE_BYTE_ARRAY, len);
+}
+
int bundle_get_byte_array(bundle *b, const char *key, void ***byte_array,
unsigned int *len, unsigned int **array_element_size)
{