C++ IP API  9.5.7
TCP & UDP for virtual user scripts
Facilita::UdpLinkFactory Class Reference

This is a factory class for the creation of UdpLink objects in the context of an IpVirtualUser. More...

Inheritance diagram for Facilita::UdpLinkFactory:
Collaboration diagram for Facilita::UdpLinkFactory:

Public Methods

 UdpLinkFactory (VirtualUserInterface *vu, LockableLog *log, const UdpFactoryProperties *properties)
 A standard constructor that is not called directly by test scripts.. More...
 
virtual ~UdpLinkFactory ()
 
bool isLoggingEnabled () const
 This read only property indicates if logging is enabled. More...
 
Public Factory Methods

Creating UdpLink objects.

UdpLink createLink (const IpEndPoint &remoteIpEndPoint)
 Create UdpLink with an unspecified local IpEndPoint and the remote IpEndPoint as given. More...
 
UdpLink createDirectedLink (const IpEndPoint &remoteIpEndPoint)
 Create a directed UdpLink with an unspecified local IpEndPoint and the remote IpEndPoint as given. More...
 
UdpLink createDirectedLink (const IpEndPoint &localIpEndPoint, const IpEndPoint &remoteIpEndPoint)
 Create UdpLink with a specified local and remote IpEndPoint. More...
 
UdpLink UdpLinkFactory::waitForLink (const IpEndPoint &localIpEndPoint)
 Create UdpLink with a specified local IpEndPoint. More...
 
Public Properties

Properties whose values are copied to a UdpLink on creation.

See also
UdpLink.
int getSendRetries () const
 Return the number of times sending data will be attempted before giving up. More...
 
void setSendRetries (int retries)
 Set the number of retries that can be attempted. More...
 
int getBufferSize () const
 Return the size of the buffer used to receive data from the network. It should be less than or equal to maxUdpSize. More...
 
void setBufferSize (int bufferSize)
 Set the current buffer size. More...
 
int getDnsTimeout () const
 Get the maximum time spent on a look up of an IP address. More...
 
void setDnsTimeout (int timeout)
 Set the DNS look up timeout. More...
 
int getDnsRetries () const
 Get the number of time a DNS look is made before giving up. More...
 
void setDnsRetries (int retries)
 Set the number of DNS lookup retries that can be made. More...
 
int getReceiveTimeout () const
 Return the the maximum time spent waiting for a data on a receive call. More...
 
void setReceiveTimeout (int timeout)
 Set the receive timeout. More...
 
Further Public Properties

This read only property returns a short string describing this object.

Properties of this factory.

int getLinkTimeout () const
 Get the maximum time spent waiting for a UdpLink on a waitForLink. More...
 
void setLinkTimeout (int timeout)
 Set the link timeout. More...
 

Detailed Description

This is a factory class for the creation of UdpLink objects in the context of an IpVirtualUser.

An instance of this class has properties whose values are copied to the corresponding properties of all UdpLink objects it creates.

Constructors

Facilita::UdpLinkFactory::UdpLinkFactory ( VirtualUserInterface *  vu,
LockableLog *  log,
const UdpFactoryProperties *  properties 
)

A standard constructor that is not called directly by test scripts..

virtual Facilita::UdpLinkFactory::~UdpLinkFactory ( )
virtual

Methods

UdpLink Facilita::UdpLinkFactory::createDirectedLink ( const IpEndPoint remoteIpEndPoint)

Create a directed UdpLink with an unspecified local IpEndPoint and the remote IpEndPoint as given.

The link is "directed" meaning remote IpEndPoint remains unchanged as datagrams are received are exchanged between the two specified peers.

Parameters
remoteIpEndPointThe value of the remote IpEntPoint of the newly constructed UdpLink.
Returns
A newly constructed UdpLink.
UdpLink Facilita::UdpLinkFactory::createDirectedLink ( const IpEndPoint localIpEndPoint,
const IpEndPoint remoteIpEndPoint 
)

Create UdpLink with a specified local and remote IpEndPoint.

The link is "directed" meaning remote IpEndPoint remains unchanged as datagrams are received are exchanged between the two specified peers.

Parameters
localIpEndPointThe value of the local IpEntPoint of the newly constructed UdpLink.
remoteIpEndPointThe value of the remote IpEntPoint of the newly constructed UdpLink.
Returns
A newly constructed UdpLink.
UdpLink Facilita::UdpLinkFactory::createLink ( const IpEndPoint remoteIpEndPoint)

Create UdpLink with an unspecified local IpEndPoint and the remote IpEndPoint as given.

The link is "non-directed" meaning as the remote IpEndPoint may change as datagrams are received from varying IP addresses and ports.

Parameters
remoteIpEndPointThe value of the remote IpEntPoint of the newly constructed UdpLink. The destination of the at least the first send
Returns
A newly constructed UdpLink.
int Facilita::UdpLinkFactory::getBufferSize ( ) const

Return the size of the buffer used to receive data from the network. It should be less than or equal to maxUdpSize.

Returns
The current buffer size.
int Facilita::UdpLinkFactory::getDnsRetries ( ) const

Get the number of time a DNS look is made before giving up.

Returns
The current number of retries that would be made.
int Facilita::UdpLinkFactory::getDnsTimeout ( ) const

Get the maximum time spent on a look up of an IP address.

Returns
The timeout value in milliseconds.
int Facilita::UdpLinkFactory::getLinkTimeout ( ) const

Get the maximum time spent waiting for a UdpLink on a waitForLink.

Returns
The current timeout in milliseconds.
int Facilita::UdpLinkFactory::getReceiveTimeout ( ) const

Return the the maximum time spent waiting for a data on a receive call.

Returns
The current timeout in milliseconds.
int Facilita::UdpLinkFactory::getSendRetries ( ) const

Return the number of times sending data will be attempted before giving up.

Returns
The retry count.
bool Facilita::UdpLinkFactory::isLoggingEnabled ( ) const

This read only property indicates if logging is enabled.

Returns
True if logging enabled else false.
void Facilita::UdpLinkFactory::setBufferSize ( int  bufferSize)

Set the current buffer size.

Parameters
bufferSizeThe number of bytes to set the buffer size.
void Facilita::UdpLinkFactory::setDnsRetries ( int  retries)

Set the number of DNS lookup retries that can be made.

Parameters
retriesThe number retries that can be made on a DNS look up.
void Facilita::UdpLinkFactory::setDnsTimeout ( int  timeout)

Set the DNS look up timeout.

Parameters
timeoutThe time in milliseconds to set the DNS look up timeout.
void Facilita::UdpLinkFactory::setLinkTimeout ( int  timeout)

Set the link timeout.

Parameters
timeoutThe timeout value in milliseconds.
void Facilita::UdpLinkFactory::setReceiveTimeout ( int  timeout)

Set the receive timeout.

Parameters
timeoutThe timeout value in milliseconds.
void Facilita::UdpLinkFactory::setSendRetries ( int  retries)

Set the number of retries that can be attempted.

Parameters
retriesThe number of retries.
UdpLink Facilita::UdpLinkFactory::UdpLinkFactory::waitForLink ( const IpEndPoint localIpEndPoint)

Create UdpLink with a specified local IpEndPoint.

The link is "non-directed" meaning as the remote IpEndPoint may change as datagrams are received from varying IP addresses and ports. The call is on a timeout see

Parameters
localIpEndPointThe value of the local IpEntPoint of the newly constructed UdpLink.
Returns
A newly constructed UdpLink.

The documentation for this class was generated from the following file: