#define CA_MESSAGE_HANDLER_H_
#include "cacommon.h"
-#include "coap.h"
+#include <coap/coap.h>
#define CA_MEMORY_ALLOC_CHECK(arg) { if (NULL == arg) {OIC_LOG(ERROR, TAG, "Out of memory"); \
goto memory_error_exit;} }
SEND_TYPE_UNICAST
} CASendDataType_t;
-typedef enum
-{
- CA_REQUEST_DATA = 1,
- CA_RESPONSE_DATA = 2,
- CA_ERROR_DATA = 3,
-} CADataType_t;
-
typedef struct
{
CASendDataType_t type;
CADataType_t dataType);
/**
- * Detaches control from the caller for sending request.
- * @param[in] resourceUri resource uri that needs to be sent in the request.
- * @param[in] token token information of the request.
- * @param[in] tokenLength length of the token.
- * @param[in] options header options that need to be append in the request.
- * @param[in] numOptions number of options be appended.
- * @return ::CA_STATUS_OK or ERROR CODES (::CAResult_t error codes in cacommon.h).
- */
-CAResult_t CADetachMessageResourceUri(const CAURI_t resourceUri, const CAToken_t token,
- uint8_t tokenLength, const CAHeaderOption_t *options,
- uint8_t numOptions);
-
-/**
* Setting the request and response callbacks for network packets.
* @param[in] ReqHandler callback for receiving the requests.
* @param[in] RespHandler callback for receiving the response.
void CAHandleRequestResponseCallbacks();
/**
+ * Setting the Callback funtion for network state change callback.
+ * @param[in] nwMonitorHandler callback for network state change.
+ */
+void CASetNetworkMonitorCallback(CANetworkMonitorCallback nwMonitorHandler);
+
+/**
* To log the PDU data.
* @param[in] pdu pdu data.
* @param[in] endpoint endpoint