<Type Name="AddinManager" FullName="Mono.Addins.AddinManager">
  <TypeSignature Language="C#" Value="public class AddinManager" />
  <AssemblyInfo>
    <AssemblyName>Mono.Addins</AssemblyName>
    <AssemblyVersion>1.0.0.0</AssemblyVersion>
  </AssemblyInfo>
  <Base>
    <BaseTypeName>System.Object</BaseTypeName>
  </Base>
  <Interfaces />
  <Members>
    <Member MemberName="CreateExtensionContext">
      <MemberSignature Language="C#" Value="public static Mono.Addins.ExtensionContext CreateExtensionContext ();" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>Mono.Addins.ExtensionContext</ReturnType>
      </ReturnValue>
      <Parameters />
      <Docs>
        <summary>Creates a new extension context.</summary>
        <returns>The new extension context.</returns>
        <remarks>Extension contexts can be used to query the extension tree using particular condition values. See <see cref="T:Mono.Addins.ExtensionContext" /> for a complete example.</remarks>
      </Docs>
    </Member>
    <Member MemberName="ExtensionChanged">
      <MemberSignature Language="C#" Value="public static event Mono.Addins.ExtensionEventHandler ExtensionChanged;" />
      <MemberType>Event</MemberType>
      <ReturnValue>
        <ReturnType>Mono.Addins.ExtensionEventHandler</ReturnType>
      </ReturnValue>
      <Docs>
        <summary>Extension change event.</summary>
        <remarks>This event is fired when any extension point in the add-in system changes. The event args object provides the path of the changed extension, although it does not provide information about what changed. Hosts subscribing to this event should get the new list of nodes using a query method such as AddinManager.GetExtensionNodes() and then update whatever needs to be updated.</remarks>
      </Docs>
    </Member>
    <Member MemberName="GetExtensionNode">
      <MemberSignature Language="C#" Value="public static Mono.Addins.ExtensionNode GetExtensionNode (string path);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>Mono.Addins.ExtensionNode</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="path" Type="System.String" />
      </Parameters>
      <Docs>
        <param name="path">Location of the node.</param>
        <summary>Returns the extension node in a path</summary>
        <returns>The node, or null if not found.</returns>
        <remarks>
          <para>This method returns the extension node located at the provided path. For example, given the following extension point:</para>
          <example>
            <code lang="XML">
	&lt;Extension path="/MonoDevelop/Workbench/MainMenu"&gt;
		&lt;ItemSet id="File" _label="_File"&gt;
			&lt;CommandItem id="NewFile" /&gt;
			&lt;CommandItem id="NewProject" /&gt;
		&lt;/ItemSet&gt;
	&lt;/Extension&gt;
	</code>
          </example>
          <para> The following calls are valid: </para>
          <example>
            <code lang="C#">
// The following call returns the root element of the extension point
ExtensionNode node = AddinManager.GetExtensionNode ("/MonoDevelop/Workbench/MainMenu");

// The following call returns an specific node of the extension point
ExtensionNode node = AddinManager.GetExtensionNode ("/MonoDevelop/Workbench/MainMenu/File");

// The following call returns a child of a node of the extension point
ExtensionNode node = AddinManager.GetExtensionNode ("/MonoDevelop/Workbench/MainMenu/File/NewProject");
</code>
          </example>
        </remarks>
      </Docs>
    </Member>
    <Member MemberName="GetExtensionObjects">
      <MemberSignature Language="C#" Value="public static object[] GetExtensionObjects (string path);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>System.Object[]</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="path" Type="System.String" />
      </Parameters>
      <Docs>
        <param name="path">An extension path.</param>
        <summary>Gets extension objects registered in a path.</summary>
        <returns>An array of objects registered in the path.</returns>
        <remarks>This method can only be used if all nodes in the provided extension path are of type <see cref="T:Mono.Addins.TypeExtensionNode" />. The returned objects
are created by calling <see cref="M:Mono.Addins.TypeExtensionNode.GetInstance()" />.</remarks>
      </Docs>
    </Member>
    <Member MemberName="GetExtensionObjects">
      <MemberSignature Language="C#" Value="public static object[] GetExtensionObjects (string path, bool reuseCachedInstance);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>System.Object[]</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="path" Type="System.String" />
        <Parameter Name="reuseCachedInstance" Type="System.Boolean" />
      </Parameters>
      <Docs>
        <param name="path">An extension path.</param>
        <param name="reuseCachedInstance">True if the method can reuse instances created in previous calls.</param>
        <summary>Gets extension objects registered in a path.</summary>
        <returns>An array of objects registered in the path.</returns>
        <remarks>This method can only be used if all nodes in the provided extension path are of type <see cref="T:Mono.Addins.TypeExtensionNode" />. The returned array is composed by all objects created by calling the <see cref="M:Mono.Addins.TypeExtensionNode.CreateInstance()" /> method for each node (or <see cref="M:Mono.Addins.TypeExtensionNode.GetInstance()" /> if reuseCachedInstance is set to true).</remarks>
      </Docs>
    </Member>
    <Member MemberName="GetExtensionObjects">
      <MemberSignature Language="C#" Value="public static object[] GetExtensionObjects (string path, Type arrayElementType);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>System.Object[]</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="path" Type="System.String" />
        <Parameter Name="arrayElementType" Type="System.Type" />
      </Parameters>
      <Docs>
        <param name="path">An extension path.</param>
        <param name="arrayElementType">Type of the return array elements.</param>
        <summary>Gets extension objects registered in a path.</summary>
        <returns>An array of objects registered in the path.</returns>
        <remarks>This method can only be used if all nodes in the provided extension path are of type <see cref="T:Mono.Addins.TypeExtensionNode" />. The returned objects
are created by calling <see cref="M:Mono.Addins.TypeExtensionNode.GetInstance(System.Type)" />.

<para>
A <see cref="T:System.InvalidOperationException" /> exception is thrown if one of the found objects is not a subclass of the provided type.
</para></remarks>
      </Docs>
    </Member>
    <Member MemberName="GetExtensionObjects">
      <MemberSignature Language="C#" Value="public static object[] GetExtensionObjects (string path, Type arrayElementType, bool reuseCachedInstance);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>System.Object[]</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="path" Type="System.String" />
        <Parameter Name="arrayElementType" Type="System.Type" />
        <Parameter Name="reuseCachedInstance" Type="System.Boolean" />
      </Parameters>
      <Docs>
        <param name="path">An extension path.</param>
        <param name="arrayElementType">Type of the return array elements.</param>
        <param name="reuseCachedInstance">True if the method can reuse instances created in previous calls.</param>
        <summary>Gets extension objects registered in a path.</summary>
        <returns>An array of objects registered in the path.</returns>
        <remarks>This method can only be used if all nodes in the provided extension path are of type <see cref="T:Mono.Addins.TypeExtensionNode" />. The returned array is composed by all objects created by calling the <see cref="M:Mono.Addins.TypeExtensionNode.CreateInstance(System.Type)" /> method for each node (or <see cref="M:Mono.Addins.TypeExtensionNode.GetInstance(System.Type)" /> if reuseCachedInstance is set to true).

<para>
A <see cref="T:System.InvalidOperationException" /> exception is thrown if one of the found objects is not a subclass of the provided type.
</para></remarks>
      </Docs>
    </Member>
    <Member MemberName="GetExtensionObjects">
      <MemberSignature Language="C#" Value="public static object[] GetExtensionObjects (Type instanceType);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>System.Object[]</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="instanceType" Type="System.Type" />
      </Parameters>
      <Docs>
        <param name="instanceType">Type for which to query extension objects.</param>
        <summary>Gets extension objects registered in an extension point.</summary>
        <returns>An array of objects registered in the extension point.</returns>
        <remarks>
          <para>This method can be used to query the extension point of a type which does not have a path. For example:</para>
          <example>
            <code lang="C#">
[TypeExtensionPoint]
public interface ICommand
{
	void Run ();
}
  </code>
          </example>
          <para>The previous interface declares an extension point which will accept types that implement ICommand interface. Since the extension path is not provided in this declaration, the host has to use the GetExtensionObject method to get the registered object. For example:
</para>
          <example>
            <code lang="C#">
foreach (ICommand cmd in AddinManager.GetExtensionObjects (typeof(ICommand)))
	cmd.Run ();
  </code>
          </example>
          <para>The returned array is composed by all objects created by calling the <see cref="M:Mono.Addins.TypeExtensionNode.GetInstance(System.Type)" /> method for each node.</para>
        </remarks>
      </Docs>
    </Member>
    <Member MemberName="GetExtensionObjects">
      <MemberSignature Language="C#" Value="public static object[] GetExtensionObjects (Type instanceType, bool reuseCachedInstance);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>System.Object[]</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="instanceType" Type="System.Type" />
        <Parameter Name="reuseCachedInstance" Type="System.Boolean" />
      </Parameters>
      <Docs>
        <param name="instanceType">Type for which to query extension objects.</param>
        <param name="reuseCachedInstance">True if the method can reuse instances created in previous calls.</param>
        <summary>Gets extension objects registered in a path.</summary>
        <returns>An array of objects registered in the extension point.</returns>
        <remarks>
          <para>This method can be used to query the extension point of a type which does not have a path. For example:</para>
          <example>
            <code lang="C#">
[TypeExtensionPoint]
public interface ICommand
{
	void Run ();
}
  </code>
          </example>
          <para>The previous interface declares an extension point which will accept types that implement ICommand interface. Since the extension path is not provided in this declaration, the host has to use the GetExtensionObject method to get the registered object. For example:
</para>
          <example>
            <code lang="C#">
foreach (ICommand cmd in AddinManager.GetExtensionObjects (typeof(ICommand)))
	cmd.Run ();
  </code>
          </example>
          <para>The returned array is composed by all objects created by calling the <see cref="M:Mono.Addins.TypeExtensionNode.CreateInstance(System.Type)" /> method for each node (or <see cref="M:Mono.Addins.TypeExtensionNode.GetInstance(System.Type)" /> if reuseCachedInstance is set to true).</para>
        </remarks>
      </Docs>
    </Member>
    <Member MemberName="GetExtensionNodes">
      <MemberSignature Language="C#" Value="public static Mono.Addins.ExtensionNodeList GetExtensionNodes (string path);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>Mono.Addins.ExtensionNodeList</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="path" Type="System.String" />
      </Parameters>
      <Docs>
        <param name="path">An extension path.</param>
        <summary>Gets extension nodes registered in a path.</summary>
        <returns>All nodes registered in the provided path.</returns>
        <remarks>
          <para>This method returns all nodes registered under the provided path. For example, given the following extension point:</para>
          <example>
            <code lang="XML">
	&lt;Extension path="/MonoDevelop/Workbench/MainMenu"&gt;
		&lt;ItemSet id="File" _label="_File"&gt;
			&lt;CommandItem id="NewFile" /&gt;
			&lt;CommandItem id="NewProject" /&gt;
		&lt;/ItemSet&gt;
		&lt;ItemSet id="Edit" _label="_Edit"/&gt;
		&lt;ItemSet id="View" _label="_View"/&gt;
	&lt;/Extension&gt;
	</code>
          </example>
          <para> The following calls are valid: </para>
          <example>
            <code lang="C#">
// The following call prints 'File', 'Edit' and 'View'
ExtensionNodeList nodes = AddinManager.GetExtensionNodes ("/MonoDevelop/Workbench/MainMenu");
foreach (ExtensionNode node in nodes)
	Console.WriteLine (node.Id);

// The following call prints 'NewFile' and 'NewProject'
nodes = AddinManager.GetExtensionNodes ("/MonoDevelop/Workbench/MainMenu/File");
foreach (ExtensionNode node in nodes)
	Console.WriteLine (node.Id);
</code>
          </example>
        </remarks>
      </Docs>
    </Member>
    <Member MemberName="GetExtensionNodes">
      <MemberSignature Language="C#" Value="public static Mono.Addins.ExtensionNodeList GetExtensionNodes (string path, Type type);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>Mono.Addins.ExtensionNodeList</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="path" Type="System.String" />
        <Parameter Name="type" Type="System.Type" />
      </Parameters>
      <Docs>
        <param name="path">An extension path.</param>
        <param name="type">Expected node type.</param>
        <summary>Gets extension nodes registered in a path.</summary>
        <returns>All nodes registered in the provided path.</returns>
        <remarks>This method returns all nodes registered under the provided path. It will throw a <see cref="T:System.InvalidOperationException" /> if the type of one of the registered nodes is not assignable to the provided type.</remarks>
      </Docs>
    </Member>
    <Member MemberName="Initialize">
      <MemberSignature Language="C#" Value="public static void Initialize ();" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>System.Void</ReturnType>
      </ReturnValue>
      <Parameters />
      <Docs>
        <summary>Initializes the add-in engine.</summary>
        <remarks>The add-in engine needs to be initialized before doing any add-in operation. When initialized with this method, it will look for add-in in the global add-in registry.</remarks>
      </Docs>
    </Member>
    <Member MemberName="Initialize">
      <MemberSignature Language="C#" Value="public static void Initialize (string configDir);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>System.Void</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="configDir" Type="System.String" />
      </Parameters>
      <Docs>
        <param name="configDir">Location of the add-in registry.</param>
        <summary>Initializes the add-in engine.</summary>
        <remarks>The add-in engine needs to be initialized before doing any add-in operation. When initialized with this method, it will look for add-in in the add-in registry located in the specified path.</remarks>
      </Docs>
    </Member>
    <Member MemberName="IsAddinLoaded">
      <MemberSignature Language="C#" Value="public static bool IsAddinLoaded (string id);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>System.Boolean</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="id" Type="System.String" />
      </Parameters>
      <Docs>
        <param name="id">Full identifier of the add-in.</param>
        <summary>Checks if an add-in has been loaded.</summary>
        <returns>'true' if the add-in is loaded.</returns>
        <remarks>Checks if the specified add-in has been loaded in memory.</remarks>
      </Docs>
    </Member>
    <Member MemberName="Shutdown">
      <MemberSignature Language="C#" Value="public static void Shutdown ();" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>System.Void</ReturnType>
      </ReturnValue>
      <Parameters />
      <Docs>
        <summary>Finalizes an add-in engine session.</summary>
        <remarks>Finalizes the add-in engine.</remarks>
      </Docs>
    </Member>
    <Member MemberName="AddExtensionNodeHandler">
      <MemberSignature Language="C#" Value="public static void AddExtensionNodeHandler (string path, Mono.Addins.ExtensionNodeEventHandler handler);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>System.Void</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="path" Type="System.String" />
        <Parameter Name="handler" Type="Mono.Addins.ExtensionNodeEventHandler" />
      </Parameters>
      <Docs>
        <param name="path">Path of the node.</param>
        <param name="handler">A handler method.</param>
        <summary>Register a listener of extension node changes.</summary>
        <remarks>Hosts can call this method to be subscribed to an extension change event for a specific path. The event will be fired once for every individual node change. The event arguments include the change type (Add or Remove) and the extension node added or removed.

<block subset="none" type="note"><para>
The handler will be called for all nodes existing in the path at the moment of registration.
  </para></block></remarks>
      </Docs>
    </Member>
    <Member MemberName="RemoveExtensionNodeHandler">
      <MemberSignature Language="C#" Value="public static void RemoveExtensionNodeHandler (string path, Mono.Addins.ExtensionNodeEventHandler handler);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>System.Void</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="path" Type="System.String" />
        <Parameter Name="handler" Type="Mono.Addins.ExtensionNodeEventHandler" />
      </Parameters>
      <Docs>
        <param name="path">Path of the node.</param>
        <param name="handler">A handler method.</param>
        <summary>Unregister a listener of extension node changes.</summary>
        <remarks>This method unregisters a delegate from the node change event of a path.</remarks>
      </Docs>
    </Member>
    <Member MemberName="AddinLoaded">
      <MemberSignature Language="C#" Value="public static event Mono.Addins.AddinEventHandler AddinLoaded;" />
      <MemberType>Event</MemberType>
      <ReturnValue>
        <ReturnType>Mono.Addins.AddinEventHandler</ReturnType>
      </ReturnValue>
      <Docs>
        <summary>Add-in loaded event.</summary>
        <remarks>Fired after loading an add-in in memory.</remarks>
      </Docs>
    </Member>
    <Member MemberName="AddinLoadError">
      <MemberSignature Language="C#" Value="public static event Mono.Addins.AddinErrorEventHandler AddinLoadError;" />
      <MemberType>Event</MemberType>
      <ReturnValue>
        <ReturnType>Mono.Addins.AddinErrorEventHandler</ReturnType>
      </ReturnValue>
      <Docs>
        <summary>Add-in loading error event.</summary>
        <remarks>This event is fired when there is an error when loading the extension of an add-in, or any other kind of error that may happen when querying extension points.</remarks>
      </Docs>
    </Member>
    <Member MemberName="AddinUnloaded">
      <MemberSignature Language="C#" Value="public static event Mono.Addins.AddinEventHandler AddinUnloaded;" />
      <MemberType>Event</MemberType>
      <ReturnValue>
        <ReturnType>Mono.Addins.AddinEventHandler</ReturnType>
      </ReturnValue>
      <Docs>
        <summary>Add-in unload event.</summary>
        <remarks>Fired when an add-in is unloaded from memory. It may happen an add-in is disabled or uninstalled.</remarks>
      </Docs>
    </Member>
    <Member MemberName="Registry">
      <MemberSignature Language="C#" Value="public static Mono.Addins.AddinRegistry Registry { get; };" />
      <MemberType>Property</MemberType>
      <ReturnValue>
        <ReturnType>Mono.Addins.AddinRegistry</ReturnType>
      </ReturnValue>
      <Docs>
        <summary>Returns the add-in registry being currently used by the add-in engine.</summary>
        <value>An add-in registry.</value>
        <remarks>Returns the add-in registry being currently used by the add-in engine.</remarks>
      </Docs>
    </Member>
    <Member MemberName="IsInitialized">
      <MemberSignature Language="C#" Value="public static bool IsInitialized { get; };" />
      <MemberType>Property</MemberType>
      <ReturnValue>
        <ReturnType>System.Boolean</ReturnType>
      </ReturnValue>
      <Docs>
        <summary>Gets whether the add-in engine has been initialized.</summary>
        <value>'true' if the add-in engine has been initialized.</value>
        <remarks />
      </Docs>
    </Member>
    <Member MemberName="LoadAddin">
      <MemberSignature Language="C#" Value="public static void LoadAddin (Mono.Addins.IProgressStatus statusMonitor, string id);" />
      <MemberType>Method</MemberType>
      <ReturnValue>
        <ReturnType>System.Void</ReturnType>
      </ReturnValue>
      <Parameters>
        <Parameter Name="statusMonitor" Type="Mono.Addins.IProgressStatus" />
        <Parameter Name="id" Type="System.String" />
      </Parameters>
      <Docs>
        <param name="statusMonitor">Status monitor to keep track of the loading process.</param>
        <param name="id">Full identifier of the add-in to load.</param>
        <summary>Loads an add-in.</summary>
        <remarks>Loads all assemblies that belong to an add-in in memory. All add-ins on which the specified add-in depends will also be loaded. Notice that in general add-ins don't need to be explicitely loaded using this method, since the add-in engine will load them on demand.</remarks>
      </Docs>
    </Member>
  </Members>
  <Docs>
    <summary>Provides access to add-in management operations.</summary>
    <remarks>To be added.</remarks>
  </Docs>
</Type>