aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/MySQL
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Data/MySQL/MySQLAssetData.cs2
-rw-r--r--OpenSim/Data/MySQL/MySQLGridData.cs2
-rw-r--r--OpenSim/Data/MySQL/MySQLInventoryData.cs20
-rw-r--r--OpenSim/Data/MySQL/MySQLUserData.cs23
4 files changed, 31 insertions, 16 deletions
diff --git a/OpenSim/Data/MySQL/MySQLAssetData.cs b/OpenSim/Data/MySQL/MySQLAssetData.cs
index 9284ba9..cec736a 100644
--- a/OpenSim/Data/MySQL/MySQLAssetData.cs
+++ b/OpenSim/Data/MySQL/MySQLAssetData.cs
@@ -112,7 +112,7 @@ namespace OpenSim.Data.MySQL
112 112
113 override public void Dispose() { } 113 override public void Dispose() { }
114 114
115 #region IAssetProvider Members 115 #region IAssetProviderPlugin Members
116 116
117 /// <summary> 117 /// <summary>
118 /// <list type="bullet"> 118 /// <list type="bullet">
diff --git a/OpenSim/Data/MySQL/MySQLGridData.cs b/OpenSim/Data/MySQL/MySQLGridData.cs
index fee457a..4cddbe5 100644
--- a/OpenSim/Data/MySQL/MySQLGridData.cs
+++ b/OpenSim/Data/MySQL/MySQLGridData.cs
@@ -51,7 +51,7 @@ namespace OpenSim.Data.MySQL
51 51
52 override public void Initialise() 52 override public void Initialise()
53 { 53 {
54 m_log.Info("[MySQLLogData]: " + Name + " cannot be default-initialized!"); 54 m_log.Info("[MySQLGridData]: " + Name + " cannot be default-initialized!");
55 throw new PluginNotInitialisedException (Name); 55 throw new PluginNotInitialisedException (Name);
56 } 56 }
57 57
diff --git a/OpenSim/Data/MySQL/MySQLInventoryData.cs b/OpenSim/Data/MySQL/MySQLInventoryData.cs
index 5bde40a..0fb49c1 100644
--- a/OpenSim/Data/MySQL/MySQLInventoryData.cs
+++ b/OpenSim/Data/MySQL/MySQLInventoryData.cs
@@ -38,7 +38,7 @@ namespace OpenSim.Data.MySQL
38 /// <summary> 38 /// <summary>
39 /// A MySQL interface for the inventory server 39 /// A MySQL interface for the inventory server
40 /// </summary> 40 /// </summary>
41 public class MySQLInventoryData : IInventoryData 41 public class MySQLInventoryData : IInventoryDataPlugin
42 { 42 {
43 private static readonly ILog m_log 43 private static readonly ILog m_log
44 = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); 44 = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
@@ -48,6 +48,12 @@ namespace OpenSim.Data.MySQL
48 /// </summary> 48 /// </summary>
49 private MySQLManager database; 49 private MySQLManager database;
50 50
51 public void Initialise()
52 {
53 m_log.Info("[MySQLInventoryData]: " + Name + " cannot be default-initialized!");
54 throw new PluginNotInitialisedException (Name);
55 }
56
51 /// <summary> 57 /// <summary>
52 /// <para>Initialises Inventory interface</para> 58 /// <para>Initialises Inventory interface</para>
53 /// <para> 59 /// <para>
@@ -183,16 +189,16 @@ namespace OpenSim.Data.MySQL
183 /// The name of this DB provider 189 /// The name of this DB provider
184 /// </summary> 190 /// </summary>
185 /// <returns>Name of DB provider</returns> 191 /// <returns>Name of DB provider</returns>
186 public string getName() 192 public string Name
187 { 193 {
188 return "MySQL Inventory Data Interface"; 194 get { return "MySQL Inventory Data Interface"; }
189 } 195 }
190 196
191 /// <summary> 197 /// <summary>
192 /// Closes this DB provider 198 /// Closes this DB provider
193 /// </summary> 199 /// </summary>
194 /// <remarks>do nothing</remarks> 200 /// <remarks>do nothing</remarks>
195 public void Close() 201 public void Dispose()
196 { 202 {
197 // Do nothing. 203 // Do nothing.
198 } 204 }
@@ -201,9 +207,9 @@ namespace OpenSim.Data.MySQL
201 /// Returns the version of this DB provider 207 /// Returns the version of this DB provider
202 /// </summary> 208 /// </summary>
203 /// <returns>A string containing the DB provider version</returns> 209 /// <returns>A string containing the DB provider version</returns>
204 public string getVersion() 210 public string Version
205 { 211 {
206 return database.getVersion(); 212 get { return database.getVersion(); }
207 } 213 }
208 214
209 /// <summary> 215 /// <summary>
@@ -692,7 +698,7 @@ namespace OpenSim.Data.MySQL
692 698
693 699
694 /// <summary> 700 /// <summary>
695 /// See IInventoryData 701 /// See IInventoryDataPlugin
696 /// </summary> 702 /// </summary>
697 /// <param name="parentID"></param> 703 /// <param name="parentID"></param>
698 /// <returns></returns> 704 /// <returns></returns>
diff --git a/OpenSim/Data/MySQL/MySQLUserData.cs b/OpenSim/Data/MySQL/MySQLUserData.cs
index 11d9c26..d8830de 100644
--- a/OpenSim/Data/MySQL/MySQLUserData.cs
+++ b/OpenSim/Data/MySQL/MySQLUserData.cs
@@ -55,6 +55,12 @@ namespace OpenSim.Data.MySQL
55 private string m_appearanceTableName = "avatarappearance"; 55 private string m_appearanceTableName = "avatarappearance";
56 private string m_connectString; 56 private string m_connectString;
57 57
58 public override void Initialise()
59 {
60 m_log.Info("[MySQLUserData]: " + Name + " cannot be default-initialized!");
61 throw new PluginNotInitialisedException (Name);
62 }
63
58 /// <summary> 64 /// <summary>
59 /// Initialise User Interface 65 /// Initialise User Interface
60 /// Loads and initialises the MySQL storage plugin 66 /// Loads and initialises the MySQL storage plugin
@@ -120,6 +126,9 @@ namespace OpenSim.Data.MySQL
120 m.Update(); 126 m.Update();
121 } 127 }
122 128
129 public override void Dispose () { }
130
131
123 #region Test and initialization code 132 #region Test and initialization code
124 133
125 /// <summary> 134 /// <summary>
@@ -252,7 +261,7 @@ namespace OpenSim.Data.MySQL
252 261
253 UserProfileData row = database.readUserRow(reader); 262 UserProfileData row = database.readUserRow(reader);
254 263
255 reader.Close(); 264 reader.Dispose();
256 result.Dispose(); 265 result.Dispose();
257 return row; 266 return row;
258 } 267 }
@@ -398,7 +407,7 @@ namespace OpenSim.Data.MySQL
398 407
399 Lfli.Add(fli); 408 Lfli.Add(fli);
400 } 409 }
401 reader.Close(); 410 reader.Dispose();
402 result.Dispose(); 411 result.Dispose();
403 } 412 }
404 } 413 }
@@ -450,7 +459,7 @@ namespace OpenSim.Data.MySQL
450 user.lastName = (string) reader["lastname"]; 459 user.lastName = (string) reader["lastname"];
451 returnlist.Add(user); 460 returnlist.Add(user);
452 } 461 }
453 reader.Close(); 462 reader.Dispose();
454 result.Dispose(); 463 result.Dispose();
455 } 464 }
456 } 465 }
@@ -484,7 +493,7 @@ namespace OpenSim.Data.MySQL
484 user.lastName = (string) reader["lastname"]; 493 user.lastName = (string) reader["lastname"];
485 returnlist.Add(user); 494 returnlist.Add(user);
486 } 495 }
487 reader.Close(); 496 reader.Dispose();
488 result.Dispose(); 497 result.Dispose();
489 } 498 }
490 } 499 }
@@ -517,7 +526,7 @@ namespace OpenSim.Data.MySQL
517 526
518 UserProfileData row = database.readUserRow(reader); 527 UserProfileData row = database.readUserRow(reader);
519 528
520 reader.Close(); 529 reader.Dispose();
521 result.Dispose(); 530 result.Dispose();
522 531
523 return row; 532 return row;
@@ -603,7 +612,7 @@ namespace OpenSim.Data.MySQL
603 612
604 UserAgentData row = database.readAgentRow(reader); 613 UserAgentData row = database.readAgentRow(reader);
605 614
606 reader.Close(); 615 reader.Dispose();
607 result.Dispose(); 616 result.Dispose();
608 617
609 return row; 618 return row;
@@ -725,7 +734,7 @@ namespace OpenSim.Data.MySQL
725 734
726 AvatarAppearance appearance = database.readAppearanceRow(reader); 735 AvatarAppearance appearance = database.readAppearanceRow(reader);
727 736
728 reader.Close(); 737 reader.Dispose();
729 result.Dispose(); 738 result.Dispose();
730 739
731 return appearance; 740 return appearance;