diff options
Diffstat (limited to 'OpenSim/Data/NHibernate/Types/LLUUIDType.cs')
-rw-r--r-- | OpenSim/Data/NHibernate/Types/LLUUIDType.cs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/OpenSim/Data/NHibernate/Types/LLUUIDType.cs b/OpenSim/Data/NHibernate/Types/LLUUIDType.cs index b8e5739..babc7fd 100644 --- a/OpenSim/Data/NHibernate/Types/LLUUIDType.cs +++ b/OpenSim/Data/NHibernate/Types/LLUUIDType.cs | |||
@@ -1,5 +1,6 @@ | |||
1 | using System; | 1 | using System; |
2 | using System.Data; | 2 | using System.Data; |
3 | using NHibernate; | ||
3 | using NHibernate.SqlTypes; | 4 | using NHibernate.SqlTypes; |
4 | using NHibernate.UserTypes; | 5 | using NHibernate.UserTypes; |
5 | using libsecondlife; | 6 | using libsecondlife; |
@@ -7,14 +8,14 @@ using libsecondlife; | |||
7 | namespace OpenSim.Data.NHibernate | 8 | namespace OpenSim.Data.NHibernate |
8 | { | 9 | { |
9 | [Serializable] | 10 | [Serializable] |
10 | public class LLUUIDString : IUserType | 11 | public class LLUUIDUserType: IUserType |
11 | { | 12 | { |
12 | public object Assemble(object cached, object owner) | 13 | public object Assemble(object cached, object owner) |
13 | { | 14 | { |
14 | return cached; | 15 | return cached; |
15 | } | 16 | } |
16 | 17 | ||
17 | bool IUserType.Equals(object uuid1, object uuid2) | 18 | public bool IUserType.Equals(object uuid1, object uuid2) |
18 | { | 19 | { |
19 | return uuid1.Equals(uuid2); | 20 | return uuid1.Equals(uuid2); |
20 | } | 21 | } |
@@ -55,9 +56,8 @@ namespace OpenSim.Data.NHibernate | |||
55 | 56 | ||
56 | public void NullSafeSet(System.Data.IDbCommand cmd, object obj, int index) | 57 | public void NullSafeSet(System.Data.IDbCommand cmd, object obj, int index) |
57 | { | 58 | { |
58 | LLUUID UUID = (LLUUID)obj; | 59 | LLUUID uuid = (LLUUID)obj; |
59 | ((IDataParameter)cmd.Parameters[index]).Value = UUID.ToString(); | 60 | ((IDataParameter)cmd.Parameters[index]).Value = uuid.ToString(); |
60 | System.Console.WriteLine("Setting UUID {0}", UUID.ToString()); | ||
61 | } | 61 | } |
62 | 62 | ||
63 | public object Replace(object original, object target, object owner) | 63 | public object Replace(object original, object target, object owner) |
@@ -72,7 +72,7 @@ namespace OpenSim.Data.NHibernate | |||
72 | 72 | ||
73 | public SqlType[] SqlTypes | 73 | public SqlType[] SqlTypes |
74 | { | 74 | { |
75 | get { return new SqlType [] { SqlTypeFactory.GetString(32) }; } | 75 | get { return new SqlType [] { NHibernateUtil.String.SqlType }; } |
76 | } | 76 | } |
77 | } | 77 | } |
78 | } | 78 | } |