hb_inetAddress
hb_inetCleanup
hb_inetClearError
hb_inetClearPeriodCallback
hb_inetClearTimeLimit
hb_inetClearTimeout
hb_inetClose
hb_inetConnect
hb_inetConnectIP
hb_inetCount
hb_inetCreate
hb_inetCRLF
hb_inetDataReady
hb_inetDGram
hb_inetDGramBind
hb_inetDGramRecv
hb_inetDGramSend
hb_inetErrorCode
hb_inetErrorDesc
hb_inetFD
hb_inetGetAlias
hb_inetGetHosts
hb_inetGetRcvBufSize
hb_inetGetSndBufSize
hb_inetInit
hb_inetIsSocket
hb_inetPeriodCallback
hb_inetPort
hb_inetRecv
hb_inetRecvAll
hb_inetRecvEndblock
hb_inetRecvLine
hb_inetSend
hb_inetSendAll
hb_inetServer
hb_inetSetRcvBufSize
hb_inetSetSndBufSize
hb_inetstatus
hb_inetTimeLimit
hb_inetTimeout
Tag Archives: inet
hb_inetTimeout()
HB_INETTIMEOUT()
Get or change the timeout value of a socket
Syntax
HB_INETTIMEOUT( <socket> [, <nTimeout> ] ) -> nPreviousTimeout
Arguments
<socket> a socket previously created / opened
<nTimeout> is the new socket timeout value
Returns
Returns the previous timeout value of the socket
Description
Sets or changes the timeout value of the socket.
Compliance
Harbour
hb_inetTimeLimit()
HB_INETTIMELIMIT()
Get or change the time limit value of a socket
Syntax
HB_INETTIMELIMIT( <socket> [, <nTimeLimit> ) -> NIL
Arguments
<socket> a socket previously created / opened
<nTimeLimit>
Returns
Returns the previous time limit value of the socket
Description
Sets or changes the time limit value of the socket.
Compliance
Harbour
hb_inetStatus()
HB_INETSTATUS()
Get the status of a socket
Syntax
HB_INETSTATUS( <socket> ) -> nResult
Arguments
<socket> a socket previously created / opened
Returns
Returns 1 (one) if the socket exists, -1 if it does not
Compliance
Harbour
hb_inetSetSndBufSize()
HB_INETSETSNDBUFSIZE()
Set the send buffer size of a socket
Syntax
HB_INETSETSNDBUFSIZE( <socket>, <nSize> ) -> nSize
Arguments
<socket> a socket previously created / opened
nSize
Returns
Returns the passed nSize or -1 on error
Description
Sets the send buffer size of a socket
Compliance
Harbour
hb_inetSetRcvBufSize()
HB_INETSETRCVBUFSIZE()
Set the receive buffer size of a socket
Syntax
HB_INETSETRCVBUFSIZE( <socket>, nSize ) -> nSize
Arguments
<socket> a socket previously created / opened
nSize
Returns
Returns the passed nSize or -1 on error
Description
Sets the receive buffer size of a socket
Compliance
Harbour
hb_inetServer()
HB_INETSERVER()
Create a socket bound to a port
Syntax
HB_INETSERVER( <port> [, <cBindAddr> [, <nListenLimit> ]] ) -> SOCKET
Arguments
<port>
<cBindAddr>
<nListenLimit> is an internal parameter and rarely needs to be passed, defaults to 10
Returns
An INET socket
Description
Creates a server that can accept connections from client on a certain port.
If the computer on which hb_InetServer is called has more than one logical interface (e.g. one network card, one loopback and one PPP address), cBindAddr can be specified to select only one of these interfaces to accept connections for this process. This is useful when a server is present on two networks, and the service is to be available only in one of them. Also, the same port on other addresses is left free to be used, so you can have different server programs running for different networks but managing the same service. For example, an FTP server available to the internal network could be radically different from an FTP server available for the internet.
nListenLimit is the number of incoming connections accepted by kernel before the kernel has the chance to report them to the application program. If the sockets receive nListenLimit connections before accepting them all, the nListenLimit + 1 connection will be notified to be “busy” by the kernel. The default value of 10 is enough for even a heavy duty server.
On error, sets error description in the newly returned socket.
Compliance
Harbour