forked from nhibernate/nhibernate-core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathObjectDeletedException.cs
59 lines (53 loc) · 1.85 KB
/
ObjectDeletedException.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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
using System;
using System.Runtime.Serialization;
namespace NHibernate
{
/// <summary>
/// Thrown when the user tries to pass a deleted object to the <c>ISession</c>.
/// </summary>
[Serializable]
public class ObjectDeletedException : UnresolvableObjectException
{
/// <summary>
/// Initializes a new instance of the <see cref="ObjectDeletedException"/> class.
/// </summary>
public ObjectDeletedException() : this( "User tried to pass a deleted object to the ISession.", null, null )
{
}
public ObjectDeletedException( string message, object identifier, System.Type clazz )
: base( message, identifier, clazz )
{
}
#region ISerializable Members
/// <summary>
/// Initializes a new instance of the <see cref="ObjectDeletedException"/> class
/// with serialized data.
/// </summary>
/// <param name="info">
/// The <see cref="SerializationInfo"/> that holds the serialized object
/// data about the exception being thrown.
/// </param>
/// <param name="context">
/// The <see cref="StreamingContext"/> that contains contextual information about the source or destination.
/// </param>
protected ObjectDeletedException( SerializationInfo info, StreamingContext context ) : base( info, context )
{
}
/// <summary>
/// Sets the serialization info for <see cref="ObjectDeletedException"/> after
/// getting the info from the base Exception.
/// </summary>
/// <param name="info">
/// The <see cref="SerializationInfo"/> that holds the serialized object
/// data about the exception being thrown.
/// </param>
/// <param name="context">
/// The <see cref="StreamingContext"/> that contains contextual information about the source or destination.
/// </param>
public override void GetObjectData(SerializationInfo info, StreamingContext context)
{
base.GetObjectData( info, context );
}
#endregion
}
}