示例#1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="LazyInitializationException"/> class.
 /// </summary>
 /// <param name="message">The message that describes the error. </param>
 /// <param name="innerException">
 /// The exception that is the cause of the current exception. If the innerException parameter
 /// is not a null reference, the current exception is raised in a catch block that handles
 /// the inner exception.
 /// </param>
 public LazyInitializationException(string message, Exception innerException) : base(message, innerException)
 {
     LoggerProvider.LoggerFor(typeof(LazyInitializationException)).Error(message, this);
 }
示例#2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="AssertionFailure"/> class.
 /// </summary>
 /// <param name="message">The message that describes the error. </param>
 /// <param name="innerException">
 /// The exception that is the cause of the current exception. If the innerException parameter
 /// is not a null reference, the current exception is raised in a catch block that handles
 /// the inner exception.
 /// </param>
 public AssertionFailure(string message, Exception innerException) : base(message, innerException)
 {
     LoggerProvider.LoggerFor(typeof(AssertionFailure)).Error(DefaultMessage, innerException);
 }
示例#3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="AssertionFailure"/> class.
 /// </summary>
 public AssertionFailure() : base(String.Empty)
 {
     LoggerProvider.LoggerFor(typeof(AssertionFailure)).Error(DefaultMessage);
 }
示例#4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="AssertionFailure"/> class.
 /// </summary>
 /// <param name="message">The message that describes the error. </param>
 public AssertionFailure(string message) : base(message)
 {
     LoggerProvider.LoggerFor(typeof(AssertionFailure)).Error(DefaultMessage, this);
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="NonUniqueResultException"/> class.
 /// </summary>
 /// <param name="resultCount">The number of items in the result.</param>
 public NonUniqueResultException(int resultCount)
     : base("query did not return a unique result: " + resultCount.ToString())
 {
     LoggerProvider.LoggerFor(typeof(NonUniqueResultException)).Error("query did not return a unique result: " +
                                                                      resultCount.ToString());
 }