6.1-roTCPStream
ON THIS PAGE
ifStreamReceive
SetLineEventPort(a As Object)
Â
SetByteEventPort(a As Object)
Â
SetReceiveEol(a As String)
Â
SetMatcher(matcher As Object) As Boolean
Instructs the stream to use the specified matcher. This object returns True if successful. Pass Invalid to this method to stop using the specified matcher.
Â
ifUserData
SetUserData(user_data As Object)
Sets the user data that will be returned when events are raised.
GetUserData() As Object
Returns the user data that has previously been set via SetUserData(). It will return Invalid if no data has been set.
ifStreamSend
SetSendEol(eol_sequence As String) As Void
Sets the EOL sequence when writing to the stream. The default value is CR (ASCII value 13). If you need to set this value to a non-printing character, use the chr()
 global function.
SendByte(byte As Integer) As Void
Writes the specified byte to the stream.
SendLine(string As String) As Void
Writes the specified characters to the stream followed by the current EOL sequence.
SendBlock(a As Dynamic) As Void
Writes the specified characters to the stream. This method can support either a string or an roByteArray. If the block is a string, any null bytes will terminate the block.
Flush()
ifTCPStream
GetFailureReason() As String
Yields additional useful information if an roTCPStream method fails.
ConnectTo(a As String, b As Integer) As Boolean
Connects the stream to the specified host (designated using a dotted quad) and port. The function returns True upon success.
Accept(a As Object) As Boolean
Accepts an incoming connection event. The function returns True upon success.
AsyncConnectTo(a As String, b As Integer) As Boolean
Attempts to connect the stream to the specified host (designated using a dotted quad) and port. The function returns False if this action is immediately impossible (for example, when the specified host is not in the correct format). Otherwise, the function returns True upon success. The connect proceeds in the background, and an roStreamConnectResultEvent is posted to the associated message port when the connect attempt succeeds or fails.