C# Class Aspectacular.ExceptionExtensions

Afficher le fichier Open project: vgribok/Aspectacular

Méthodes publiques

Méthode Description
AllExceptions ( this ex ) : IEnumerable

Returns all exceptions in the chain starting from the innermost.

AllExceptionsBack ( this ex ) : IEnumerable

Returns all exceptions in the chain starting from the outermost.

Consolidate ( this ex, string separator, bool innerFirst, string>.Func converter ) : string

Joins text information from the chain of exceptions including inner ones.

ConsolidatedInfo ( this ex, string separator = null, bool innerFirst = true ) : string

Returns exception information (messages + stack traces) in the exception chain (main + inner exceptions), starting from the innermost one.

ConsolidatedMessage ( this ex, string separator = null, bool innerFirst = true ) : string

Returns all messages in the exception chain (main + inner exceptions), starting from the innermost one.

ConsolidatedStack ( this ex, string separator = null, bool innerFirst = true ) : string

Returns all stack traces in the exception chain (main + inner exceptions), starting from the innermost one.

FullInfo ( this ex ) : string

Returns string containing exception type, message and stack trace. No inner exception information included.

ToSerializable ( this ex ) : ExceptionDto

Returns Exception-like object that can serialized to XML, JSON, etc.

TypeAndMessage ( this ex ) : string

Returns string with the information of exception type and message.

Method Details

AllExceptions() public static méthode

Returns all exceptions in the chain starting from the innermost.
public static AllExceptions ( this ex ) : IEnumerable
ex this
Résultat IEnumerable

AllExceptionsBack() public static méthode

Returns all exceptions in the chain starting from the outermost.
public static AllExceptionsBack ( this ex ) : IEnumerable
ex this
Résultat IEnumerable

Consolidate() public static méthode

Joins text information from the chain of exceptions including inner ones.
public static Consolidate ( this ex, string separator, bool innerFirst, string>.Func converter ) : string
ex this
separator string
innerFirst bool True to put innermost exception on top, false for outermost.
converter string>.Func
Résultat string

ConsolidatedInfo() public static méthode

Returns exception information (messages + stack traces) in the exception chain (main + inner exceptions), starting from the innermost one.
public static ConsolidatedInfo ( this ex, string separator = null, bool innerFirst = true ) : string
ex this
separator string
innerFirst bool True to put innermost exception on top, false for outermost.
Résultat string

ConsolidatedMessage() public static méthode

Returns all messages in the exception chain (main + inner exceptions), starting from the innermost one.
public static ConsolidatedMessage ( this ex, string separator = null, bool innerFirst = true ) : string
ex this
separator string
innerFirst bool True to put innermost exception on top, false for outermost.
Résultat string

ConsolidatedStack() public static méthode

Returns all stack traces in the exception chain (main + inner exceptions), starting from the innermost one.
public static ConsolidatedStack ( this ex, string separator = null, bool innerFirst = true ) : string
ex this
separator string
innerFirst bool True to put innermost exception on top, false for outermost.
Résultat string

FullInfo() public static méthode

Returns string containing exception type, message and stack trace. No inner exception information included.
public static FullInfo ( this ex ) : string
ex this
Résultat string

ToSerializable() public static méthode

Returns Exception-like object that can serialized to XML, JSON, etc.
public static ToSerializable ( this ex ) : ExceptionDto
ex this
Résultat ExceptionDto

TypeAndMessage() public static méthode

Returns string with the information of exception type and message.
public static TypeAndMessage ( this ex ) : string
ex this
Résultat string