Internalfunctions - SmartSlog KP Library
Data Structures | Macros | Typedefs | Functions
subscription_internal.h File Reference

Internal part of the interface for subscription. More...

#include "structures.h"
#include "subscription.h"

Go to the source code of this file.

Data Structures

struct  subscription_data_s
 Subscription data for subscription container. More...
struct  subscription_s
 Contains data for the subscription. More...

Macros

#define KPLIB_SBCR_UNSUBSCRIBE_ATTEMPTS   10
 Count of attemts to try receiving unsubscription notification.
#define KPLIB_SBCR_ASYNC_WAITING_TIMEOUT   100
 Timeout to check notification for asynchronous subscriptions.
#define KPLIB_SBCR_SYNC_WAITING_TIMEOUT   1000
 Timeout to check notification for synchronous subscriptions.
#define KPLIB_SBCR_UNSBCR_WAITING_TIMEOUT   500
 Timeout to wait unsubscription notification.
#define KPLIB_SBCR_ASYNC_PROCESS_SLEEP   100

Typedefs

typedef struct subscription_data_s subscription_data_t
 Subscription data for subscription container.

Functions

subscription_data_tnew_subscription_data (individual_t *individual, list_t *properties)
 Create a new data for the subscription.
void free_subscription_data (subscription_data_t *data, bool free_prop_list)
 Free subscription data.

Detailed Description

Internal part of the interface for subscription.

Author:
Aleksandr A. Lomov lomov.nosp@m.@cs..nosp@m.karel.nosp@m.ia.r.nosp@m.u
Date:
19 April, 2012

LICENSE

SmartSlog KP Library is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

SmartSlog KP Library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with SmartSlog KP Library; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA

DESCRIPTION

subscription_internal.h - Internal part of the interface for subscription.

Copyright (C) SmartSlog Team (Aleksandr A. Lomov). All rights reserved.
Mail-list: smart.nosp@m.slog.nosp@m.@cs.k.nosp@m.arel.nosp@m.ia.ru


Macro Definition Documentation

#define KPLIB_SBCR_UNSUBSCRIBE_ATTEMPTS   10

Count of attemts to try receiving unsubscription notification.


Typedef Documentation

Subscription data for subscription container.

See also:
subscription_s.

Function Documentation

void free_subscription_data ( subscription_data_t data,
bool  free_prop_list 
)

Free subscription data.

Free subscription data structure, individual and properties are not freed. You can free properties list (only list structure will be freed, not properties), using parameter free_prop_list.

Parameters:
datasubscription data to free.
free_prop_listif it is 'true' - list structure will be freed.
subscription_data_t* new_subscription_data ( individual_t individual,
list_t *  properties 
)

Create a new data for the subscription.

Subscription data contains individual and list with properties or NULL for all individual's properties.

Parameters:
individualindividual.
propertieslist with properties for subscribe or NULL for all properties.
Returns:
new subscription data on success or NULL otherwise.