Package org.eclipse.lemminx.services.extensions

## Class XMLExtensionsRegistry

- java.lang.Object
- - org.eclipse.lemminx.services.extensions.XMLExtensionsRegistry

All Implemented Interfaces:
  `IComponentProvider`

Direct Known Subclasses:
  `XMLLanguageService`

    public class XMLExtensionsRegistry
    extends Object
    implements IComponentProvider

XML extensions registry.

### Constructor Summary

Constructors
`XMLExtensionsRegistry()`

### Method Summary

All Methods Instance Methods Concrete Methods
`void` `dispose()` Unregisters all registered extensions.
`void` `doSave​(ISaveContext saveContext)`
`List<ICodeActionParticipant>` `getCodeActionsParticipants()`
`Collection<ICodeLensParticipant>` `getCodeLensParticipants()`
`IXMLCommandService` `getCommandService()` Returns the LS command service
`Collection<ICompletionParticipant>` `getCompletionParticipants()`
`<T> T` `getComponent​(Class clazz)` Returns the component class instance from the given class and null otherwise.
`Collection<IDefinitionParticipant>` `getDefinitionParticipants()`
`Collection<IDiagnosticsParticipant>` `getDiagnosticsParticipants()`
`Collection<IDocumentColorParticipant>` `getDocumentColorParticipants()`
`List<IDocumentLifecycleParticipant>` `getDocumentLifecycleParticipants()` Return the registered document lifecycle participants.
`Collection<IDocumentLinkParticipant>` `getDocumentLinkParticipants()`
`IXMLDocumentProvider` `getDocumentProvider()` Returns the XML Document provider and null otherwise.
`Collection<IXMLExtension>` `getExtensions()`
`Collection<IFormatterParticipant>` `getFormatterParticipants()`
`Collection<IHighlightingParticipant>` `getHighlightingParticipants()`
`Collection<IHoverParticipant>` `getHoverParticipants()`
`List<ILinkedEditingRangesParticipant>` `getLinkedEditingRangesParticipants()`
`IXMLNotificationService` `getNotificationService()` Returns the notification service
`ProgressSupport` `getProgressSupport()`
`Collection<IReferenceParticipant>` `getReferenceParticipants()`
`Collection<IRenameParticipant>` `getRenameParticipants()`
`URIResolverExtensionManager` `getResolverExtensionManager()`
`Collection<ISymbolsProviderParticipant>` `getSymbolsProviderParticipants()`
`TelemetryManager` `getTelemetryManager()`
`Collection<ITypeDefinitionParticipant>` `getTypeDefinitionParticipants()`
`IXMLValidationService` `getValidationService()` Returns the XML document validation service
`Collection<IWorkspaceServiceParticipant>` `getWorkspaceServiceParticipants()` Return the registered workspace service participants.
`void` `initializeIfNeeded()`
`void` `initializeParams​(org.eclipse.lsp4j.InitializeParams params)`
`void` `registerCodeActionParticipant​(ICodeActionParticipant codeActionsParticipant)`
`void` `registerCodeLensParticipant​(ICodeLensParticipant codeLensParticipant)`
`void` `registerCompletionParticipant​(ICompletionParticipant completionParticipant)`
`void` `registerComponent​(Object component)`
`void` `registerDefinitionParticipant​(IDefinitionParticipant definitionParticipant)`
`void` `registerDiagnosticsParticipant​(IDiagnosticsParticipant diagnosticsParticipant)`
`void` `registerDocumentColorParticipant​(IDocumentColorParticipant documentColorParticipant)`
`void` `registerDocumentLifecycleParticipant​(IDocumentLifecycleParticipant documentLifecycleParticipant)` Register a new document lifecycle participant
`void` `registerDocumentLinkParticipant​(IDocumentLinkParticipant documentLinkParticipant)`
`void` `registerFormatterParticipant​(IFormatterParticipant formatterParticipant)`
`void` `registerHighlightingParticipant​(IHighlightingParticipant highlightingParticipant)`
`void` `registerHoverParticipant​(IHoverParticipant hoverParticipant)`
`void` `registerLinkedEditingRangesParticipants​(ILinkedEditingRangesParticipant linkedEditingRangesParticipant)`
`void` `registerReferenceParticipant​(IReferenceParticipant referenceParticipant)`
`void` `registerRenameParticipant​(IRenameParticipant renameParticipant)`
`void` `registerSymbolsProviderParticipant​(ISymbolsProviderParticipant symbolsProviderParticipant)`
`void` `registerTypeDefinitionParticipant​(ITypeDefinitionParticipant typeDefinitionParticipant)`
`void` `registerWorkspaceServiceParticipant​(IWorkspaceServiceParticipant workspaceServiceParticipant)` Register a new workspace service participant
`void` `setCommandService​(IXMLCommandService commandService)` Sets the LS command service
`void` `setDocumentProvider​(IXMLDocumentProvider documentProvider)` Set the XML Document provider
`void` `setNotificationService​(IXMLNotificationService notificationService)` Sets the notification service
`void` `setProgressSupport​(ProgressSupport progressSupport)`
`void` `setTelemetryManager​(TelemetryManager telemetryManager)`
`void` `setValidationService​(IXMLValidationService validationService)` Sets the XML document validation service
`void` `unregisterCodeActionParticipant​(ICodeActionParticipant codeActionsParticipant)`
`void` `unregisterCodeLensParticipant​(ICodeLensParticipant codeLensParticipant)`
`void` `unregisterCompletionParticipant​(ICompletionParticipant completionParticipant)`
`void` `unregisterDefinitionParticipant​(IDefinitionParticipant definitionParticipant)`
`void` `unregisterDiagnosticsParticipant​(IDiagnosticsParticipant diagnosticsParticipant)`
`void` `unregisterDocumentColorParticipant​(IDocumentColorParticipant documentColorParticipant)`
`void` `unregisterDocumentLifecycleParticipant​(IDocumentLifecycleParticipant documentLifecycleParticipant)` Unregister a new document lifecycle participant.
`void` `unregisterDocumentLinkParticipant​(IDocumentLinkParticipant documentLinkParticipant)`
`void` `unregisterFormatterParticipant​(IFormatterParticipant formatterParticipant)`
`void` `unregisterHighlightingParticipant​(IHighlightingParticipant highlightingParticipant)`
`void` `unregisterHoverParticipant​(IHoverParticipant hoverParticipant)`
`void` `unregisterLinkedEditingRangesParticipants​(ILinkedEditingRangesParticipant linkedEditingRangesParticipant)`
`void` `unregisterReferenceParticipant​(IReferenceParticipant referenceParticipant)`
`void` `unregisterRenameParticipant​(IRenameParticipant renameParticipant)`
`void` `unregisterSymbolsProviderParticipant​(ISymbolsProviderParticipant symbolsProviderParticipant)`
`void` `unregisterTypeDefinitionParticipant​(ITypeDefinitionParticipant typeDefinitionParticipant)`
`void` `unregisterWorkspaceServiceParticipant​(IWorkspaceServiceParticipant workspaceServiceParticipant)` Unregister a new workspace service participant.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### XMLExtensionsRegistry

    public XMLExtensionsRegistry()

### Method Detail

#### registerComponent

    public void registerComponent​(Object component)

#### getComponent

    public <T> T getComponent​(Class clazz)

Description copied from interface: `IComponentProvider`
Returns the component class instance from the given class and null otherwise.

Specified by:
  `getComponent` in interface `IComponentProvider`
Parameters:
  `clazz` - class of the component.
Returns:
  the component class instance from the given class and null otherwise.

#### initializeParams

    public void initializeParams​(org.eclipse.lsp4j.InitializeParams params)

#### doSave

    public void doSave​(ISaveContext saveContext)

#### getExtensions

    public Collection<IXMLExtension> getExtensions()

#### getCompletionParticipants

    public Collection<ICompletionParticipant> getCompletionParticipants()

#### getHoverParticipants

    public Collection<IHoverParticipant> getHoverParticipants()

#### getDiagnosticsParticipants

    public Collection<IDiagnosticsParticipant> getDiagnosticsParticipants()

#### getCodeActionsParticipants

    public List<ICodeActionParticipant> getCodeActionsParticipants()

#### getDocumentLinkParticipants

    public Collection<IDocumentLinkParticipant> getDocumentLinkParticipants()

#### getDocumentColorParticipants

    public Collection<IDocumentColorParticipant> getDocumentColorParticipants()

#### getDefinitionParticipants

    public Collection<IDefinitionParticipant> getDefinitionParticipants()

#### getTypeDefinitionParticipants

    public Collection<ITypeDefinitionParticipant> getTypeDefinitionParticipants()

#### getReferenceParticipants

    public Collection<IReferenceParticipant> getReferenceParticipants()

#### getCodeLensParticipants

    public Collection<ICodeLensParticipant> getCodeLensParticipants()

#### getHighlightingParticipants

    public Collection<IHighlightingParticipant> getHighlightingParticipants()

#### getRenameParticipants

    public Collection<IRenameParticipant> getRenameParticipants()

#### getLinkedEditingRangesParticipants

    public List<ILinkedEditingRangesParticipant> getLinkedEditingRangesParticipants()

#### getFormatterParticipants

    public Collection<IFormatterParticipant> getFormatterParticipants()

#### getSymbolsProviderParticipants

    public Collection<ISymbolsProviderParticipant> getSymbolsProviderParticipants()

#### getWorkspaceServiceParticipants

    public Collection<IWorkspaceServiceParticipant> getWorkspaceServiceParticipants()

Return the registered workspace service participants.

Returns:
  the registered workspace service participants.
Since:
  0.14.2

#### getDocumentLifecycleParticipants

    public List<IDocumentLifecycleParticipant> getDocumentLifecycleParticipants()

Return the registered document lifecycle participants.

Returns:
  the registered document lifecycle participants.
Since:
  0.18.0

#### initializeIfNeeded

    public void initializeIfNeeded()

#### dispose

    public void dispose()

Unregisters all registered extensions.

#### registerCompletionParticipant

    public void registerCompletionParticipant​(ICompletionParticipant completionParticipant)

#### unregisterCompletionParticipant

    public void unregisterCompletionParticipant​(ICompletionParticipant completionParticipant)

#### registerHoverParticipant

    public void registerHoverParticipant​(IHoverParticipant hoverParticipant)

#### unregisterHoverParticipant

    public void unregisterHoverParticipant​(IHoverParticipant hoverParticipant)

#### registerDiagnosticsParticipant

    public void registerDiagnosticsParticipant​(IDiagnosticsParticipant diagnosticsParticipant)

#### unregisterDiagnosticsParticipant

    public void unregisterDiagnosticsParticipant​(IDiagnosticsParticipant diagnosticsParticipant)

#### registerCodeActionParticipant

    public void registerCodeActionParticipant​(ICodeActionParticipant codeActionsParticipant)

#### unregisterCodeActionParticipant

    public void unregisterCodeActionParticipant​(ICodeActionParticipant codeActionsParticipant)

#### registerDocumentLinkParticipant

    public void registerDocumentLinkParticipant​(IDocumentLinkParticipant documentLinkParticipant)

#### unregisterDocumentLinkParticipant

    public void unregisterDocumentLinkParticipant​(IDocumentLinkParticipant documentLinkParticipant)

#### registerDocumentColorParticipant

    public void registerDocumentColorParticipant​(IDocumentColorParticipant documentColorParticipant)

#### unregisterDocumentColorParticipant

    public void unregisterDocumentColorParticipant​(IDocumentColorParticipant documentColorParticipant)

#### registerDefinitionParticipant

    public void registerDefinitionParticipant​(IDefinitionParticipant definitionParticipant)

#### unregisterDefinitionParticipant

    public void unregisterDefinitionParticipant​(IDefinitionParticipant definitionParticipant)

#### registerTypeDefinitionParticipant

    public void registerTypeDefinitionParticipant​(ITypeDefinitionParticipant typeDefinitionParticipant)

#### unregisterTypeDefinitionParticipant

    public void unregisterTypeDefinitionParticipant​(ITypeDefinitionParticipant typeDefinitionParticipant)

#### registerReferenceParticipant

    public void registerReferenceParticipant​(IReferenceParticipant referenceParticipant)

#### unregisterReferenceParticipant

    public void unregisterReferenceParticipant​(IReferenceParticipant referenceParticipant)

#### registerCodeLensParticipant

    public void registerCodeLensParticipant​(ICodeLensParticipant codeLensParticipant)

#### unregisterCodeLensParticipant

    public void unregisterCodeLensParticipant​(ICodeLensParticipant codeLensParticipant)

#### registerHighlightingParticipant

    public void registerHighlightingParticipant​(IHighlightingParticipant highlightingParticipant)

#### unregisterHighlightingParticipant

    public void unregisterHighlightingParticipant​(IHighlightingParticipant highlightingParticipant)

#### registerRenameParticipant

    public void registerRenameParticipant​(IRenameParticipant renameParticipant)

#### unregisterRenameParticipant

    public void unregisterRenameParticipant​(IRenameParticipant renameParticipant)

#### registerLinkedEditingRangesParticipants

    public void registerLinkedEditingRangesParticipants​(ILinkedEditingRangesParticipant linkedEditingRangesParticipant)

#### unregisterLinkedEditingRangesParticipants

    public void unregisterLinkedEditingRangesParticipants​(ILinkedEditingRangesParticipant linkedEditingRangesParticipant)

#### registerFormatterParticipant

    public void registerFormatterParticipant​(IFormatterParticipant formatterParticipant)

#### unregisterFormatterParticipant

    public void unregisterFormatterParticipant​(IFormatterParticipant formatterParticipant)

#### registerSymbolsProviderParticipant

    public void registerSymbolsProviderParticipant​(ISymbolsProviderParticipant symbolsProviderParticipant)

#### unregisterSymbolsProviderParticipant

    public void unregisterSymbolsProviderParticipant​(ISymbolsProviderParticipant symbolsProviderParticipant)

#### registerWorkspaceServiceParticipant

    public void registerWorkspaceServiceParticipant​(IWorkspaceServiceParticipant workspaceServiceParticipant)

Register a new workspace service participant

Parameters:
  `workspaceServiceParticipant` - the participant to register
Since:
  0.14.2

#### unregisterWorkspaceServiceParticipant

    public void unregisterWorkspaceServiceParticipant​(IWorkspaceServiceParticipant workspaceServiceParticipant)

Unregister a new workspace service participant.

Parameters:
  `workspaceServiceParticipant` - the participant to unregister
Since:
  0.14.2

#### registerDocumentLifecycleParticipant

    public void registerDocumentLifecycleParticipant​(IDocumentLifecycleParticipant documentLifecycleParticipant)

Register a new document lifecycle participant

Parameters:
  `documentLifecycleParticipant` - the participant to register
Since:
  0.18.0

#### unregisterDocumentLifecycleParticipant

    public void unregisterDocumentLifecycleParticipant​(IDocumentLifecycleParticipant documentLifecycleParticipant)

Unregister a new document lifecycle participant.

Parameters:
  `documentLifecycleParticipant` - the participant to unregister
Since:
  0.18.0

#### getDocumentProvider

    public IXMLDocumentProvider getDocumentProvider()

Returns the XML Document provider and null otherwise.

Returns:
  the XML Document provider and null otherwise.

#### setDocumentProvider

    public void setDocumentProvider​(IXMLDocumentProvider documentProvider)

Set the XML Document provider

Parameters:
  `documentProvider` - XML Document provider

#### getResolverExtensionManager

    public URIResolverExtensionManager getResolverExtensionManager()

#### getNotificationService

    public IXMLNotificationService getNotificationService()

Returns the notification service

Returns:
  the notification service

#### setNotificationService

    public void setNotificationService​(IXMLNotificationService notificationService)

Sets the notification service

Parameters:
  `notificationService` - the new notification service

#### getValidationService

    public IXMLValidationService getValidationService()

Returns the XML document validation service

Returns:
  the validation service

#### setValidationService

    public void setValidationService​(IXMLValidationService validationService)

Sets the XML document validation service

Parameters:
  `validationService` -

#### getCommandService

    public IXMLCommandService getCommandService()

Returns the LS command service

Returns:
  the command service

#### setCommandService

    public void setCommandService​(IXMLCommandService commandService)

Sets the LS command service

Parameters:
  `commandService` -

#### getTelemetryManager

    public TelemetryManager getTelemetryManager()

#### setTelemetryManager

    public void setTelemetryManager​(TelemetryManager telemetryManager)

#### setProgressSupport

    public void setProgressSupport​(ProgressSupport progressSupport)

#### getProgressSupport

    public ProgressSupport getProgressSupport()