Skip to content

Commit 930e793

Browse files
committed
Debug 3
1 parent 9b366fd commit 930e793

2 files changed

Lines changed: 14 additions & 3 deletions

File tree

bundles/io.openliberty.tools.eclipse.ui/src/io/openliberty/tools/eclipse/debug/LibertySourcePathComputer.java

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,21 +97,32 @@ public ISourceContainer[] computeSourceContainers(ILaunchConfiguration configura
9797
// Get project dependencies that are open in the same workspace
9898
List<IProject> projectDependencies = getProjectDependencies(baseProject);
9999

100+
System.out.println("@ed: baseProject: " + baseProject + " has these dependencies: " + projectDependencies);
100101
// Create the classpath entry for the project dependencies found
101102
for (IProject dependencyProject : projectDependencies) {
102103

103104
if (dependencyProject.isNatureEnabled(JavaCore.NATURE_ID)) {
105+
System.out.println("Adding to unreolved: dependencyproject: " + dependencyProject);
106+
104107
IJavaProject dependencyJavaProject = JavaCore.create(dependencyProject);
105108
unresolvedClasspathEntries.add(JavaRuntime.newDefaultProjectClasspathEntry(dependencyJavaProject));
106109
}
107110
}
108111
}
109-
112+
//for (IRuntimeClasspathEntry entry :unresolvedClasspathEntries) {
113+
//System.out.println("@ed:UnreslovedClasspathEntries: project: " + entry.getJavaProject()+", location: "+ entry.getLocation());
114+
//}
110115
// Resolve and get final list of source containers
111116
IRuntimeClasspathEntry[] resolvedClasspathDependencies = JavaRuntime.resolveSourceLookupPath(
112117
unresolvedClasspathEntries.toArray(new IRuntimeClasspathEntry[unresolvedClasspathEntries.size()]),
113118
configuration);
114-
119+
for (int i = 0; i < resolvedClasspathDependencies.length; i++ ) {
120+
System.out.println("@ed:RESOLVEDClasspathEntries: project: " + resolvedClasspathDependencies[i].
121+
getClasspathEntry().getEntryKind()+", location: "+ resolvedClasspathDependencies[i].getLocation());
122+
}
123+
124+
125+
115126
ArrayList<ISourceContainer> containersList = new ArrayList<ISourceContainer>();
116127

117128
containersList.addAll(Arrays.asList(JavaRuntime.getSourceContainers(resolvedClasspathDependencies)));

bundles/io.openliberty.tools.eclipse.ui/src/io/openliberty/tools/eclipse/model/WorkspaceModel.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ private void buildMultiProjectModel(List<IProject> projectsToScan, boolean class
157157
// - Relative path: "../ear" (peer or other location)
158158
java.io.File parentDir = new java.io.File(projectLocation);
159159
java.io.File childDir = new java.io.File(parentDir, subprojectPath);
160-
String resolvedPath = childDir.getCanonicalPath();
160+
String resolvedPath = childDir.getAbsolutePath();
161161

162162
childProjectModel = projectsByLocation.get(resolvedPath);
163163
} catch (Exception e) {

0 commit comments

Comments
 (0)