Logo Search packages:      
Sourcecode: sofia-sip version File versions  Download package

nea_server.c File Reference

Detailed Description

Nokia Event API - event notifier implementation.

For internal use only.

Pekka Pessi <Pekka.Pessi@nokia.com>

Martti Mela <Martti.Mela@nokia.com>

Created: Wed Feb 14 18:37:04 EET 2001 ppessi

Definition in file nea_server.c.

#include "config.h"
#include <sofia-sip/sip.h>
#include <sofia-sip/sip_header.h>
#include <sofia-sip/sip_util.h>
#include <sofia-sip/sip_status.h>
#include <sofia-sip/su_tagarg.h>
#include "nea_debug.h"
#include <sofia-sip/nea.h>
#include <sofia-sip/htable.h>
#include <stddef.h>
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include <stdarg.h>
#include <assert.h>
#include <limits.h>

Go to the source code of this file.


struct  nea_event_s
struct  nea_event_view_s
struct  nea_event_view_s::nea_event_queue_s
struct  nea_server_s
struct  nea_sub_s


#define evv_content_type   evv_head->evq_content_type
#define evv_payload   evv_head->evq_payload
#define evv_updated   evv_head->evq_updated
#define evv_version   evv_head->evq_version
#define NEA_VIEW_MAX   (8)
#define NONE   ((void *)- 1)
#define NTA_AGENT_MAGIC_T   struct nea_server_s
#define NTA_INCOMING_MAGIC_T   struct nea_sub_s
#define NTA_LEG_MAGIC_T   struct nea_sub_s
#define NTA_OUTGOING_MAGIC_T   struct nea_sub_s
#define sip_allow_events_find(k, i)   sip_params_find(k->k_items, i)
#define SU_MSG_ARG_T   tagi_t
#define SU_ROOT_MAGIC_T   struct nea_server_s


typedef struct nea_event_queue_s nea_event_queue_t


nea_emagic_tnea_emagic_get (nea_event_t *ev)
nea_event_tnea_event_create (nea_server_t *nes, nea_watcher_f *callback, nea_emagic_t *context, char const *name, char const *subname, char const *default_content_type, char const *accept)
nea_event_tnea_event_get (nea_server_t const *nes, char const *e)
nea_event_tnea_event_tcreate (nea_server_t *nes, nea_watcher_f *callback, nea_emagic_t *context, char const *name, char const *subname, tag_type_t tag, tag_value_t value,...)
nea_event_view_tnea_event_view (nea_event_t *ev, char const *content_type)
int nea_server_active (nea_server_t *nes, nea_event_t const *ev)
int nea_server_add_irq (nea_server_t *nes, nta_leg_t *leg, sip_contact_t const *local_target, nta_incoming_t *irq, sip_t const *sip)
static int nea_server_callback (nea_sub_t *nes_as_sub, nta_leg_t *leg, nta_incoming_t *irq, sip_t const *sip)
nea_server_tnea_server_create (nta_agent_t *agent, su_root_t *root, url_t const *url, int max_subs, nea_new_event_f *callback, nea_smagic_t *context, tag_type_t tag, tag_value_t value,...)
void nea_server_destroy (nea_server_t *nes)
void nea_server_flush (nea_server_t *nes, nea_event_t *event)
void nea_server_free_subscribers (nea_server_t *nes, nea_subnode_t const **sn_list)
nea_subnode_t const ** nea_server_get_subscribers (nea_server_t *nes, nea_event_t const *ev)
int nea_server_non_embryonic (nea_server_t *nes, nea_event_t const *ev)
int nea_server_notify (nea_server_t *nes, nea_event_t *ev)
static void nea_server_pending_flush (nea_server_t *nes)
int nea_server_shutdown (nea_server_t *nes, int retry_after)
int nea_server_update (nea_server_t *nes, nea_event_t *ev, tag_type_t tag, tag_value_t value,...)
su_inline void nea_sub_assign_view (nea_sub_t *s, nea_event_view_t *evv)
int nea_sub_auth (nea_sub_t *s, nea_state_t state, tag_type_t tag, tag_value_t value,...)
static nea_sub_tnea_sub_create (nea_server_t *nes)
static void nea_sub_destroy (nea_sub_t *s)
nta_incoming_tnea_sub_get_request (nea_sub_t *sub)
static int nea_sub_is_removed (nea_sub_t const *s)
static int nea_sub_notify (nea_server_t *nes, nea_sub_t *s, sip_time_t now, tag_type_t tag, tag_value_t value,...)
static int nea_sub_process_incoming (nea_sub_t *s, nta_leg_t *leg, nta_incoming_t *irq, sip_t const *sip)
static int nea_sub_process_subscribe (nea_sub_t *s, nta_leg_t *leg, nta_incoming_t *irq, sip_t const *sip)
static void nea_sub_remove (nea_sub_t *s)
int nea_sub_version (nea_sub_t *s, unsigned version)
nta_incoming_tnea_subnode_get_incoming (nea_subnode_t *sn)
su_inline void nea_subnode_init (nea_subnode_t *sn, nea_sub_t *s, sip_time_t now)
sip_content_type_t const * nea_view_content_type (nea_event_view_t const *evv)
nea_event_view_tnea_view_create (nea_server_t *nes, nea_event_t *ev, nea_evmagic_t *magic, tag_type_t tag, tag_value_t value,...)
static int nea_view_dequeue (nea_server_t *nes, nea_event_t *ev)
void nea_view_destroy (nea_server_t *nes, nea_event_view_t *evv)
nea_evmagic_tnea_view_magic (nea_event_view_t const *evv)
static int nea_view_queue (nea_server_t *nes, nea_event_view_t *evv, nea_event_queue_t *evq)
void nea_view_set_magic (nea_event_view_t *evv, nea_evmagic_t *magic)
static int nea_view_update (nea_server_t *nes, nea_event_t *ev, nea_event_view_t **evvp, int private, int fake, tag_type_t tag, tag_value_t value,...)
unsigned nea_view_version (nea_event_view_t const *evv)
static void nes_event_timer (nea_server_t *nes, su_timer_t *timer, su_timer_arg_t *arg)
static int nes_new_event_callback (nea_server_t *nes, nea_event_t **ev_p, nea_event_view_t **view_p, nta_incoming_t *irq, sip_t const *sip)
static int nes_watcher_callback (nea_server_t *nes, nea_event_t *ev, nea_sub_t *s, sip_t const *sip, sip_time_t now)
static int response_to_notify (nea_sub_t *s, nta_outgoing_t *oreq, sip_t const *sip)

Generated by  Doxygen 1.6.0   Back to index