00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026 #ifndef _PU_SEND_SUBSC_
00027 #define _PU_SEND_SUBSC_
00028
00029 #include <time.h>
00030
00031 #include "../../modules/tm/tm_load.h"
00032 #include "../../str.h"
00033 #include "hash.h"
00034
00035 typedef struct subs_info
00036 {
00037 str id;
00038 str* pres_uri;
00039 str* watcher_uri;
00040 str* contact;
00041 str* remote_target;
00042 str* outbound_proxy;
00043 int event;
00044 str* extra_headers;
00045 int expires;
00046 int source_flag;
00047 int flag;
00048 void* cb_param;
00049
00050
00051
00052 int internal_update_flag;
00053 }subs_info_t;
00054
00055
00056 typedef int (*send_subscribe_t)(subs_info_t* subs);
00057 int send_subscribe(subs_info_t* subs);
00058 void subs_cback_func(struct cell *t, int type, struct tmcb_params *ps);
00059 str* subs_build_hdr(str* watcher_uri, int expires, int event, str* extra_headers);
00060 dlg_t* pua_build_dlg_t(ua_pres_t* presentity);
00061 ua_pres_t* subscribe_cbparam(subs_info_t* subs, int ua_flag);
00062 ua_pres_t* subs_cbparam_indlg(ua_pres_t* subs, int expires, int ua_flag);
00063
00064 #endif