# Class DeactivatedDesignerAutocompleteProvider OptimaJet.Workflow.Core.Runtime.DeactivatedDesignerAutocompleteProvider Wraps an [IDesignerAutocompleteProvider](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/IDesignerAutocompleteProvider/) and allows it to be enabled or disabled dynamically. Namespace: [OptimaJet.Workflow.Core.Runtime](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/) ```csharp public class DeactivatedDesignerAutocompleteProvider : IDesignerAutocompleteProvider ``` ## Type Hierarchy - DeactivatedDesignerAutocompleteProvider Current type - Implemented interfaces - [IDesignerAutocompleteProvider](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/IDesignerAutocompleteProvider/) ## Constructors `public DeactivatedDesignerAutocompleteProvider(IDesignerAutocompleteProvider activatedDesignerAutocompleteProvider, Func getDisabled)` Initializes a new dynamically switchable wrapper around a designer autocomplete provider. ### Parameters | Name | Type | Description | | --- | --- | --- | | `activatedDesignerAutocompleteProvider` | `IDesignerAutocompleteProvider` | The provider to which calls are forwarded while `getDisabled` returns [false](https://learn.microsoft.com/dotnet/csharp/language-reference/builtin-types/bool). | | `getDisabled` | `Func` | The predicate evaluated for every method call. A result of [true](https://learn.microsoft.com/dotnet/csharp/language-reference/builtin-types/bool) selects [EmptyDesignerAutocompleteProvider.Value](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/EmptyDesignerAutocompleteProvider/); a result of [false](https://learn.microsoft.com/dotnet/csharp/language-reference/builtin-types/bool) selects `activatedDesignerAutocompleteProvider`. | ## Methods `public List GetAutocompleteSuggestions(SuggestionCategory category, string value, string schemeCode)` Gets a list of autocomplete suggestion strings for the specified category and context. ### Parameters | Name | Type | Description | | --- | --- | --- | | `category` | `SuggestionCategory` | The suggestion category that determines the editor context. | | `value` | `String` | The rule, action, or condition name used as context for suggestions. | | `schemeCode` | `String` | The scheme code for which suggestions are requested. | ### Returns | Type | Description | | --- | --- | | `List` | A list of suggestion strings to display, or [null](https://learn.microsoft.com/dotnet/csharp/language-reference/keywords/null) when no suggestions are available. | ## Remarks The wrapper evaluates the predicate supplied to the constructor on every method call. When the predicate returns [false](https://learn.microsoft.com/dotnet/csharp/language-reference/builtin-types/bool), the call is forwarded unchanged to the configured provider. When it returns [true](https://learn.microsoft.com/dotnet/csharp/language-reference/builtin-types/bool), the configured provider is bypassed and the call is delegated to [EmptyDesignerAutocompleteProvider.Value](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/EmptyDesignerAutocompleteProvider/). Disabling the wrapper does not modify the configured provider. While disabled, [DeactivatedDesignerAutocompleteProvider.GetAutocompleteSuggestions(SuggestionCategory, string, string)](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/DeactivatedDesignerAutocompleteProvider/) returns an empty list of autocomplete suggestions. [Previous CreateInstanceParams](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/CreateInstanceParams/) [Next DeactivatedDesignerParameterFormatProvider](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/DeactivatedDesignerParameterFormatProvider/)