title: Can someone explain what the C# "Func<T,T>" does?
body: <p>I'm reading the Pro MVC 2 book, and there is an example of creating an extension method for the HtmlHelper class.</p>
  
  <p>Here the code example:</p>
  
  <pre><code>public static MvcHtmlString PageLinks(this HtmlHelper html, PagingInfo pagingInfo, Func&lt;int,string&gt; pageUrl)
  {
      //Magic here.
  }
  </code></pre>
  
  <p>And here is an example usage:</p>
  
  <pre><code>[Test]
  public void Can_Generate_Links_To_Other_Pages()
  {
      //Arrange: We're going to extend the Html helper class.
      //It doesn't matter if the variable we use is null            
      HtmlHelper html = null;
  
      PagingInfo pagingInfo = PagingInfo(){
          CurrentPage = 2,
          TotalItems = 28,
          ItemsPerPage = 10
      };
  
      Func&lt;int, String&gt; pageUrl = i =&gt; "Page" + i;
  
      //Act: Here's how it should format the links.
      MvcHtmlString result = html.PageLinks(pagingInfo, pageUrl);
  
      //Assert:
      result.ToString().ShouldEqual(@"&lt;a href=""Page1""&gt;1&lt;/a&gt;&lt;a href=""Page2""&gt;2&lt;/a&gt;&lt;a href=""Page3""&gt;3&lt;/a&gt;")           
  
  }
  </code></pre>
  
  <p>Edit: Removed part that confused the <strong>point</strong> of this question.</p>
  
  <p>The question is: Why is the example using Func? When should I use it? What is Func?</p>
  
  <p>Thanks!</p>