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
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036 #ifndef _OSP_MOD_DESTINATION_H_
00037 #define _OSP_MOD_DESTINATION_H_
00038
00039 #include <time.h>
00040 #include "osp_mod.h"
00041
00042 typedef struct _osp_dest {
00043 char validafter[OSP_STRBUF_SIZE];
00044 char validuntil[OSP_STRBUF_SIZE];
00045 char callid[OSP_STRBUF_SIZE];
00046 char called[OSP_STRBUF_SIZE];
00047 char calling[OSP_STRBUF_SIZE];
00048 char source[OSP_STRBUF_SIZE];
00049 char srcdev[OSP_STRBUF_SIZE];
00050 char host[OSP_STRBUF_SIZE];
00051 char destdev[OSP_STRBUF_SIZE];
00052 char networkid[OSP_STRBUF_SIZE];
00053 unsigned char token[OSP_TOKENBUF_SIZE];
00054 unsigned int callidsize;
00055 unsigned int tokensize;
00056 unsigned int timelimit;
00057 int lastcode;
00058 time_t authtime;
00059 time_t time100;
00060 time_t time180;
00061 time_t time200;
00062 int type;
00063 unsigned long long transid;
00064 int supported;
00065 int used;
00066 int reported;
00067 unsigned int destinationCount;
00068 char origcalled[OSP_STRBUF_SIZE];
00069 } osp_dest;
00070
00071 osp_dest* ospInitDestination(osp_dest* dest);
00072 int ospSaveOrigDestination(osp_dest* dest);
00073 int ospSaveTermDestination(osp_dest* dest);
00074 int ospCheckOrigDestination(void);
00075 osp_dest* ospGetNextOrigDestination(void);
00076 osp_dest* ospGetLastOrigDestination(void);
00077 osp_dest* ospGetTermDestination(void);
00078 void ospRecordEvent(int clientcode, int servercode);
00079 void ospDumpDestination(osp_dest* dest);
00080 void ospDumpAllDestination(void);
00081 void ospConvertAddress(char* src, char* dst, int buffersize);
00082
00083 #endif
00084