Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

F# AsyncWaitOne and AsyncReadToEnd

I am working ti old F# code from Expert F#. However, the example doesn't build anymore. The following two calls don't seem to exist:

semaphore.AsyncWaitOne(?millisecondsTimeout=timeout) 

and

reader.ReadToEndAsync()

Does anyone know what these have been replaced with or if I am just missing a reference?

like image 238
Jeff Avatar asked Aug 20 '10 22:08

Jeff


2 Answers

It's now called Async.AwaitWaitHandle.

AsyncReadToEnd is in the F# PowerPack.

like image 126
Brian Avatar answered Nov 18 '22 10:11

Brian


By now, FSharp PowerPack project has been broken up into smaller modules for any further development. Specifically, the AsyncStreamReader class and the extension methods for the reading from a StreamReader, WebClient, etc. the new project is FSharpx.Async.

like image 21
Stanislav Vitebskiy Avatar answered Nov 18 '22 10:11

Stanislav Vitebskiy