Closes the connection with the host.

1 socket.close

<socket.close>
    <socket /> +
</socket.close>
Example

The following example shows how a connection to the host w2ksrv1y is open and closes the connection.

Copy
<xsql-script name='socket'>
    <body>
        <!-- open LPR client -->

        <set name='s'>
            <socket host='w2ksrv1' port='515' />
        </set>

        <!-- get queue state -->

        <socket.out.write>
            <s />
            <byte>4</byte>
        </socket.out.write>

        <socket.close>
            <s />
        </socket.close>
    </body>
</xsql-script>