About This eBook by Bart De Smet

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

O'Reilly logo

Asynchronous Programming Model

The oldest of the asynchronous programming patterns was introduced right from the start, with .NET Framework 1.0. We’ve already covered this pattern in passing in Chapter 17, “Delegates,” and in Chapter 28, “Working with I/O.” Nonetheless, let’s revisit this pattern briefly and identify its core characteristics.

This pattern consists of two related methods, using a Begin and End prefix convention. For example, asynchronous read operations on a Stream object are defined as follows:

IAsyncResult BeginRead(byte[] buffer, int offset, int count,                       AsyncCallback callback, object state);int EndRead(IAsyncResult asyncResult);

The BeginRead method takes all the required parameters ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required