Ejemplo n.º 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);
 }
Ejemplo n.º 2
0
 public static void SetLoggersFactory(ILoggerFactory loggerFactory)
 {
     instance = new LoggerProvider(loggerFactory);
 }
Ejemplo n.º 3
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);
 }
Ejemplo n.º 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);
 }
Ejemplo n.º 5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="AssertionFailure"/> class.
 /// </summary>
 public AssertionFailure() : base(String.Empty)
 {
     LoggerProvider.LoggerFor(typeof(AssertionFailure)).Error(DefaultMessage);
 }
 /// <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());
 }