Cuemon .NET Framework
Flatten(Exception) Method

The exception to flatten.
Flattens any inner exceptions descendant-or-self from the specified exception into an IEnumerable sequence of exceptions.
Syntax
'Declaration
 
Public Overloads Shared Function Flatten( _
   ByVal exception As Exception _
) As IEnumerable(Of Exception)
public static IEnumerable<Exception> Flatten( 
   Exception exception
)

Parameters

exception
The exception to flatten.

Return Value

An empty IEnumerable sequence if no inner exceptions was specified; otherwise any inner exceptions rooted to the specified exception as well as it's descendants.
Exceptions
ExceptionDescription
System.ArgumentNullExceptionexception is null.
Remarks
If any inner exceptions are referenced this method will iterative flatten all of them descendant-or-self from the specified exception.
Should the exception be of the new AggregateException type introduced with .NET 4.0, the return sequence of this method will be equal to the result of the InnerExceptions property.
Requirements

Target Platforms: Windows 8, Windows Server 2012, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

ExceptionUtility Class
ExceptionUtility Members
Overload List

 

 


| Cuemon is licensed under a The MIT License (MIT)



© 2009-2015 Weubphoria. All Rights Reserved.

Documentation made easy with Document! X by Innovasys

Send Feedback