Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Paul Betts committed Sep 13, 2012
1 parent 4fae298 commit 2d760c3
Showing 1 changed file with 12 additions and 8 deletions.
20 changes: 12 additions & 8 deletions README.md
Expand Up @@ -4,6 +4,10 @@ In a world where many methods return `Task<T>` or other Awaitable types
(especially in WinRT), LINQ can't be used nearly as easily. Enter LinqToAwait:

```
using System;
using System.Reactive.Linq;
using LinqToAwait;
var inputs = new[] {
"http://www.google.com",
"http://www.yahoo.com",
Expand All @@ -13,26 +17,26 @@ var inputs = new[] {
IEnumerable<string> results = await inputs.AsAsync()
.WhereAsync(async x => await IsPageInTop10WebSitesByTrafficAsync(x))
.SelectAsync(async x => await DownloadPageAsync(x))
.Select(x => x.Substring(0, 50))
.GetResults();
>>> ["<html>...."]
```

## Where does this work?
### Where does this work?

Currently, you're going to need Visual Studio 11 - you can use LinqToAwait with both C# Metro-based applications, as well as standard .NET 4.5 applications.
You're going to need Visual Studio 2012 - you can use LinqToAwait with .NET 4.5 applications.

## Hey, isn't this kind of like Rx?
### Hey, isn't this kind of like Rx?

It **is** Rx! However, it is a simplification of the API used for a more
specific use-case. Instead of choosing async/await *or* Rx, LinqToAwait helps
you use both at the same time, applying the most straightforward technique for
the particular problem.

## How do I get started?

It's .NET, how else? [Use NuGet!](http://nuget.org/packages/linqtoawait). There's a trick though: since Rx 2.0 is currently in beta, you need to install the package from the Powershell Console:
### How do I get started?

It's .NET, how else? [Use NuGet!](http://nuget.org/packages/linqtoawait).
```
Install-Package LinqToAwait -pre
```
Install-Package LinqToAwait
```

0 comments on commit 2d760c3

Please sign in to comment.