PT #164971098: Fix Inro URL constants. Properly create Location instance
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 Pivotal, Inc.
|
||||
* Copyright (c) 2019 Pivotal, Inc.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
@@ -21,7 +21,13 @@ public class EclipseJavaElementLocationProvider implements JavaElementLocationPr
|
||||
@Override
|
||||
public Location findLocation(IJavaProject project, IMember member) {
|
||||
URI uri = EclipseSourceLinks.eclipseIntroUri(project, member);
|
||||
return uri == null ? null : new Location(uri.toString(), null);
|
||||
if (uri == null) {
|
||||
return null;
|
||||
} else {
|
||||
Location location = new Location();
|
||||
location.setUri(uri.toString());
|
||||
return location;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -31,7 +31,7 @@ import org.springframework.ide.vscode.commons.languageserver.java.JavaProjectFin
|
||||
*/
|
||||
public class EclipseSourceLinks implements SourceLinks {
|
||||
|
||||
private static final String URL_PREFIX = "https://org.eclipse.ui.intro/execute?command=";
|
||||
private static final String URL_PREFIX = "http://org.eclipse.ui.intro/execute?command=";
|
||||
private static final String EQUALS = "=";
|
||||
private static final String PARAMETERS_SEPARATOR = ",";
|
||||
private static final String PARAMETERS_START = "(";
|
||||
|
||||
Reference in New Issue
Block a user