forked from nhibernate/nhibernate-core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathInner.cs
59 lines (50 loc) · 820 Bytes
/
Inner.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;
namespace NHibernate.DomainModel
{
/// <summary>
/// Summary description for Inner.
/// </summary>
[Serializable]
public class Inner
{
private InnerKey _id;
private string _dudu;
public InnerKey Id
{
get { return _id; }
set { _id = value; }
}
public string Dudu
{
get { return _dudu; }
set { _dudu = value; }
}
#region object members
public override bool Equals(object obj)
{
if (this == obj) return true;
Inner cidSuper = obj as Inner;
if (cidSuper == null) return false;
if (_id == null)
{
return cidSuper._id == null;
}
else
{
return _id.Equals(cidSuper._id);
}
}
public override int GetHashCode()
{
if (_id == null)
{
return 0;
}
else
{
return _id.GetHashCode();
}
}
#endregion
}
}