aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/NHibernate/NHibernateInventoryData.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Data/NHibernate/NHibernateInventoryData.cs')
-rw-r--r--OpenSim/Data/NHibernate/NHibernateInventoryData.cs74
1 files changed, 37 insertions, 37 deletions
diff --git a/OpenSim/Data/NHibernate/NHibernateInventoryData.cs b/OpenSim/Data/NHibernate/NHibernateInventoryData.cs
index 0129800..7657ae5 100644
--- a/OpenSim/Data/NHibernate/NHibernateInventoryData.cs
+++ b/OpenSim/Data/NHibernate/NHibernateInventoryData.cs
@@ -42,6 +42,34 @@ namespace OpenSim.Data.NHibernate
42 42
43 public NHibernateManager manager; 43 public NHibernateManager manager;
44 44
45 /// <summary>
46 /// The plugin being loaded
47 /// </summary>
48 /// <returns>A string containing the plugin name</returns>
49 public string Name
50 {
51 get { return "NHibernate Inventory Data Interface"; }
52 }
53
54 /// <summary>
55 /// The plugins version
56 /// </summary>
57 /// <returns>A string containing the plugin version</returns>
58 public string Version
59 {
60 get
61 {
62 Module module = GetType().Module;
63 // string dllName = module.Assembly.ManifestModule.Name;
64 Version dllVersion = module.Assembly.GetName().Version;
65
66
67 return
68 string.Format("{0}.{1}.{2}.{3}", dllVersion.Major, dllVersion.Minor, dllVersion.Build,
69 dllVersion.Revision);
70 }
71 }
72
45 public void Initialise() 73 public void Initialise()
46 { 74 {
47 m_log.Info("[NHibernateInventoryData]: " + Name + " cannot be default-initialized!"); 75 m_log.Info("[NHibernateInventoryData]: " + Name + " cannot be default-initialized!");
@@ -57,6 +85,13 @@ namespace OpenSim.Data.NHibernate
57 manager = new NHibernateManager(connect, "InventoryStore"); 85 manager = new NHibernateManager(connect, "InventoryStore");
58 } 86 }
59 87
88 /// <summary>
89 /// Closes the interface
90 /// </summary>
91 public void Dispose()
92 {
93 }
94
60 /***************************************************************** 95 /*****************************************************************
61 * 96 *
62 * Basic CRUD operations on Data 97 * Basic CRUD operations on Data
@@ -92,7 +127,7 @@ namespace OpenSim.Data.NHibernate
92 { 127 {
93 if (!ExistsItem(item.ID)) 128 if (!ExistsItem(item.ID))
94 { 129 {
95 manager.Save(item); 130 manager.Insert(item);
96 } 131 }
97 else 132 else
98 { 133 {
@@ -161,7 +196,7 @@ namespace OpenSim.Data.NHibernate
161 { 196 {
162 if (!ExistsFolder(folder.ID)) 197 if (!ExistsFolder(folder.ID))
163 { 198 {
164 manager.Save(folder); 199 manager.Insert(folder);
165 } 200 }
166 else 201 else
167 { 202 {
@@ -220,41 +255,6 @@ namespace OpenSim.Data.NHibernate
220 // TODO: DataSet commit 255 // TODO: DataSet commit
221 } 256 }
222 257
223 /// <summary>
224 /// Closes the interface
225 /// </summary>
226 public void Dispose()
227 {
228 }
229
230 /// <summary>
231 /// The plugin being loaded
232 /// </summary>
233 /// <returns>A string containing the plugin name</returns>
234 public string Name
235 {
236 get { return "NHibernate Inventory Data Interface"; }
237 }
238
239 /// <summary>
240 /// The plugins version
241 /// </summary>
242 /// <returns>A string containing the plugin version</returns>
243 public string Version
244 {
245 get
246 {
247 Module module = GetType().Module;
248 // string dllName = module.Assembly.ManifestModule.Name;
249 Version dllVersion = module.Assembly.GetName().Version;
250
251
252 return
253 string.Format("{0}.{1}.{2}.{3}", dllVersion.Major, dllVersion.Minor, dllVersion.Build,
254 dllVersion.Revision);
255 }
256 }
257
258 // Move seems to be just update 258 // Move seems to be just update
259 259
260 public void moveInventoryFolder(InventoryFolderBase folder) 260 public void moveInventoryFolder(InventoryFolderBase folder)