Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bind XSD, DTD with CodeLens #1049

Merged

Conversation

angelozerr
Copy link
Contributor

Bind XSD, DTD with CodeLens

See redhat-developer/vscode-xml#395

Signed-off-by: azerr azerr@redhat.com

@angelozerr
Copy link
Contributor Author

angelozerr commented Jun 4, 2021

@BoykoAlex pay attention this PR will break the API of command (IDelegateCommandHandler). Now we will have the shared settings in the parameter:

public interface IDelegateCommandHandler {

		/**
		 * Executes a command
		 * 
		 * @param params        command execution parameters
		 * @param sharedSettings the shared settings.
		 * @param cancelChecker check if cancel has been requested
		 * @return the result of the command
		 * @throws Exception the unhandled exception will be wrapped in
		 *                   <code>org.eclipse.lsp4j.jsonrpc.ResponseErrorException</code>
		 *                   and be wired back to the JSON-RPC protocol caller
		 */
		Object executeCommand(ExecuteCommandParams params, SharedSettings sharedSettings, CancelChecker cancelChecker) throws Exception;
	}

@angelozerr angelozerr force-pushed the associate-with-codelens branch 5 times, most recently from 769daea to d3f5f4c Compare June 9, 2021 15:55
@angelozerr angelozerr marked this pull request as ready for review June 9, 2021 15:59
@angelozerr angelozerr requested a review from datho7561 June 9, 2021 15:59
Copy link
Contributor

@datho7561 datho7561 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code looks pretty good and it works great!

I think we should add a file in docs/ that explains what the client needs to implement in order to support these CodeLens properly.

It would be nice if the code actions that add the XML to bind to the schema respected the formatting settings, but this could be handled in a different PR.

@angelozerr angelozerr force-pushed the associate-with-codelens branch 6 times, most recently from c271d41 to ae97315 Compare June 10, 2021 15:10
@angelozerr angelozerr force-pushed the associate-with-codelens branch from ae97315 to f9376d0 Compare June 10, 2021 16:25
See redhat-developer/vscode-xml#395

Signed-off-by: azerr <azerr@redhat.com>
@datho7561 datho7561 merged commit eb0121a into eclipse-lemminx:master Jun 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants