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

Language Server Protocol Rename implementation #6615

Merged
merged 6 commits into from
Oct 9, 2017
Merged

Language Server Protocol Rename implementation #6615

merged 6 commits into from
Oct 9, 2017

Conversation

evidolob
Copy link
Contributor

@evidolob evidolob commented Oct 6, 2017

What does this PR do?

Add implementation of LSP Rename

What issues does this PR fix or reference?

#1806

Release Notes

Language Server Protocol Rename implementation

@evidolob evidolob self-assigned this Oct 6, 2017
@benoitf benoitf added status/code-review This issue has a pull request posted for it and is awaiting code review completion by the community. kind/enhancement A feature request - must adhere to the feature request template. labels Oct 6, 2017
@codenvy-ci
Copy link

if (!isStartWithProject(filePath)) {
filePath = prefixProject(filePath);
}
String fileContent =
Copy link
Contributor

Choose a reason for hiding this comment

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

Sorry to chime in late, but since we'll face a similar problem with the "references" for the jdt.ls, etc. I think this approach will not scale for large sets of changes. We should be thinking towards a UI where we fetch the concrete line changes ("snippets") when we need them.

String matchedLine = change.getTextEdit().getLineText();
int startOffset = change.getTextEdit().getInLineStart();
int endOffset = change.getTextEdit().getInLineEnd();
if (matchedLine != null /*&& matchInLine != null*/) {
Copy link
Contributor

Choose a reason for hiding this comment

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

comment code

}
spanElement.appendChild(textElement);

// presentation.setPresentableIcon(resources.searchMatch());
Copy link
Contributor

Choose a reason for hiding this comment

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

comment code

@@ -134,12 +150,15 @@ public void onFileOperation(final FileEvent event) {
break;
}
}
// onOpen(event.getEditor(), event.getFile(), dtoFactory, serviceClient, fileTypeRegister);
// onOpen(event.getEditor(), event.getFile(), dtoFactory, serviceClient,
Copy link
Contributor

Choose a reason for hiding this comment

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

comment code

Signed-off-by: Yevhen Vydolob <evidolob@codenvy.com>
@evidolob evidolob merged commit 59abab9 into master Oct 9, 2017
@evidolob evidolob deleted the ls-rename branch October 9, 2017 14:06
@benoitf benoitf removed the status/code-review This issue has a pull request posted for it and is awaiting code review completion by the community. label Oct 9, 2017
@benoitf benoitf added this to the 5.19.0 milestone Oct 9, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement A feature request - must adhere to the feature request template.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants