Instance Method

stream(_:handle:)

The delegate receives this message when a given event has occurred on a given stream.

Declaration

optional func stream(_ aStream: Stream, handle eventCode: Stream.Event)

Parameters

theStream

The stream on which streamEvent occurred.

streamEvent

The stream event that occurred.

Discussion

The delegate receives this message only if theStream is scheduled on a run loop. The message is sent on the stream object’s thread. The delegate should examine streamEvent to determine the appropriate action it should take.

See Also