Mon Jun 27 16:50:55 2011

Asterisk developer's documentation


pktccops.h

Go to the documentation of this file.
00001 /*
00002  * Asterisk -- An open source telephony toolkit.
00003  *
00004  * Copyright (C) 2009, Attila Domjan
00005  *
00006  * Attila Domjan <attila.domjan.hu@gmail.com>
00007  *
00008  * See http://www.asterisk.org for more information about
00009  * the Asterisk project. Please do not directly contact
00010  * any of the maintainers of this project for assistance;
00011  * the project provides a web site, mailing lists and IRC
00012  * channels for your use.
00013  *
00014  * This program is free software, distributed under the terms of
00015  * the GNU General Public License Version 2. See the LICENSE file
00016  * at the top of the source tree.
00017  */
00018 
00019 /*! \file
00020  *
00021  * \brief PacketCable COPS
00022  * 
00023  * \author Attila Domjan <attila.domjan.hu@gmail.com>
00024  */
00025 
00026 #ifndef _ASTERISK_PKTCCOPS_H
00027 #define _ASTERISK_PKTCCOPS_H
00028 
00029 #include "asterisk/optional_api.h"
00030 
00031 #if defined(__cplusplus) || defined(c_plusplus)
00032 extern "C" {
00033 #endif
00034 
00035 enum {
00036    GATE_SET,
00037    GATE_INFO,
00038    GATE_SET_HAVE_GATEID,
00039    GATE_DEL
00040 };
00041 
00042 enum {
00043    GATE_ALLOC_FAILED,
00044    GATE_ALLOC_PROGRESS,
00045    GATE_ALLOCATED,
00046    GATE_CLOSED,
00047    GATE_CLOSED_ERR,
00048    GATE_OPEN,
00049    GATE_DELETED,
00050    GATE_TIMEOUT
00051 };
00052 
00053 struct cops_gate {
00054    AST_LIST_ENTRY(cops_gate) list;
00055    uint32_t gateid;
00056    uint16_t trid;
00057    time_t in_transaction;
00058    uint32_t mta;
00059    int state;
00060    time_t allocated;
00061    time_t checked;
00062    time_t deltimer;
00063    struct cops_cmts *cmts;
00064    int (* got_dq_gi) (struct cops_gate *gate);
00065    int (* gate_remove) (struct cops_gate *gate);
00066    int (* gate_open) (struct cops_gate *gate);
00067    void *tech_pvt;
00068 };
00069 
00070 
00071 AST_OPTIONAL_API(struct cops_gate *, ast_pktccops_gate_alloc,
00072    (int cmd,  struct cops_gate *gate, uint32_t mta, uint32_t actcount,
00073     float bitrate, uint32_t psize, uint32_t ssip, uint16_t ssport,
00074     int (* const got_dq_gi) (struct cops_gate *gate),
00075     int (* const gate_remove) (struct cops_gate *gate)),
00076    { return NULL; });
00077 
00078 #if defined(__cplusplus) || defined(c_plusplus)
00079 }
00080 #endif
00081 
00082 #endif /* _ASTERISK_PKTCCOPS_H */

Generated on Mon Jun 27 16:50:55 2011 for Asterisk - The Open Source Telephony Project by  doxygen 1.4.7