DesignerActionService.Contains(IComponent) 方法

定义

确定当前智能标记服务是否管理指定组件的操作列表。Determines whether the current smart tag service manages the action lists for the specified component.

public:
 bool Contains(System::ComponentModel::IComponent ^ comp);
public bool Contains (System.ComponentModel.IComponent comp);
member this.Contains : System.ComponentModel.IComponent -> bool
Public Function Contains (comp As IComponent) As Boolean

参数

comp
IComponent

要搜索的 IComponentThe IComponent to search for.

返回

如果组件由当前服务管理,则为 true;否则为 falsetrue if the component is managed by the current service; otherwise, false.

异常

compnullcomp is null.

注解

方法仅识别Add与方法关联的推送模型智能标记。 ContainsThe Contains method only recognizes push-model smart tags, which are associated to a component with the Add method.

尽管对设计时工具创建的并发DesignerActionService实例数没有结构限制, 但通常每个设计图面仅创建一项服务实例。Although there is no structural limitation on the number of concurrent DesignerActionService instances created by a design-time tool, typically only a single instance of the service is created per design surface.

适用于

另请参阅