.NET Portable TypeCast  3.1.0.4
A, easy-to-use tested, generic, portable, runtime-extensible, arbitrary type converter library
Core.TypeCast.ConverterCollectionException Class Reference

The Exception-type which is raised exclusively by the Converter<T> Library More...

+ Collaboration diagram for Core.TypeCast.ConverterCollectionException:

Public Member Functions

 ConverterCollectionException (ConverterCollectionCause cause, string message=null)
 Initializes a new instance of the ConverterCollectionException class. Requires a ConverterCollectionCause and optional user message . More...
 
 ConverterCollectionException (ConverterCollectionCause cause, Exception innerException)
 Initializes a new instance of the ConverterCollectionException class. Requires a ConverterCollectionCause and innerException message More...
 
 ConverterCollectionException (ConverterCollectionCause cause, Exception innerException, string message)
 Initializes a new instance of the ConverterCollectionException class. Requires a ConverterCollectionCause an innerException and an exception message More...
 
virtual string GetMessage ()
 Override this method for custom formatting of the unformatted exception Exception.Message More...
 
override string ToString ()
 A string representation of the current exception. More...
 

Properties

ConverterCollectionCause Cause [get, set]
 Gets or sets the exception's ConverterCollectionCause, which is set through the parameterized exception constructor ConverterCollectionException(ConverterCollectionCause, string) More...
 
override string Message [get]
 Override this method for custom formatting of the unformatted exception Exception.Message More...
 

Detailed Description

The Exception-type which is raised exclusively by the Converter<T> Library

See also
ConverterCollectionCause

Definition at line 19 of file ConverterCollectionException.cs.

Constructor & Destructor Documentation

Core.TypeCast.ConverterCollectionException.ConverterCollectionException ( ConverterCollectionCause  cause,
string  message = null 
)

Initializes a new instance of the ConverterCollectionException class. Requires a ConverterCollectionCause and optional user message .

Parameters
causeThe coded reason for the Exception
messageThe message for the Exception. If left empty, the description of the cause will be used as exception message

Definition at line 30 of file ConverterCollectionException.cs.

31  : this(cause, null, message ?? cause.GetDescription())
32  {
33  }
Core.TypeCast.ConverterCollectionException.ConverterCollectionException ( ConverterCollectionCause  cause,
Exception  innerException 
)

Initializes a new instance of the ConverterCollectionException class. Requires a ConverterCollectionCause and innerException message

Parameters
causeThe coded reason for the Exception
innerExceptionThe wrapped exception within the ConverterCollectionException

Definition at line 41 of file ConverterCollectionException.cs.

42  : this(cause, innerException, cause.GetDescription())
43  {
44  }
Core.TypeCast.ConverterCollectionException.ConverterCollectionException ( ConverterCollectionCause  cause,
Exception  innerException,
string  message 
)

Initializes a new instance of the ConverterCollectionException class. Requires a ConverterCollectionCause an innerException and an exception message

Parameters
causeThe coded reason for the Exception of the value ConverterCollectionCause
innerExceptionThe wrapped exception within the ConverterCollectionException
messageThe message for the Exception

Definition at line 53 of file ConverterCollectionException.cs.

54  : base(message: message, innerException: innerException)
55  {
56  this.Cause = cause;
57  }
ConverterCollectionCause Cause
Gets or sets the exception&#39;s ConverterCollectionCause, which is set through the parameterized excepti...

Member Function Documentation

virtual string Core.TypeCast.ConverterCollectionException.GetMessage ( )
virtual

Override this method for custom formatting of the unformatted exception Exception.Message

Returns
The string containing the formatted exception message

Definition at line 71 of file ConverterCollectionException.cs.

72  {
73  return this.Cause.GetType().Name + " '" + this.Cause + "': " + this.Cause.GetDescription() + base.Message;
74  }
ConverterCollectionCause Cause
Gets or sets the exception&#39;s ConverterCollectionCause, which is set through the parameterized excepti...
override string Core.TypeCast.ConverterCollectionException.ToString ( )

A string representation of the current exception.

Returns
Returns a string representation of GetMessage concatenated to the underlying Exception.ToString method.

Definition at line 94 of file ConverterCollectionException.cs.

95  {
96  return this.GetMessage() + Environment.NewLine + base.ToString();
97  }
virtual string GetMessage()
Override this method for custom formatting of the unformatted exception Exception.Message

Property Documentation

ConverterCollectionCause Core.TypeCast.ConverterCollectionException.Cause
getset

Gets or sets the exception's ConverterCollectionCause, which is set through the parameterized exception constructor ConverterCollectionException(ConverterCollectionCause, string)

Returns
The enumeration value for the raised Exception of the type ConverterCollectionCause

To get a detailed description of the value, use EnumExtension.GetDescription(Enum,string)

Definition at line 65 of file ConverterCollectionException.cs.

override string Core.TypeCast.ConverterCollectionException.Message
get

Override this method for custom formatting of the unformatted exception Exception.Message

Returns
The string containing the formatted exception message

Definition at line 81 of file ConverterCollectionException.cs.


The documentation for this class was generated from the following file: