title: Directory.EnumerateFiles => UnauthorizedAccessException
body: <p>There is a nice new method in .NET 4.0 for getting files in a directory in a streaming way via enumeration.</p>
  
  <p>The problem here is that if one wishes to enumerate all files one may not know in advance which files or folders are access protected and can throw an UnauthorizedAccessException. </p>
  
  <p>To reproduce, one can just run this fragment:</p>
  
  <pre><code>foreach (var file in Directory.EnumerateFiles(@"c:\", "*", SearchOption.AllDirectories))
  {
     // whatever
  }
  </code></pre>
  
  <p>Before this .NET method existed it was possible to achieve roughly the same effect by implementing a recursive iterator on the string-array returning methods. But it's not quite as lazy as the new .NET method is.</p>
  
  <p>So what to do? Can the UnauthorizedAccessException be suppressed or is a fact of life when using this method?</p>
  
  <p>Seems to me that the method should have an overload accepting an action to deal with any exceptions.</p>