mirror of
https://github.com/sigmasternchen/xtext-core
synced 2025-03-15 08:18:55 +00:00
[lsp] ensure resources are initialized
This commit is contained in:
parent
d2bd0da853
commit
6761c499cc
2 changed files with 7 additions and 2 deletions
|
@ -115,7 +115,10 @@ class ProjectManager {
|
|||
}
|
||||
|
||||
def Resource getResource(URI uri) {
|
||||
resourceSet.getResource(uri, true)
|
||||
val resource = resourceSet.getResource(uri, true)
|
||||
// initialize
|
||||
resource.contents
|
||||
return resource
|
||||
}
|
||||
|
||||
def void reportProjectIssue(String message, String code, Severity severity) {
|
||||
|
|
|
@ -152,7 +152,9 @@ public class ProjectManager {
|
|||
}
|
||||
|
||||
public Resource getResource(final URI uri) {
|
||||
return this.resourceSet.getResource(uri, true);
|
||||
final Resource resource = this.resourceSet.getResource(uri, true);
|
||||
resource.getContents();
|
||||
return resource;
|
||||
}
|
||||
|
||||
public void reportProjectIssue(final String message, final String code, final Severity severity) {
|
||||
|
|
Loading…
Reference in a new issue