Free cookie consent management tool by TermsFeed Policy Generator

Changeset 4414


Ignore:
Timestamp:
09/16/10 14:49:34 (14 years ago)
Author:
cneumuel
Message:

Changes to PluginInfrastructure for Hive compatibility (#1191)

Location:
trunk/sources/HeuristicLab.PluginInfrastructure/3.3
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.PluginInfrastructure/3.3/Manager/PluginInfrastructureEventArgs.cs

    r4068 r4414  
    2424namespace HeuristicLab.PluginInfrastructure.Manager {
    2525  [Serializable]
    26   internal sealed class PluginInfrastructureEventArgs : EventArgs {
    27     internal object Entity { get; private set; }
    28     internal PluginInfrastructureEventArgs(object entity) {
     26  public sealed class PluginInfrastructureEventArgs : EventArgs {
     27    public object Entity { get; private set; }
     28    public PluginInfrastructureEventArgs(object entity) {
    2929      this.Entity = entity;
    3030    }
    3131
    3232    private static PluginInfrastructureEventArgs emptyArgs = new PluginInfrastructureEventArgs(string.Empty);
    33     internal new static PluginInfrastructureEventArgs Empty {
     33    public new static PluginInfrastructureEventArgs Empty {
    3434      get { return emptyArgs; }
    3535    }
  • trunk/sources/HeuristicLab.PluginInfrastructure/3.3/Manager/PluginManager.cs

    r4068 r4414  
    3131  /// Class to manage different plugins.
    3232  /// </summary>
    33   internal sealed class PluginManager : MarshalByRefObject {
    34     internal event EventHandler<PluginInfrastructureEventArgs> PluginLoaded;
    35     internal event EventHandler<PluginInfrastructureEventArgs> PluginUnloaded;
    36     internal event EventHandler<PluginInfrastructureEventArgs> Initializing;
    37     internal event EventHandler<PluginInfrastructureEventArgs> Initialized;
    38     internal event EventHandler<PluginInfrastructureEventArgs> ApplicationStarting;
    39     internal event EventHandler<PluginInfrastructureEventArgs> ApplicationStarted;
     33  public sealed class PluginManager : MarshalByRefObject {
     34    public event EventHandler<PluginInfrastructureEventArgs> PluginLoaded;
     35    public event EventHandler<PluginInfrastructureEventArgs> PluginUnloaded;
     36    public event EventHandler<PluginInfrastructureEventArgs> Initializing;
     37    public event EventHandler<PluginInfrastructureEventArgs> Initialized;
     38    public event EventHandler<PluginInfrastructureEventArgs> ApplicationStarting;
     39    public event EventHandler<PluginInfrastructureEventArgs> ApplicationStarted;
    4040
    4141    private string pluginDir;
     
    4545    /// Gets all installed plugins.
    4646    /// </summary>
    47     internal IEnumerable<PluginDescription> Plugins {
     47    public IEnumerable<PluginDescription> Plugins {
    4848      get { return plugins; }
    4949    }
     
    6060    private bool initialized;
    6161
    62     internal PluginManager(string pluginDir) {
     62    public PluginManager(string pluginDir) {
    6363      this.pluginDir = pluginDir;
    6464      plugins = new List<PluginDescription>();
     
    7070    /// Determines installed plugins and checks if all plugins are loadable.
    7171    /// </summary>
    72     internal void DiscoverAndCheckPlugins() {
     72    public void DiscoverAndCheckPlugins() {
    7373      OnInitializing(PluginInfrastructureEventArgs.Empty);
    7474      AppDomainSetup setup = AppDomain.CurrentDomain.SetupInformation;
  • trunk/sources/HeuristicLab.PluginInfrastructure/3.3/Sandboxing/SandboxManager.cs

    r4068 r4414  
    8787      DefaultApplicationManager applicationManager =
    8888        (DefaultApplicationManager)applicationDomain.CreateInstanceAndUnwrap(applicationManagerType.Assembly.FullName, applicationManagerType.FullName, true, BindingFlags.NonPublic | BindingFlags.Instance, null, null, null, null, null);
     89      PluginManager pm = new PluginManager(name);
     90      pm.DiscoverAndCheckPlugins();
    8991      ApplicationDescription[] apps = ApplicationManager.Manager.Applications.Cast<ApplicationDescription>().ToArray();
    9092      PluginDescription[] plugins = ApplicationManager.Manager.Plugins.Cast<PluginDescription>().ToArray();
Note: See TracChangeset for help on using the changeset viewer.