From: Younho Park Date: Thu, 3 Dec 2015 04:33:17 +0000 (+0900) Subject: Modified Push Tutorial ; 1. Added warning comment, 2. Replaced internal enum value X-Git-Tag: tizen_3.0/TD_SYNC/20161201~293^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f4866e21ad82bc810e99e23bd6dda858787913fc;p=sdk%2Fonline-doc.git Modified Push Tutorial ; 1. Added warning comment, 2. Replaced internal enum value Change-Id: I2a780475074408812b18b77477bec269933d1484 Signed-off-by: Younho Park --- diff --git a/org.tizen.tutorials/html/native/messaging/push_tutorial_n.htm b/org.tizen.tutorials/html/native/messaging/push_tutorial_n.htm index e1bcc95..d9ce771 100644 --- a/org.tizen.tutorials/html/native/messaging/push_tutorial_n.htm +++ b/org.tizen.tutorials/html/native/messaging/push_tutorial_n.htm @@ -236,7 +236,7 @@ push_service_disconnect(push_conn); push_conn = NULL; -

The connection is automatically closed when the application terminates. Hence, if the application uses the push service while being launched, it does not need this function. However, the application can disconnect the service in the middle of the application operation. If you add a toggle switch to the application for switching the push service on and off, call this function when the service is switched off.

+

The connection is automatically closed when the application terminates. Hence, if the application uses the push service while being launched, it does not need this function. However, the application can disconnect the service in the middle of the application operation. If you add a toggle switch to the application for switching the push service on and off, call this function when the service is switched off. If you call this function in the push callback functions, it may cause your application to crash.

  • Handle state transitions. @@ -320,7 +320,7 @@ _result_cb(push_service_result_e result, const char *msg, void *user_data) } -

    When an error occurs in the middle of the registration process, the reason is returned in the first parameter of the callback. For example, if the push server is not responding, the push_service_register() function returns PUSH_SERVICE_ERROR_NONE (because delivery to the service is successful), but the _result_cb() function is called later with PUSH_RESULT_TIMEOUT. In this case, the application does not need to request registration again because the push service keeps the previous request and sends it when the network becomes online. The msg parameter is the error message from the push service if the request fails.

    +

    When an error occurs in the middle of the registration process, the reason is returned in the first parameter of the callback. For example, if the push server is not responding, the push_service_register() function returns PUSH_SERVICE_ERROR_NONE (because delivery to the service is successful), but the _result_cb() function is called later with PUSH_SERVICE_RESULT_TIMEOUT. In this case, the application does not need to request registration again because the push service keeps the previous request and sends it when the network becomes online. The msg parameter is the error message from the push service if the request fails.

  • Handle the transit to the REGISTERED state. @@ -952,4 +952,4 @@ var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga - \ No newline at end of file +