abyss_socket.h File Reference

#include <netinet/in.h>
#include <xmlrpc-c/abyss.h>

Include dependency graph for abyss_socket.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  _TSocket
struct  TSocketVtbl

Defines

#define IPB1(x)   (((unsigned char *)(&x))[0])
#define IPB2(x)   (((unsigned char *)(&x))[1])
#define IPB3(x)   (((unsigned char *)(&x))[2])
#define IPB4(x)   (((unsigned char *)(&x))[3])
#define TIME_INFINITE   0xffffffff

Typedefs

typedef void SocketAcceptImpl (TSocket *const listenSocketP, abyss_bool *const connectedP, abyss_bool *const failedP, TSocket **const acceptedSocketPP, TIPAddr *const ipAddrP)
typedef uint32_t SocketAvailableReadBytesImpl (TSocket *const socketP)
typedef abyss_bool SocketBindImpl (TSocket *const socketP, TIPAddr *const addrP, uint16_t const portNumber)
typedef abyss_bool SocketConnectImpl (TSocket *const socketP, TIPAddr *const addrP, uint16_t const portNumber)
typedef void SocketDestroyImpl (TSocket *const socketP)
typedef uint32_t SocketErrorImpl (TSocket *const socketP)
typedef void SocketGetPeerNameImpl (TSocket *const socketP, TIPAddr *const ipAddrP, uint16_t *const portNumberP, abyss_bool *const successP)
typedef abyss_bool SocketListenImpl (TSocket *const socketP, uint32_t const backlog)
typedef uint32_t SocketReadImpl (TSocket *const socketP, char *const buffer, uint32_t const len)
typedef uint32_t SocketWaitImpl (TSocket *const socketP, abyss_bool const rd, abyss_bool const wr, uint32_t const timems)
typedef void SocketWriteImpl (TSocket *const socketP, const unsigned char *const buffer, uint32_t const len, abyss_bool *const failedP)
typedef struct in_addr TIPAddr

Functions

void SocketAccept (TSocket *const listenSocketP, abyss_bool *const connectedP, abyss_bool *const failedP, TSocket **const acceptedSocketP, TIPAddr *const ipAddrP)
uint32_t SocketAvailableReadBytes (TSocket *const socketP)
abyss_bool SocketBind (TSocket *const socketP, TIPAddr *const addrP, uint16_t const portNumber)
abyss_bool SocketConnect (TSocket *const socketP, TIPAddr *const addrP, uint16_t const portNumber)
void SocketCreate (const struct TSocketVtbl *const vtblP, void *const implP, TSocket **const socketPP)
uint32_t SocketError (TSocket *const socketP)
void SocketGetPeerName (TSocket *const socketP, TIPAddr *const ipAddrP, uint16_t *const portNumberP, abyss_bool *const successP)
abyss_bool SocketInit (void)
abyss_bool SocketListen (TSocket *const socketP, uint32_t const backlog)
uint32_t SocketRead (TSocket *const socketP, unsigned char *const buffer, uint32_t const len)
void SocketTerm (void)
uint32_t SocketWait (TSocket *const socketP, abyss_bool const rd, abyss_bool const wr, uint32_t const timems)
void SocketWrite (TSocket *const socketP, const unsigned char *const buffer, uint32_t const len, abyss_bool *const failedP)

Variables

abyss_bool SocketTraceIsActive


Define Documentation

#define IPB1 (  )     (((unsigned char *)(&x))[0])

Definition at line 10 of file abyss_socket.h.

#define IPB2 (  )     (((unsigned char *)(&x))[1])

Definition at line 11 of file abyss_socket.h.

#define IPB3 (  )     (((unsigned char *)(&x))[2])

Definition at line 12 of file abyss_socket.h.

#define IPB4 (  )     (((unsigned char *)(&x))[3])

Definition at line 13 of file abyss_socket.h.

#define TIME_INFINITE   0xffffffff

Definition at line 84 of file abyss_socket.h.


Typedef Documentation

typedef void SocketAcceptImpl(TSocket *const listenSocketP, abyss_bool *const connectedP, abyss_bool *const failedP, TSocket **const acceptedSocketPP, TIPAddr *const ipAddrP)

Definition at line 39 of file abyss_socket.h.

typedef uint32_t SocketAvailableReadBytesImpl(TSocket *const socketP)

Definition at line 52 of file abyss_socket.h.

typedef abyss_bool SocketBindImpl(TSocket *const socketP, TIPAddr *const addrP, uint16_t const portNumber)

Definition at line 32 of file abyss_socket.h.

typedef abyss_bool SocketConnectImpl(TSocket *const socketP, TIPAddr *const addrP, uint16_t const portNumber)

Definition at line 28 of file abyss_socket.h.

typedef void SocketDestroyImpl(TSocket *const socketP)

Definition at line 17 of file abyss_socket.h.

typedef uint32_t SocketErrorImpl(TSocket *const socketP)

Definition at line 45 of file abyss_socket.h.

typedef void SocketGetPeerNameImpl(TSocket *const socketP, TIPAddr *const ipAddrP, uint16_t *const portNumberP, abyss_bool *const successP)

Definition at line 54 of file abyss_socket.h.

typedef abyss_bool SocketListenImpl(TSocket *const socketP, uint32_t const backlog)

Definition at line 36 of file abyss_socket.h.

typedef uint32_t SocketReadImpl(TSocket *const socketP, char *const buffer, uint32_t const len)

Definition at line 24 of file abyss_socket.h.

typedef uint32_t SocketWaitImpl(TSocket *const socketP, abyss_bool const rd, abyss_bool const wr, uint32_t const timems)

Definition at line 47 of file abyss_socket.h.

typedef void SocketWriteImpl(TSocket *const socketP, const unsigned char *const buffer, uint32_t const len, abyss_bool *const failedP)

Definition at line 19 of file abyss_socket.h.

typedef struct in_addr TIPAddr

Definition at line 15 of file abyss_socket.h.


Function Documentation

void SocketAccept ( TSocket *const   listenSocketP,
abyss_bool *const   connectedP,
abyss_bool *const   failedP,
TSocket **const   acceptedSocketP,
TIPAddr *const   ipAddrP 
)

Definition at line 214 of file abyss_socket.c.

uint32_t SocketAvailableReadBytes ( TSocket *const   socketP  ) 

Definition at line 241 of file abyss_socket.c.

abyss_bool SocketBind ( TSocket *const   socketP,
TIPAddr *const   addrP,
uint16_t const   portNumber 
)

Definition at line 195 of file abyss_socket.c.

abyss_bool SocketConnect ( TSocket *const   socketP,
TIPAddr *const   addrP,
uint16_t const   portNumber 
)

Definition at line 185 of file abyss_socket.c.

void SocketCreate ( const struct TSocketVtbl *const   vtblP,
void *const   implP,
TSocket **const   socketPP 
)

Definition at line 131 of file abyss_socket.c.

References MALLOCVAR, _TConn::socketP, and socketSignature.

uint32_t SocketError ( TSocket *const   socketP  ) 

Definition at line 260 of file abyss_socket.c.

void SocketGetPeerName ( TSocket *const   socketP,
TIPAddr *const   ipAddrP,
uint16_t *const   portNumberP,
abyss_bool *const   successP 
)

Definition at line 249 of file abyss_socket.c.

Referenced by ConnCreate().

abyss_bool SocketInit ( void   ) 

Definition at line 96 of file abyss_socket.c.

References NULL, socketOsInit(), and SocketTraceIsActive.

abyss_bool SocketListen ( TSocket *const   socketP,
uint32_t const   backlog 
)

Definition at line 205 of file abyss_socket.c.

uint32_t SocketRead ( TSocket *const   socketP,
unsigned char *const   buffer,
uint32_t const   len 
)

Definition at line 175 of file abyss_socket.c.

void SocketTerm ( void   ) 

Definition at line 112 of file abyss_socket.c.

References socketOsTerm().

uint32_t SocketWait ( TSocket *const   socketP,
abyss_bool const   rd,
abyss_bool const   wr,
uint32_t const   timems 
)

Definition at line 230 of file abyss_socket.c.

void SocketWrite ( TSocket *const   socketP,
const unsigned char *const   buffer,
uint32_t const   len,
abyss_bool *const   failedP 
)

Definition at line 164 of file abyss_socket.c.


Variable Documentation

abyss_bool SocketTraceIsActive

Definition at line 93 of file abyss_socket.c.

Referenced by SocketInit(), socketRead(), and socketWrite().


Generated on Thu May 17 10:00:33 2012 for Kamailio - The Open Source SIP Server by  doxygen 1.5.6