SOCKET CLOSE()

From Lianjapedia
Jump to: navigation, search

Purpose

Function to close an open socket connection

Syntax

SOCKET_CLOSE(<expN>)

See Also

ACLASS(), ADDPROPERTY(), AMEMBERS(), COMPOBJ(), CREATEOBJECT(), DEFINE CLASS, DISPLAY CLASSES, DODEFAULT(), FOREACH, JSON_DECODE_FILE(), JSON_ENCODE(), LIST CLASSES, LOADOBJECT(), NEWOBJECT(), OBJECT(), PRINT_JSON(), PRINT_HTML(), PRINT_R(), PRINT_XML(), REMOVEPROPERTY(), REQUIRE_ONCE(), SAVEOBJECT(), SELECT, SOCKET_LASTERROR(), SOCKET_OPEN(), SOCKET_PEEK(), SOCKET_READ(), SOCKET_SERVER(), SOCKET_WRITE(), WITH, XML_DECODE_FILE()

Description

The SOCKET_CLOSE() function is used to close an open socket connection. The <expN> is the socket number returned from SOCKET_OPEN() or SOCKET_SERVER().

Example

// close the socket connection
m_skt = socket_close(skt)
if m_skt != skt
    // error closing socket
endif