Class TaskProviderRegistry

The TaskProviderRegistry is the common component for registration and provision of TaskProviders. Theia will collect all TaskContributions and invoke TaskContribution#registerProviders for each contribution.

Constructors

Properties

onWillProvideTaskProvider: Event<WillResolveTaskProvider> = ...

Emit when the registry provides a registered task provider. i.e. when the TaskProviderRegistry#getProvider function is called.

onWillProvideTaskProviderEmitter: Emitter<WillResolveTaskProvider> = ...
providers: Map<string, TaskProvider>

Methods

  • Initiates activation of a TaskProvider with the given type

    Parameters

    • type: string

      the task configuration type, '*' indicates, all providers.

    Returns Promise<void>

  • Retrieves the TaskProvider registered for the given type task configuration type. If there is already a TaskProvider registered for the specified type the registration will be overwritten with the new value.

    Parameters

    • type: string

      the task configuration type.

    Returns Promise<undefined | TaskProvider>

    a promise of the registered TaskProvider`` or undefined` if no provider is registered for the given type.

  • Registers the given TaskProvider for task configurations of the specified type

    Parameters

    • type: string

      the task configuration type for which the given provider should be registered.

    • provider: TaskProvider

      the TaskProvider that should be registered.

    • Optional handle: number

    Returns Disposable

    a Disposable that can be invoked to unregister the given resolver.