reSIProcate
SIP stack, Dialog Usage Manager and related libraries
Loading...
Searching...
No Matches
Udp.hxx File Reference
#include "rutil/Socket.hxx"

Go to the source code of this file.

Functions

resip::Socket openPort (unsigned short port, unsigned int interfaceIp, bool verbose)
 Open a UDP socket to receive on the given port - if port is 0, pick a a port, if interfaceIp!=0 then use ONLY the interface specified instead of all of them

 
bool getMessage (resip::Socket fd, char *buf, int *len, uint32_t *srcIp, unsigned short *srcPort, bool verbose)
 recive a UDP message
 
bool sendMessage (resip::Socket fd, char *msg, int len, unsigned int dstIp, unsigned short dstPort, bool verbose)
 send a UDP message
 

Function Documentation

◆ getMessage()

bool getMessage ( resip::Socket  fd,
char *  buf,
int *  len,
uint32_t *  srcIp,
unsigned short *  srcPort,
bool  verbose 
)

recive a UDP message

Definition at line 118 of file Udp.cxx.

◆ openPort()

resip::Socket openPort ( unsigned short  port,
unsigned int  interfaceIp,
bool  verbose 
)

Open a UDP socket to receive on the given port - if port is 0, pick a a port, if interfaceIp!=0 then use ONLY the interface specified instead of all of them

Definition at line 38 of file Udp.cxx.

◆ sendMessage()

bool sendMessage ( resip::Socket  fd,
char *  msg,
int  len,
unsigned int  dstIp,
unsigned short  dstPort,
bool  verbose 
)

send a UDP message

Definition at line 187 of file Udp.cxx.