From 2270b252656146d9d74b84665a7ace6c3139db30 Mon Sep 17 00:00:00 2001
From: Mike Mazur
Date: Thu, 31 Jul 2008 09:24:28 +0000
Subject: Thanks, sempuki, for a patch that moves all Grid Server's plugins to
PluginLoader. Fix issue 1871.
---
OpenSim/Data/MSSQL/MSSQLAssetData.cs | 2 +-
OpenSim/Data/MSSQL/MSSQLInventoryData.cs | 20 +++++++++++++-------
OpenSim/Data/MSSQL/MSSQLUserData.cs | 8 ++++++++
3 files changed, 22 insertions(+), 8 deletions(-)
(limited to 'OpenSim/Data/MSSQL')
diff --git a/OpenSim/Data/MSSQL/MSSQLAssetData.cs b/OpenSim/Data/MSSQL/MSSQLAssetData.cs
index e0e20df..443907f 100644
--- a/OpenSim/Data/MSSQL/MSSQLAssetData.cs
+++ b/OpenSim/Data/MSSQL/MSSQLAssetData.cs
@@ -45,7 +45,7 @@ namespace OpenSim.Data.MSSQL
private MSSQLManager database;
- #region IAssetProvider Members
+ #region IAssetProviderPlugin Members
///
/// Migration method
diff --git a/OpenSim/Data/MSSQL/MSSQLInventoryData.cs b/OpenSim/Data/MSSQL/MSSQLInventoryData.cs
index 4a8d6e9..9e60b16 100644
--- a/OpenSim/Data/MSSQL/MSSQLInventoryData.cs
+++ b/OpenSim/Data/MSSQL/MSSQLInventoryData.cs
@@ -39,7 +39,7 @@ namespace OpenSim.Data.MSSQL
///
/// A MSSQL interface for the inventory server
///
- public class MSSQLInventoryData : IInventoryData
+ public class MSSQLInventoryData : IInventoryDataPlugin
{
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
@@ -59,6 +59,12 @@ namespace OpenSim.Data.MSSQL
///
private MSSQLManager database;
+ public void Initialise()
+ {
+ m_log.Info("[MSSQLInventoryData]: " + Name + " cannot be default-initialized!");
+ throw new PluginNotInitialisedException (Name);
+ }
+
///
/// Loads and initialises the MSSQL inventory storage interface
///
@@ -134,15 +140,15 @@ namespace OpenSim.Data.MSSQL
/// The name of this DB provider
///
/// A string containing the name of the DB provider
- public string getName()
+ public string Name
{
- return "MSSQL Inventory Data Interface";
+ get { return "MSSQL Inventory Data Interface"; }
}
///
/// Closes this DB provider
///
- public void Close()
+ public void Dispose()
{
// Do nothing.
}
@@ -151,9 +157,9 @@ namespace OpenSim.Data.MSSQL
/// Returns the version of this DB provider
///
/// A string containing the DB provider
- public string getVersion()
+ public string Version
{
- return database.getVersion();
+ get { return database.getVersion(); }
}
///
@@ -681,7 +687,7 @@ namespace OpenSim.Data.MSSQL
folders.Add(f);
}
- // See IInventoryData
+ // See IInventoryDataPlugin
public List getFolderHierarchy(LLUUID parentID)
{
List folders = new List();
diff --git a/OpenSim/Data/MSSQL/MSSQLUserData.cs b/OpenSim/Data/MSSQL/MSSQLUserData.cs
index 0593c62..0703aab 100644
--- a/OpenSim/Data/MSSQL/MSSQLUserData.cs
+++ b/OpenSim/Data/MSSQL/MSSQLUserData.cs
@@ -52,6 +52,12 @@ namespace OpenSim.Data.MSSQL
private string m_usersTableName;
private string m_userFriendsTableName;
+ public override void Initialise()
+ {
+ m_log.Info("[MSSQLUserData]: " + Name + " cannot be default-initialized!");
+ throw new PluginNotInitialisedException (Name);
+ }
+
///
/// Loads and initialises the MSSQL storage plugin
///
@@ -93,6 +99,8 @@ namespace OpenSim.Data.MSSQL
TestTables();
}
+
+ public override void Dispose () {}
///
///
--
cgit v1.1