Previous: , Up: Sockets.StreamSocket   [Index]


6.22.8 Sockets.StreamSocket: stream protocol

atEnd

Answer whether more data is available on the socket

availableBytes

Answer how many bytes are available in the socket’s read buffer or from the operating system.

bufferContents

Answer the current contents of the read buffer

canRead

Answer whether more data is available in the socket’s read buffer or from the operating system.

close

Flush and close the socket.

fill

Fill the read buffer with data read from the socket

isPeerAlive

Answer whether the connection with the peer remote machine is still valid.

next

Read a byte from the socket. This might yield control to other Smalltalk Processes.

peek

Read a byte from the socket, without advancing the buffer; answer nil if no more data is available. This might yield control to other Smalltalk Processes.

peekFor: anObject

Read a byte from the socket, advancing the buffer only if it matches anObject; answer whether they did match or not. This might yield control to other Smalltalk Processes.

readBufferSize: size

Create a new read buffer of the given size (which is only possible before the first read or if the current buffer is empty).