11.04.2013 Views

UniBasic Commands Reference - Rocket Software

UniBasic Commands Reference - Rocket Software

UniBasic Commands Reference - Rocket Software

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

eadSocket<br />

Syntax<br />

readSocket(socket_handle, socket_data, max_read_size, time_out, blocking_mode,<br />

actual_read_size)<br />

Note: This function is case-sensitive. If you want it to be case-insensitive, you<br />

must compile your programs using the BASIC command with the -i option.<br />

Description<br />

Use the readSocket function to read data in the socket buffer up to max_read_size<br />

characters.<br />

Parameters<br />

The following table describes each parameter of the syntax.<br />

Parameter Description<br />

1-638 <strong>UniBasic</strong> <strong>Commands</strong> <strong>Reference</strong><br />

socket_handle The handle to the open socket.<br />

socket_data The data to be read from the socket.<br />

max_read_size The maximum mumber of characters to return. If this is 0, then<br />

the entire buffer should be returned.<br />

time_out The time (in milliseconds) before a return in blocking mode.<br />

This is ignored for non-blocking read.<br />

blocking_mode 0:using current mode<br />

1:blocking<br />

2:non-blocking<br />

actual_read_size The number of characters actually read. -1 if error.<br />

readSocket Parameters

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!