/**
* Initialize the KeepAlive.
+ * @param[in] mode Host mode of operation.
* @return ::OC_STACK_OK or Appropriate error code.
*/
-OCStackResult InitializeKeepAlive();
+OCStackResult InitializeKeepAlive(OCMode mode);
/**
* Terminates the KeepAlive.
+ * @param[in] mode Host mode of operation.
* @return ::OC_STACK_OK or Appropriate error code.
*/
-OCStackResult TerminateKeepAlive();
+OCStackResult TerminateKeepAlive(OCMode mode);
/**
* Process the KeepAlive timer to send ping message to OIC Server.
/**
* This API will be called from RI layer whenever there is a request for KeepAlive.
* Virtual Resource.
- * @param[in] endPoint RemoteEndpoint which sent the packet.
- * @param[in] requestInfo Received coap packet.
+ * @param[in] request Received request information.
+ * @param[in] resource Resource handle used for sending the response.
* @return ::OC_STACK_OK or Appropriate error code.
*/
-OCStackResult HandleKeepAliveRequest(const CAEndpoint_t* endPoint,
- const CARequestInfo_t* requestInfo);
+OCStackResult HandleKeepAliveRequest(OCServerRequest *request,
+ const OCResource *resource);
/**
* API to handle the connected device for KeepAlive.
* @return Current Time.
*/
-void HandleKeepAliveConnCB(const CAEndpoint_t *endpoint);
-
-/**
- * API to handle the disconnected device for KeepAlive.
- * @return Current Time.
- */
-void HandleKeepAliveDisconnCB(const CAEndpoint_t *endpoint);
+void HandleKeepAliveConnCB(const CAEndpoint_t *endpoint, bool isConnected);
#ifdef __cplusplus
} // extern "C"