vlc_network.h File Reference

Include dependency graph for vlc_network.h:

Go to the source code of this file.

Data Structures

struct  virtual_socket_t
struct  pollfd
struct  addrinfo

Defines

#define net_errno   errno
#define net_Connect(a, b, c, d, e)   __net_Connect(VLC_OBJECT(a), b, c, d, e)
#define net_ListenTCP(a, b, c)   net_Listen(VLC_OBJECT(a), b, c, IPPROTO_TCP)
#define net_ConnectTCP(a, b, c)   __net_ConnectTCP(VLC_OBJECT(a), b, c)
#define net_Accept(a, b, c)   __net_Accept(VLC_OBJECT(a), b, c)
#define net_ConnectDgram(a, b, c, d, e)   __net_ConnectDgram(VLC_OBJECT(a), b, c, d, e)
#define net_OpenDgram(a, b, c, d, e, g, h)   __net_OpenDgram(VLC_OBJECT(a), b, c, d, e, g, h)
#define net_Read(a, b, c, d, e, f)   __net_Read(VLC_OBJECT(a),b,c,d,e,f)
#define net_Write(a, b, c, d, e)   __net_Write(VLC_OBJECT(a),b,c,d,e)
#define net_Gets(a, b, c)   __net_Gets(VLC_OBJECT(a),b,c)
#define net_vaPrintf(a, b, c, d, e)   __net_vaPrintf(VLC_OBJECT(a),b,c,d,e)
#define inet_pton   vlc_inet_pton
#define inet_ntop   vlc_inet_ntop
#define poll(a, b, c)   vlc_poll(a, b, c)
#define net_Close(fd)   (void)close (fd)
#define EAI_BADFLAGS   -1
#define EAI_NONAME   -2
#define EAI_AGAIN   -3
#define EAI_FAIL   -4
#define EAI_NODATA   -5
#define EAI_FAMILY   -6
#define EAI_SOCKTYPE   -7
#define EAI_SERVICE   -8
#define EAI_ADDRFAMILY   -9
#define EAI_MEMORY   -10
#define EAI_OVERFLOW   -11
#define EAI_SYSTEM   -12
#define NI_MAXHOST   1025
#define NI_MAXSERV   32
#define NI_MAXNUMERICHOST   64
#define NI_NUMERICHOST   0x01
#define NI_NUMERICSERV   0x02
#define NI_NOFQDN   0x04
#define NI_NAMEREQD   0x08
#define NI_DGRAM   0x10
#define AI_PASSIVE   1
#define AI_CANONNAME   2
#define AI_NUMERICHOST   4
#define AI_NUMERICSERV   0

Enumerations

enum  {
  POLLIN = 1, POLLOUT = 2, POLLPRI = 4, POLLERR = 8,
  POLLHUP = 16, POLLNVAL = 32
}

Functions

ssize_t vlc_sendmsg (int, struct msghdr *, int)
ssize_t vlc_recvmsg (int, struct msghdr *, int)
int net_Socket (vlc_object_t *obj, int family, int socktype, int proto)
int net_SetupSocket (int fd)
int __net_Connect (vlc_object_t *p_this, const char *psz_host, int i_port, int socktype, int protocol)
int * net_Listen (vlc_object_t *p_this, const char *psz_host, int i_port, int protocol)
static int __net_ConnectTCP (vlc_object_t *obj, const char *host, int port)
int net_AcceptSingle (vlc_object_t *obj, int lfd)
int __net_Accept (vlc_object_t *, int *, mtime_t)
int __net_ConnectDgram (vlc_object_t *p_this, const char *psz_host, int i_port, int hlim, int proto)
static int net_ConnectUDP (vlc_object_t *obj, const char *host, int port, int hlim)
int __net_OpenDgram (vlc_object_t *p_this, const char *psz_bind, int i_bind, const char *psz_server, int i_server, int family, int proto)
static int net_ListenUDP1 (vlc_object_t *obj, const char *host, int port)
void net_ListenClose (int *fd)
int net_Subscribe (vlc_object_t *obj, int fd, const struct sockaddr *addr, socklen_t addrlen)
int net_SetCSCov (int fd, int sendcov, int recvcov)
 net_SetCSCov: Sets the send and receive checksum coverage of a socket:
ssize_t __net_Read (vlc_object_t *p_this, int fd, const v_socket_t *, uint8_t *p_data, size_t i_data, bool b_retry)
ssize_t __net_Write (vlc_object_t *p_this, int fd, const v_socket_t *, const uint8_t *p_data, size_t i_data)
char * __net_Gets (vlc_object_t *p_this, int fd, const v_socket_t *)
ssize_t net_Printf (vlc_object_t *p_this, int fd, const v_socket_t *, const char *psz_fmt,...)
ssize_t __net_vaPrintf (vlc_object_t *p_this, int fd, const v_socket_t *, const char *psz_fmt, va_list args)
int vlc_inet_pton (int af, const char *src, void *dst)
 inet_pton() replacement
const char * vlc_inet_ntop (int af, const void *src, char *dst, socklen_t cnt)
 inet_ntop() replacement
int vlc_poll (struct pollfd *fds, unsigned nfds, int timeout)
const char * vlc_gai_strerror (int)
int vlc_getnameinfo (const struct sockaddr *, int, char *, int, int *, int)
int vlc_getaddrinfo (vlc_object_t *, const char *, int, const struct addrinfo *, struct addrinfo **)
void vlc_freeaddrinfo (struct addrinfo *)
static bool net_SockAddrIsMulticast (const struct sockaddr *addr, socklen_t len)
static int net_GetSockAddress (int fd, char *address, int *port)
static int net_GetPeerAddress (int fd, char *address, int *port)
static uint16_t net_GetPort (const struct sockaddr *addr)
static void net_SetPort (struct sockaddr *addr, uint16_t port)


Define Documentation

#define AI_CANONNAME   2

#define AI_NUMERICHOST   4

#define AI_NUMERICSERV   0

#define AI_PASSIVE   1

#define EAI_ADDRFAMILY   -9

#define EAI_AGAIN   -3

#define EAI_BADFLAGS   -1

#define EAI_FAIL   -4

#define EAI_FAMILY   -6

#define EAI_MEMORY   -10

#define EAI_NODATA   -5

#define EAI_NONAME   -2

#define EAI_OVERFLOW   -11

#define EAI_SERVICE   -8

#define EAI_SOCKTYPE   -7

#define EAI_SYSTEM   -12

#define inet_ntop   vlc_inet_ntop

#define inet_pton   vlc_inet_pton

#define net_Accept ( a,
b,
 )     __net_Accept(VLC_OBJECT(a), b, c)

#define net_Close ( fd   )     (void)close (fd)

#define net_Connect ( a,
b,
c,
d,
 )     __net_Connect(VLC_OBJECT(a), b, c, d, e)

#define net_ConnectDgram ( a,
b,
c,
d,
 )     __net_ConnectDgram(VLC_OBJECT(a), b, c, d, e)

#define net_ConnectTCP ( a,
b,
 )     __net_ConnectTCP(VLC_OBJECT(a), b, c)

#define net_errno   errno

#define net_Gets ( a,
b,
 )     __net_Gets(VLC_OBJECT(a),b,c)

#define net_ListenTCP ( a,
b,
 )     net_Listen(VLC_OBJECT(a), b, c, IPPROTO_TCP)

#define net_OpenDgram ( a,
b,
c,
d,
e,
g,
 )     __net_OpenDgram(VLC_OBJECT(a), b, c, d, e, g, h)

#define net_Read ( a,
b,
c,
d,
e,
 )     __net_Read(VLC_OBJECT(a),b,c,d,e,f)

#define net_vaPrintf ( a,
b,
c,
d,
 )     __net_vaPrintf(VLC_OBJECT(a),b,c,d,e)

#define net_Write ( a,
b,
c,
d,
 )     __net_Write(VLC_OBJECT(a),b,c,d,e)

#define NI_DGRAM   0x10

#define NI_MAXHOST   1025

#define NI_MAXNUMERICHOST   64

#define NI_MAXSERV   32

#define NI_NAMEREQD   0x08

#define NI_NOFQDN   0x04

#define NI_NUMERICHOST   0x01

#define NI_NUMERICSERV   0x02

#define poll ( a,
b,
 )     vlc_poll(a, b, c)


Enumeration Type Documentation

anonymous enum

Enumerator:
POLLIN 
POLLOUT 
POLLPRI 
POLLERR 
POLLHUP 
POLLNVAL 


Function Documentation

int __net_Accept ( vlc_object_t ,
int *  ,
mtime_t   
)

int __net_Connect ( vlc_object_t p_this,
const char *  psz_host,
int  i_port,
int  socktype,
int  protocol 
)

int __net_ConnectDgram ( vlc_object_t p_this,
const char *  psz_host,
int  i_port,
int  hlim,
int  proto 
)

static int __net_ConnectTCP ( vlc_object_t obj,
const char *  host,
int  port 
) [inline, static]

char* __net_Gets ( vlc_object_t p_this,
int  fd,
const v_socket_t  
)

int __net_OpenDgram ( vlc_object_t p_this,
const char *  psz_bind,
int  i_bind,
const char *  psz_server,
int  i_server,
int  family,
int  proto 
)

ssize_t __net_Read ( vlc_object_t p_this,
int  fd,
const v_socket_t ,
uint8_t *  p_data,
size_t  i_data,
bool  b_retry 
)

ssize_t __net_vaPrintf ( vlc_object_t p_this,
int  fd,
const v_socket_t ,
const char *  psz_fmt,
va_list  args 
)

ssize_t __net_Write ( vlc_object_t p_this,
int  fd,
const v_socket_t ,
const uint8_t *  p_data,
size_t  i_data 
)

int net_AcceptSingle ( vlc_object_t obj,
int  lfd 
)

static int net_ConnectUDP ( vlc_object_t obj,
const char *  host,
int  port,
int  hlim 
) [inline, static]

static int net_GetPeerAddress ( int  fd,
char *  address,
int *  port 
) [inline, static]

static uint16_t net_GetPort ( const struct sockaddr addr  )  [inline, static]

static int net_GetSockAddress ( int  fd,
char *  address,
int *  port 
) [inline, static]

int* net_Listen ( vlc_object_t p_this,
const char *  psz_host,
int  i_port,
int  protocol 
)

void net_ListenClose ( int *  fd  ) 

static int net_ListenUDP1 ( vlc_object_t obj,
const char *  host,
int  port 
) [inline, static]

ssize_t net_Printf ( vlc_object_t p_this,
int  fd,
const v_socket_t ,
const char *  psz_fmt,
  ... 
)

int net_SetCSCov ( int  fd,
int  sendcov,
int  recvcov 
)

net_SetCSCov: Sets the send and receive checksum coverage of a socket:

Parameters:
fd socket
sendcov payload coverage of sent packets (bytes), -1 for full
recvcov minimum payload coverage of received packets, -1 for full

static void net_SetPort ( struct sockaddr addr,
uint16_t  port 
) [inline, static]

int net_SetupSocket ( int  fd  ) 

static bool net_SockAddrIsMulticast ( const struct sockaddr addr,
socklen_t  len 
) [inline, static]

int net_Socket ( vlc_object_t obj,
int  family,
int  socktype,
int  proto 
)

int net_Subscribe ( vlc_object_t obj,
int  fd,
const struct sockaddr addr,
socklen_t  addrlen 
)

void vlc_freeaddrinfo ( struct addrinfo  ) 

const char* vlc_gai_strerror ( int   ) 

int vlc_getaddrinfo ( vlc_object_t ,
const char *  ,
int  ,
const struct addrinfo ,
struct addrinfo **   
)

int vlc_getnameinfo ( const struct sockaddr ,
int  ,
char *  ,
int  ,
int *  ,
int   
)

const char* vlc_inet_ntop ( int  af,
const void *  src,
char *  dst,
socklen_t  cnt 
)

inet_ntop() replacement

int vlc_inet_pton ( int  af,
const char *  src,
void *  dst 
)

inet_pton() replacement

int vlc_poll ( struct pollfd fds,
unsigned  nfds,
int  timeout 
)

ssize_t vlc_recvmsg ( int  ,
struct msghdr *  ,
int   
)

ssize_t vlc_sendmsg ( int  ,
struct msghdr *  ,
int   
)


Generated on Wed Aug 13 08:02:45 2008 for VLC by  doxygen 1.5.1