sipxportlib
Version 3.3
|
#include <IStunSocket.h>
Public Member Functions | |
virtual | ~IStunSocket () |
virtual OsSocket * | getSocket ()=0 |
virtual int | socketWrite (const char *buffer, int bufferLength, const char *ipAddress, int port, PacketType packetType=UNKNOWN_PACKET)=0 |
virtual UtlBoolean | getRelayIp (UtlString *ip, int *port)=0 |
virtual UtlBoolean | getMappedIp (UtlString *ip, int *port)=0 |
virtual void | enableTransparentReads (bool bEnable)=0 |
virtual void | enableStun (const char *szStunServer, int stunPort, int iKeepAlive, int stunOptions, bool bReadFromSocket)=0 |
virtual void | setStunAddress (const UtlString &address, const int iPort)=0 |
virtual void | setTurnAddress (const UtlString &address, const int iPort)=0 |
virtual void | markStunFailure ()=0 |
virtual void | markStunSuccess (bool bAddressChanged)=0 |
virtual void | markTurnFailure ()=0 |
virtual void | markTurnSuccess ()=0 |
virtual void | evaluateDestinationAddress (const UtlString &address, int iPort, int priority)=0 |
virtual void | enableTurn (const char *szTurnSever, int turnPort, int iKeepAlive, const char *username, const char *password, bool bReadFromSocket)=0 |
virtual void | readyDestination (const char *szAddress, int iPort)=0 |
virtual UtlBoolean | applyDestinationAddress (const char *szAddress, int iPort)=0 |
virtual UtlBoolean | getBestDestinationAddress (UtlString &address, int &iPort)=0 |
virtual void | addAlternateDestination (const char *szAddress, int iPort, int priority)=0 |
virtual void | setReadNotification (OsNotification *pNotification)=0 |
virtual bool | getFirstReadTime (OsDateTime &time)=0 |
virtual bool | getLastReadTime (OsDateTime &time)=0 |
virtual bool | getFirstWriteTime (OsDateTime &time)=0 |
virtual bool | getLastWriteTime (OsDateTime &time)=0 |
virtual void | destroy ()=0 |
Generic interface representing a media transport object. Implemented by VoiceEngineDatagramSocket, VoiceEngineConnectionSocket, and any other class which provides RTP transport for VoiceEngine.
|
inlinevirtual |
virtual destructor.
|
pure virtual |
Implemented in OsNatDatagramSocket, OsNatSocketBaseImpl, and OsNatConnectionSocket.
|
pure virtual |
Standard write - should be used to invoke the base class's write method
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Enable STUN. Enabling STUN will reset the the keep alive timer and will force a binding refresh.
szStunServer | |
stunPort | |
iKeepAlive | |
stunOptions | |
bReadFromSocket |
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Sets the STUN-resolved address and port for this socket.
address | String containing the stunned address. |
iPort | integer value of the stunned port. |
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Set the TURN-dervied relay address for this socket.
address | TURN-derived hostname/IP address |
iPort | TURN-derived port address |
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Report that a stun attempt failed.
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Report that a stun attempt succeeded.
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Report that a stun attempt failed.
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Report that a stun attempt succeeded.
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Reset the destination address for this OsNatDatagramSocket. This method is called by the OsStunAgentTask when a better address is found via STUN/ICE.
address | The new destination address |
iPort | The new destination port |
priority | Priority of the destination address |
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Enable STUN. Enabling STUN will reset the the keep alive timer and will force a binding refresh.
szTurnSever | |
turnPort | |
iKeepAlive | |
username | |
password | |
bReadFromSocket |
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Prepares a destination under TURN usage.
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
TODO: DOCS
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
TODO: DOCS
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Add an alternate destination to this OsNatDatagramSocket. Alternate destinations are tested by sending stun packets. If a stun response is received and the priority is greater than what has already been selected then that address is used.
szAddress | IP address of the alternate destination |
iPort | port number of the alternate destination |
priority | priority of the alternate where a higher number indicates a higher priority. |
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.
|
pure virtual |
Set a notification object to be signaled when the first the data packet is received from the socket. Once this is signaled, the notification object is discarded.
Implemented in OsNatDatagramSocket, and OsNatSocketBaseImpl.
|
pure virtual |
Get the timestamp of the first read data packet (excluding any STUN/TURN/NAT packets).
Implemented in OsNatSocketBaseImpl.
|
pure virtual |
Get the timestamp of the last read data packet (excluding any STUN/TURN/NAT packets).
Implemented in OsNatSocketBaseImpl.
|
pure virtual |
Get the timestamp of the first written data packet (excluding any STUN/TURN/NAT packets).
Implemented in OsNatSocketBaseImpl.
|
pure virtual |
Get the timestamp of the last written data packet (excluding any STUN/TURN/NAT packets).
Implemented in OsNatSocketBaseImpl.
|
pure virtual |
Cleanup routine.
Implemented in OsNatDatagramSocket, and OsNatConnectionSocket.