Blocking stream & converting

  • Thread starter Thread starter Guy Korland
  • Start date Start date
G

Guy Korland

Hi,

1. How can I read stream in blocking mode? Meaning stop the thread till it
get a new line sign?

Or getting an event from the stream on new income data?

2. How can I convert 2 bytes to char?



Thanks

Guy
 
Guy,

Where are you reading this from? If you are reading from a network
stream, then it will block until there is data on the line (I believe). If
you are reading from a console, then you can just call the readline method,
and it will block until a new line is entered into the console.

Hope this helps.
 
Back
Top