Interface IXMLCommandService
- All Known Implementing Classes:
XMLWorkspaceService
public interface IXMLCommandService
Service available to XML LS extensions to add/remove/execute commands via the
XML LS
- Author:
- Alex Boyko
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceCommand handler to register with the workspace service -
Method Summary
Modifier and TypeMethodDescriptiondefault voiddefault voidexecuteClientCommand(org.eclipse.lsp4j.ExecuteCommandParams command) Executes a command via the client.voidregisterCommand(String commandId, IXMLCommandService.IDelegateCommandHandler handler) Registers a command with the language servervoidunregisterCommand(String commandId) Unregisters the command from the language server
-
Method Details
-
registerCommand
Registers a command with the language server- Parameters:
commandId- unique id of the commandhandler- command handler function
-
unregisterCommand
Unregisters the command from the language server- Parameters:
commandId- unique id of the command to unregister
-
executeClientCommand
Executes a command via the client. The command can be registered by any language server- Parameters:
command- the LSP command- Returns:
- the result of the command
-
beginCommandsRegistration
default void beginCommandsRegistration() -
endCommandsRegistration
default void endCommandsRegistration()
-