Skip to content
gdoron edited this page Nov 3, 2014 · 3 revisions

Async Support

Methods on IGraphClient that have an Async suffix on their name work with the new await keyword in C# 5.

This means you can write code like this:

var node = await client.GetAsync<NamedNode>(625);
Console.WriteLine(node.Data.Name);

That code will drop back to a kernel-level IO completion port while the underlying network request is in progress. (Albeit at some expense of managing such marshalling, so don't just use the async methods blindly.)

Clone this wiki locally