"Fossies" - the Fresh Open Source Software Archive

Member "opensips-3.0.1/modules/tm/uac.h" (16 Apr 2019, 2638 Bytes) of package /linux/misc/opensips-3.0.1.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "uac.h" see the Fossies "Dox" file reference documentation.

    1 /*
    2  * Copyright (C) 2001-2003 FhG Fokus
    3  *
    4  * This file is part of opensips, a free SIP server.
    5  *
    6  * opensips is free software; you can redistribute it and/or modify
    7  * it under the terms of the GNU General Public License as published by
    8  * the Free Software Foundation; either version 2 of the License, or
    9  * (at your option) any later version
   10  *
   11  * opensips is distributed in the hope that it will be useful,
   12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
   13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
   14  * GNU General Public License for more details.
   15  *
   16  * You should have received a copy of the GNU General Public License
   17  * along with this program; if not, write to the Free Software
   18  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301  USA
   19  *
   20  * History:
   21  * ----------
   22  * 2003-02-28 protocolization of t_uac_dlg completed (jiri)
   23  */
   24 
   25 #ifndef _UAC_H
   26 #define _UAC_H
   27 
   28 #include <stdio.h>
   29 #include "../../str.h"
   30 #include "dlg.h"
   31 #include "t_hooks.h"
   32 
   33 #define DEFAULT_CSEQ 10 /* Default CSeq number */
   34 
   35 /* Pass provisional replies to fifo applications */
   36 extern int pass_provisional_replies;
   37 
   38 
   39 /*
   40  * Function prototypes
   41  */
   42 typedef int (*reqwith_t)(str* m, str* h, str* b, dlg_t* d,
   43         transaction_cb c, void* cp, release_tmcb_param release_func);
   44 typedef int (*reqout_t)(str* m, str* t, str* f, str* h, str* b, dlg_t** d,
   45         transaction_cb c, void* cp, release_tmcb_param release_func);
   46 typedef int (*req_t)(str* m, str* ru, str* t, str* f, str* h, str* b, str *obu,
   47         transaction_cb c, void* cp,release_tmcb_param release_func);
   48 
   49 typedef void (*set_localT_holder_f)(struct cell**);
   50 
   51 /*
   52  * Generate a fromtag based on given Call-ID
   53  */
   54 void generate_fromtag(str* tag, str* callid);
   55 
   56 
   57 /*
   58  * Initialization function
   59  */
   60 int uac_init(void);
   61 
   62 
   63 /*
   64  * Send a request
   65  */
   66 int t_uac(str* method, str* headers, str* body, dlg_t* dialog,
   67         transaction_cb cb, void* cbp, release_tmcb_param release_func);
   68 
   69 
   70 /*
   71  * Send a message within a dialog
   72  */
   73 int req_within(str* m, str* h, str* b, dlg_t* d,
   74         transaction_cb c, void* cp, release_tmcb_param release_func);
   75 
   76 
   77 /*
   78  * Send an initial request that will start a dialog
   79  */
   80 int req_outside(str* m, str* t, str* f, str* h, str* b, dlg_t** d,
   81     transaction_cb c, void* cp, release_tmcb_param release_func);
   82 
   83 
   84 /*
   85  * Send a transactional request, no dialogs involved
   86  */
   87 int request(str* m, str* ruri, str* to, str* from, str* h, str* b, str *oburi,
   88         transaction_cb c, void* cp, release_tmcb_param release_func);
   89 
   90 /*
   91  * Set a struct cell holder to get the last local transaction pointer
   92  * */
   93 void setlocalTholder(struct cell** holder);
   94 
   95 #endif