Interface IComponentCategoryManager

Namespace
ESRI.ArcGIS.esriSystem
Assembly
ESRI.Server.System.dll

Provides access to members that work with the component category manager.

[Guid("D9B58741-322D-11D2-A29A-080009B6F22B")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IComponentCategoryManager

Remarks

To get access to the IComponentCategoryManager interface create a new instance of a ComponentCategoryManager object.

Methods

Create(string, UID)

Creates a component category.

void Create(string Name, UID Category)

Parameters

Name string
Category UID

Setup(string, UID, UID, bool)

Installs or uninstalls the objects that match the object type into the given category.

void Setup(string pathname, UID objectType, UID Category, bool install)

Parameters

pathname string
objectType UID
Category UID
install bool

Remarks

The Setup method provides a means of registering more than one object stored in a DLL. Setup will QueryInterface (QI) each object in the DLL for the interface specified by ObjectType. If the QI succeeds, it will add that object to the component category specified by Category. 

For example, you can have a single DLL that contains many commands (objects that implement ICommand). To register all the commands in this DLL with the commands category for ArcMap, you can set ObjectType to be the UID of the ICommand interface and set Category to be the UID of the ESRI Mx Commands category. You don't need to know the UID for each command. By calling Setup once, all the command objects in the DLL will be registered in this category.

If you use the SetupObject method instead, you would have to call SetupObject many times; once for each command in the DLL.

SetupObject(string, UID, UID, bool)

Installs or uninstalls the given object into the given category.

void SetupObject(string pathname, UID obj, UID Category, bool install)

Parameters

pathname string
obj UID
Category UID
install bool

Remarks

The SetupObject method provides a means of registering a specific object stored in a DLL.

For example, you can have a single DLL that contains many commands (objects that implement ICommand). If you want to register only one of the commands in this DLL with the commands category for ArcMap, you can set obj to be the UID of your command and set Category to be the UID of the ESRI Mx Commands category. By calling SetObject with these settings, only that specific command will be registered. If you want to register all the commands in the DLL you can either call SetupObject a number of times (once for each command) or use the Setup method instead. Setup allows you to register many objects at the same time with a single call.