Class XMLValidationFileCommand
- java.lang.Object
-
- org.eclipse.lemminx.services.extensions.commands.AbstractDOMDocumentCommandHandler
-
- org.eclipse.lemminx.extensions.contentmodel.commands.XMLValidationFileCommand
-
- All Implemented Interfaces:
IXMLCommandService.IDelegateCommandHandler
public class XMLValidationFileCommand extends AbstractDOMDocumentCommandHandler
XML Command "xml.validation.current.file" to revalidate a give XML file which means:- remove the referenced grammar in the XML file from the Xerces grammar pool (used by the Xerces validation) and the content model documents cache (used by the XML completion/hover based on the grammar)
- trigger the validation for the given XML file
- Author:
- Angelo ZERR
-
-
Field Summary
Fields Modifier and Type Field Description static StringCOMMAND_ID
-
Constructor Summary
Constructors Constructor Description XMLValidationFileCommand(ContentModelManager contentModelManager, IXMLDocumentProvider documentProvider, IXMLValidationService validationService)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected ObjectexecuteCommand(DOMDocument document, org.eclipse.lsp4j.ExecuteCommandParams params, SharedSettings sharedSettings, org.eclipse.lsp4j.jsonrpc.CancelChecker cancelChecker)Executes a command-
Methods inherited from class org.eclipse.lemminx.services.extensions.commands.AbstractDOMDocumentCommandHandler
executeCommand
-
-
-
-
Field Detail
-
COMMAND_ID
public static final String COMMAND_ID
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
XMLValidationFileCommand
public XMLValidationFileCommand(ContentModelManager contentModelManager, IXMLDocumentProvider documentProvider, IXMLValidationService validationService)
-
-
Method Detail
-
executeCommand
protected Object executeCommand(DOMDocument document, org.eclipse.lsp4j.ExecuteCommandParams params, SharedSettings sharedSettings, org.eclipse.lsp4j.jsonrpc.CancelChecker cancelChecker) throws Exception
Description copied from class:AbstractDOMDocumentCommandHandlerExecutes a command- Specified by:
executeCommandin classAbstractDOMDocumentCommandHandler- Parameters:
document- the DOM document retrieve by theTextDocumentIdentifierargument.params- command execution parameterssharedSettings- the shared settingscancelChecker- check if cancel has been requested- Returns:
- the result of the command
- Throws:
Exception- the unhandled exception will be wrapped inorg.eclipse.lsp4j.jsonrpc.ResponseErrorExceptionand be wired back to the JSON-RPC protocol caller
-
-