IoTivity-Lite
|
#include <stdio.h>
#include "oc_config.h"
#include "oc_helpers.h"
#include "oc_rep.h"
#include "oc_ri.h"
#include "oc_endpoint.h"
#include "util/oc_memb.h"
#include "util/oc_process.h"
Data Structures | |
struct | oc_pushd_resource_rep |
object used to store Resource pushed to "oic.r.pushreceiver:receivers[i].receiveruri" More... | |
Typedefs | |
typedef void(* | oc_on_push_arrived_t) (oc_pushd_resource_rep_t *) |
callback function called whenever new push arrives More... | |
typedef struct oc_pushd_resource_rep | oc_pushd_resource_rep_t |
object used to store Resource pushed to "oic.r.pushreceiver:receivers[i].receiveruri" More... | |
Functions | |
void | oc_print_pushd_resource (const oc_rep_t *payload) |
print payload of Resource in user friendly format More... | |
void | oc_resource_state_changed (const char *uri, size_t uri_len, size_t device_index) |
application should call this function whenever the contents of pushable Resource is updated, or Push Notification will not work. More... | |
void | oc_set_on_push_arrived (oc_on_push_arrived_t func) |
set callback function called whenever new push arrives More... | |
typedef void(* oc_on_push_arrived_t) (oc_pushd_resource_rep_t *) |
callback function called whenever new push arrives
typedef struct oc_pushd_resource_rep oc_pushd_resource_rep_t |
object used to store Resource pushed to "oic.r.pushreceiver:receivers[i].receiveruri"
void oc_print_pushd_resource | ( | const oc_rep_t * | payload | ) |
print payload of Resource in user friendly format
[in] | payload | pointer to the payload to be printed |
void oc_resource_state_changed | ( | const char * | uri, |
size_t | uri_len, | ||
size_t | device_index | ||
) |
application should call this function whenever the contents of pushable Resource is updated, or Push Notification will not work.
[in] | uri | path of pushable Resource whose contents is just updated |
[in] | uri_len | length of uri |
[in] | device_index | index of Device that updated pushable Resource belongs to |
void oc_set_on_push_arrived | ( | oc_on_push_arrived_t | func | ) |
set callback function called whenever new push arrives
[in] | func | function name |