mirror of
https://github.com/opensim/opensim.git
synced 2026-08-09 10:46:00 +08:00
Mantis#1591. Thank you graciously, Sempuki for a patch that:
Currently module loading is done ad-hoc. I propose creating a simple loader class that leverages Mono.Addins (and perhaps the new .NET addins when they become available in mono). Attached is a basic patch for review that compiles into HEAD, but doesn't yet replace any existing ad-hoc loaders.
This commit is contained in:
@@ -25,12 +25,24 @@
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
using System;
|
||||
|
||||
namespace OpenSim.Framework
|
||||
{
|
||||
/// <summary>
|
||||
/// Exception thrown if Initialise has been called, but failed.
|
||||
/// </summary>
|
||||
public class PluginNotInitialisedException : Exception
|
||||
{
|
||||
public PluginNotInitialisedException () : base() {}
|
||||
public PluginNotInitialisedException (string msg) : base(msg) {}
|
||||
public PluginNotInitialisedException (string msg, Exception e) : base(msg, e) {}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// This interface, describes a generic plugin
|
||||
/// </summary>
|
||||
public interface IPlugin
|
||||
public interface IPlugin : System.IDisposable
|
||||
{
|
||||
/// <summary>
|
||||
/// Returns the plugin version
|
||||
@@ -45,8 +57,8 @@ namespace OpenSim.Framework
|
||||
string Name { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Initialises the plugin (artificial constructor)
|
||||
/// Default-initialises the plugin
|
||||
/// </summary>
|
||||
void Initialise();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user