tsNet
Type
library
Description
tsNet is a LiveCode external that replaces and enhances the networking capabilities of the platform.
© 2016 Tech Strategies
Exclusively licensed worldwide to LiveCode Ltd
Associated Syntax
Command
Name | Summary | Syntax |
---|---|---|
tsNetInit | Initialises the tsNet external. This must be done prior to calling any other functions within the tsNet library. | tsNetInit |
tsNetClose | Closes all open connections and disables the tsNet external. | tsNetClose |
tsNetCABundle | Sets a CA bundle to be used for SSL connections within the tsNet external. | tsNetCABundle <pCAFile> |
tsNetLibUrlReuseConnection | Enable or disable connection re-use when using tsNet with libUrl. | tsNetLibUrlReuseConnection <pEnable> |
tsNetVerifySSLPeer | Enable or disable SSL peer certificate verification. | tsNetVerifySSLPeer <pEnable> |
tsNetSSLNoRevoke | Enable or disable SSL certificate revocation checks. | tsNetSSLNoRevoke <pEnable> |
tsNetSuppressConnectHeaders | Prevent proxy CONNECT responses from being included in the returned HTTP headers | tsNetSuppressConnectHeaders <pEnable> |
tsNetRedirEnable | Enable or disable automatic following of HTTP redirects. | tsNetRedirEnable <pEnable> |
tsNetCreateMissingDirs | Enable or disable automatic creation of missing directories when uploading files via FTP or SFTP. | tsNetCreateMissingDirs <pEnable> |
tsNetSetFTPPort | Enable or disable the use of active transfers for FTP. | tsNetSetFTPPort <pPort> |
tsNetSetDirNLST | Enable or disable "simple" directory listings over FTP and SFTP. | tsNetSetDirNLST <pEnable> |
tsNetSetTimeouts | Adjust the timeout values used by tsNet external. | tsNetSetTimeouts <pDnsCacheTimeout>, <pRequestTimeoutMS>, <pConnectTimeoutMS>, <pAcceptTimeoutMS>, <pLowSpeedTime>, <pLowSpeedLimit> |
tsNetSetProxy | Enable or disable the use of a proxy for networking transfers. | tsNetSetProxy <pProxyURL>, <pNoProxy>, <pUsername>, <pPassword> |
tsNetSetStatusCallback | Sends a message to the given callback when status updates are available for network transfers. | tsNetSetStatusCallback <pCallback> |
tsNetSetDebugCallback | Sends a message to the given callback with verbose debug information during network transfers. | tsNetSetDebugCallback <pCallback> |
tsNetCloseConn | Removes the specified connection from memory. | tsNetCloseConn <pConnectionID> |
Function
Name | Summary | Syntax |
---|---|---|
tsNetGenerateKey | Generates an RSA public/private key for use with SFTP transfers. | tsNetGenerateKey(<pKeyLength>, <rPrivateKey>, <rPublicKey>, <pPassphrase>, [<pFormat]) |
tsNetVersion | Returns the version of the tsNet external. | tsNetVersion() |
tsNetIsSyncBlocked | Returns whether another synchronous call can be made immediately. | tsNetIsSyncBlocked() |
tsNetGetTimeouts | Returns the current timeout values used by tsNet external. | tsNetGetTimeouts() |
tsNetGetStatus | Returns the status of the specified transfer. | tsNetGetStatus(<pConnectionID>) |
tsNetRetrError | Returns the error message of a failed transfer. | tsNetRetrError(<pConnectionID>) |
tsNetRetrData | Retrieve any returned data from a transfer. | tsNetRetrData(<pConnectionID>, <rError>) |
tsNetRetrHeaders | Retrieve any returned headers from a transfer. | tsNetRetrHeaders(<pConnectionID>, <rError>) |
tsNetRetrSentHeaders | Retrieve any headers sent to the server during a transfer. | tsNetRetrSentHeaders(<pConnectionID>, <rError>) |
tsNetHead | Send an asynchronous request to a server specifying that no body be transferred. | tsNetHead(<pConnectionID>, <pURL>, <pHeaders>, <pCallback>, [<pSettings>]) |
tsNetHeadSync | Send a synchronous request to a server specifying that no body be transferred. | tsNetHeadSync(<pURL>, <xHeaders>, <rResult>, <rBytes>, [<pSettings>]) |
tsNetSendCmd | Send an asynchronous command to a FTP or SFTP server. | tsNetSendCmd(<pConnectionID>, <pURL>, <pCommand>, <pCallback>, [<pSettings>]) |
tsNetSendCmdSync | Send a synchronous command to a FTP or SFTP server. | tsNetSendCmdSync(<pURL>, <pCommand>, <rResult>, <rBytes>, [<pSettings>]) |
tsNetCustom | Send an asynchronous custom request to a server. | tsNetCustom(<pConnectionID>, <pURL>, <pRequest>, <pHeaders>, <pCallback>, [<pSettings>]) |
tsNetCustomSync | Send a synchronous custom request to a server. | tsNetCustomSync(<pURL>, <pRequest>, <xHeaders>, <rOutHeaders>, <rResult>, <rBytes>, [<pSettings>]) |
tsNetCustomUpload | Send an asynchronous upload request to a server using a custom request method. | tsNetCustomUpload(<pConnectionID>, <pURL>, <pRequest>, <pHeaders>, <pCallback>, <pData>, [<pSettings>]) |
tsNetCustomUploadSync | Send a synchronous upload request to a server using a custom request method. | tsNetCustomUploadSync(<pURL>, <pRequest>, <xHeaders>, <pData>, <rOutHeaders>, <rResult>, <rBytes>, [<pSettings>]) |
tsNetCustomUploadFile | Send an asynchronous upload request to a server which retrieves the data to be sent directly from a file using a custom request method. | tsNetCustomUploadFile(<pConnectionID>, <pFile>, <pURL>, <pRequest>, <pHeaders>, <pCallback>, [<pSettings>]) |
tsNetCustomUploadFileSync | Send a synchronous upload request to a server which retrieves the data to be sent directly from a file using a custom request method. | tsNetCustomUploadFileSync(<pFile>, <pURL>, <pRequest>, <xHeaders>, <rOutHeaders>, <rResult>, <rBytes>, [<pSettings>]) |
tsNetGet | Send an asynchronous GET request to a server. | tsNetGet(<pConnectionID>, <pURL>, <pHeaders>, <pCallback>, [<pSettings>]) |
tsNetGetSync | Send a synchronous GET request to a server. | tsNetGetSync(<pURL>, <xHeaders>, <rOutHeaders>, <rResult>, <rBytes>, [<pSettings>]) |
tsNetGetFile | Send an asynchronous GET request to a server which stores the returned data directly to a file. | tsNetGetFile(<pConnectionID>, <pFile>, <pURL>, <pHeaders>, <pCallback>, [<pSettings>]) |
tsNetGetFileSync | Send a synchronous GET request to a server which stores the returned data directly to a file. | tsNetGetFileSync(<pFile>, <pURL>, <xHeaders>, <rOutHeaders>, <rBytes>, [<pSettings>]) |
tsNetPost | Send an asynchronous POST request to a server. | tsNetPost(<pConnectionID>, <pURL>, <pHeaders>, <pPostData>, <pCallback>, [<pSettings>]) |
tsNetPostSync | Send a synchronous POST request to a server. | tsNetPostSync(<pURL>, <xHeaders>, <pPostData>, <rOutHeaders>, <rResult>, <rBytes>, [<pSettings>]) |
tsNetUpload | Send an asynchronous upload request to a server. | tsNetUpload(<pConnectionID>, <pURL>, <pHeaders>, <pCallback>, <pData>, [<pSettings>]) |
tsNetUploadSync | Send a synchronous upload request to a server. | tsNetUploadSync(<pURL>, <xHeaders>, <pData>, <rOutHeaders>, <rResult>, <rBytes>, [<pSettings>]) |
tsNetUploadFile | Send an asynchronous upload request to a server which retrieves the data to be sent directly from a file. | tsNetUploadFile(<pConnectionID>, <pFile>, <pURL>, <pHeaders>, <pCallback>, [<pSettings>]) |
tsNetUploadFileSync | Send a synchronous upload request to a server which retrieves the data to be sent directly from a file. | tsNetUploadFileSync(<pFile>, <pURL>, <xHeaders>, <rOutHeaders>, <rResult>, <rBytes>, [<pSettings>]) |
tsNetSmtp | Send an asynchronous upload request to a server. | tsNetSmtp(<pConnectionID>, <pURL>, <pFrom>, <pRcpt>, <pCallback>, <pData>, [<pSettings>]) |
tsNetSmtpSync | Send a synchronous upload request to a server. | tsNetSmtpSync(<pURL>, <pFrom>, <pRcpt>, <pData>, <rOutHeaders>, <rBytes>, [<pSettings>]) |
tsNetSmtpFile | Send an asynchronous upload request to a server which retrieves the data to be sent directly from a file. | tsNetSmtpFile(<pConnectionID>, <pFile>, <pURL>, <pFrom>, <pRcpt>, <pCallback>, [<pSettings>]) |
tsNetSmtpFileSync | Send a synchronous upload request to a server which retrieves the data to be sent directly from a file. | tsNetSmtpFileSync(<pFile>, <pURL>, <pFrom>, <pRcpt>, <rOutHeaders>, <rBytes>, [<pSettings>]) |