Esempio n. 1
0
 /// <summary>
 /// Register a listener of extension node changes.
 /// </summary>
 /// <param name="instanceType">
 /// Type defining the extension point
 /// </param>
 /// <param name="handler">
 /// A handler method.
 /// </param>
 /// <remarks>
 /// Hosts can call this method to be subscribed to an extension change
 /// event for a specific type extension point. 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.
 ///
 /// NOTE: The handler will be called for all nodes existing in the path at the moment of registration.
 /// </remarks>
 public static void AddExtensionNodeHandler(Type instanceType, ExtensionNodeEventHandler handler)
 {
     AddinEngine.CheckInitialized();
     AddinEngine.AddExtensionNodeHandler(instanceType, handler);
 }
Esempio n. 2
0
 /// <summary>
 /// Register a listener of extension node changes.
 /// </summary>
 /// <param name="path">
 /// Path of the node.
 /// </param>
 /// <param name="handler">
 /// A handler method.
 /// </param>
 /// <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.
 ///
 /// NOTE: The handler will be called for all nodes existing in the path at the moment of registration.
 /// </remarks>
 public static void AddExtensionNodeHandler(string path, ExtensionNodeEventHandler handler)
 {
     AddinEngine.CheckInitialized();
     AddinEngine.AddExtensionNodeHandler(path, handler);
 }