forked from nhibernate/nhibernate-core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathAdoExceptionContextInfo.cs
40 lines (34 loc) · 1.06 KB
/
AdoExceptionContextInfo.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
using System;
namespace NHibernate.Exceptions
{
/// <summary>
/// Collect data of an <see cref="ADOException"/> to be converted.
/// </summary>
[Serializable]
public class AdoExceptionContextInfo
{
// This class was introduced, in NH, to allow less intrusive possible extensions
// of information given to the ISQLExceptionConverter
// (extensions of a class instead succesive changes of a method)
/// <summary>
/// The <see cref="System.Data.Common.DbException"/> to be converted.
/// </summary>
public Exception SqlException { get; set; }
/// <summary>
/// An optional error message.
/// </summary>
public string Message { get; set; }
/// <summary>
/// The SQL that generate the exception
/// </summary>
public string Sql { get; set; }
/// <summary>
/// Optional EntityName where available in the original exception context.
/// </summary>
public string EntityName { get; set; }
/// <summary>
/// Optional EntityId where available in the original exception context.
/// </summary>
public object EntityId { get; set; }
}
}