- moved data plugin loading code from various places to

OpenSim/Data/DataPluginFactory.cs
- removed dependencies on a few executable assemblies in
  bin/OpenSim.Data.addin.xml
- trim trailing whitespace
This commit is contained in:
Mike Mazur
2009-02-03 05:20:44 +00:00
parent d3eae4073e
commit d259238c74
6 changed files with 185 additions and 74 deletions

View File

@@ -59,20 +59,18 @@ namespace OpenSim.Framework.Communications
}
/// <summary>
/// Adds a new inventory data plugin - plugins will be requested in the order they were loaded.
/// Adds a list of inventory data plugins, as described by `provider'
/// and `connect', to `m_plugins'.
/// </summary>
/// <param name="provider">The filename of the inventory server plugin DLL</param>
/// <param name="provider">
/// The filename of the inventory server plugin DLL.
/// </param>
/// <param name="connect">
/// The connection string for the storage backend.
/// </param>
public void AddPlugin(string provider, string connect)
{
PluginLoader<IInventoryDataPlugin> loader =
new PluginLoader<IInventoryDataPlugin> (new InventoryDataInitialiser(connect));
// loader will try to load all providers (MySQL, MSSQL, etc)
// unless it is constrainted to the correct "Provider" entry in the addin.xml
loader.Add ("/OpenSim/InventoryData", new PluginProviderFilter(provider));
loader.Load();
m_plugins.AddRange(loader.Plugins);
m_plugins.AddRange(DataPluginFactory.LoadInventoryDataPlugins(provider, connect));
}
#endregion

View File

@@ -74,21 +74,18 @@ namespace OpenSim.Framework.Communications
}
/// <summary>
/// Add a new user data plugin - plugins will be requested in the order they were added.
/// Adds a list of user data plugins, as described by `provider' and
/// `connect', to `_plugins'.
/// </summary>
/// <param name="provider">The filename to the user data plugin DLL</param>
/// <param name="connect"></param>
/// <param name="provider">
/// The filename of the inventory server plugin DLL.
/// </param>
/// <param name="connect">
/// The connection string for the storage backend.
/// </param>
public void AddPlugin(string provider, string connect)
{
PluginLoader<IUserDataPlugin> loader =
new PluginLoader<IUserDataPlugin>(new UserDataInitialiser(connect));
// loader will try to load all providers (MySQL, MSSQL, etc)
// unless it is constrainted to the correct "Provider" entry in the addin.xml
loader.Add("/OpenSim/UserData", new PluginProviderFilter(provider));
loader.Load();
_plugins.AddRange(loader.Plugins);
_plugins.AddRange(DataPluginFactory.LoadUserDataPlugins(provider, connect));
}
#region Get UserProfile