h1.post-title { color:orange; font-family:verdana,Arial; font-weight:bold; padding-bottom:5px; text-shadow:#64665b 0px 1px 1px; font-size:32px; } -->

Pages

async -- C# Keyword

async  -- C# Keyword


  • This Keyword is implemented from VS 2012.
  •         Use the async modifier to specify that a method, lambda expression, or anonymous method is asynchronous.
  •         If you use this modifier on a method or expression, it's referred to as an async method.

public async Task<int> ExampleMethodAsync()
{
    // . . . .

}

in -- C# Keyword

in -- C# Keyword


  •    This Keyword is implemented from VS 2010.
  •    The in keyword specifies that the type parameter is contravariant.
  •    You can use the in keyword in generic interfaces and delegates.

// Contravariant interface.

interface <Interface Name><in A> { }