Fix enum (IOTCON_OBSERVE -> IOTCON_OBSERVE_IGNORE_OUT_OF_ORDER)
authorsung.goo.kim <sung.goo.kim@samsung.com>
Thu, 12 Nov 2015 01:01:22 +0000 (10:01 +0900)
committerYoungjae Shin <yj99.shin@samsung.com>
Thu, 19 Nov 2015 05:54:46 +0000 (14:54 +0900)
Change-Id: I27f14b373366414f449d932c064e67d87b96741e

daemon/icd-ioty.c
doc/iotcon_doc.h
lib/icl-remote-resource-caching.c
lib/include/iotcon-constant.h
test/iotcon-test-basic-client.c

index 981a9fe..331f390 100644 (file)
@@ -733,9 +733,9 @@ OCDoHandle icd_ioty_observer_start(GVariant *resource, int observe_type,
                return NULL;
        }
 
-       if (IOTCON_OBSERVE == observe_type)
+       if (IOTCON_OBSERVE_IGNORE_OUT_OF_ORDER == observe_type)
                method = OC_REST_OBSERVE;
-       else if (IOTCON_OBSERVE_ALL == observe_type)
+       else if (IOTCON_OBSERVE_ACCEPT_OUT_OF_ORDER == observe_type)
                method = OC_REST_OBSERVE_ALL;
        else
                method = OC_REST_OBSERVE_ALL;
index 304f13c..48a02b9 100644 (file)
@@ -334,7 +334,7 @@ static void _on_resopnse_observe(iotcon_remote_resource_h resource, iotcon_error
 ...
 {
        int ret;
-       ret = iotcon_remote_resource_set_notify_cb(door_resource, IOTCON_OBSERVE_ALL, NULL,
+       ret = iotcon_remote_resource_set_notify_cb(door_resource, IOTCON_OBSERVE_ACCEPT_OUT_OF_ORDER, NULL,
                        _on_resopnse_observe, NULL);
        if (IOTCON_ERROR_NONE != ret)
                return;
index b8323ee..0ef72fa 100644 (file)
@@ -275,7 +275,7 @@ static int _caching_observer_start(iotcon_remote_resource_h resource)
 
        RETV_IF(NULL == resource, IOTCON_ERROR_INVALID_PARAMETER);
 
-       ret = icl_remote_resource_observer_start(resource, IOTCON_OBSERVE, NULL,
+       ret = icl_remote_resource_observer_start(resource, IOTCON_OBSERVE_IGNORE_OUT_OF_ORDER, NULL,
                        _caching_observe_cb, resource, _caching_observe_cleanup, &sub_id, &handle);
        if (IOTCON_ERROR_NONE != ret) {
                ERR("icl_remote_resource_observer_start() Fail(%d)", ret);
index 322c70c..9c351b5 100644 (file)
@@ -252,8 +252,8 @@ typedef enum {
  * @since_tizen 3.0
  */
 typedef enum {
-       IOTCON_OBSERVE = 0, /**< Indicates observation request for most up-to-date notifications only */
-       IOTCON_OBSERVE_ALL = 1 /**< Indicates observation request for all notifications including stale notifications */
+       IOTCON_OBSERVE_IGNORE_OUT_OF_ORDER = 0, /**< Indicates observation request for most up-to-date notifications only */
+       IOTCON_OBSERVE_ACCEPT_OUT_OF_ORDER = 1 /**< Indicates observation request for all notifications including stale notifications */
 } iotcon_observe_type_e;
 
 /**
index f753e69..1eba3da 100644 (file)
@@ -570,7 +570,7 @@ static void _found_resource(iotcon_remote_resource_h resource, iotcon_error_e re
                }
 
                /* Set NOTIFY callback */
-               ret = iotcon_remote_resource_set_notify_cb(resource_clone, IOTCON_OBSERVE, NULL,
+               ret = iotcon_remote_resource_set_notify_cb(resource_clone, IOTCON_OBSERVE_IGNORE_OUT_OF_ORDER, NULL,
                                _on_response, NULL);
                if (IOTCON_ERROR_NONE != ret) {
                        ERR("iotcon_remote_resource_set_notify_cb() Fail(%d)", ret);