Exception in finding Unresollved using plain java api?
Hello,
I am trying to find out all the Unresolved changes of the loaded workspace(Loaded with the help of load file)
Code:
ISharingManager sm = FileSystemCore.getSharingManager();
ILocalChangeManager lcm = sm.getLocalChangeManager();
String target = "HWRef";
PathLocation pathlocation = new PathLocation(projectConfiguration.getSandBoxLocation() );
ILocation sandBoxLocation = pathlocation.getCanonicalForm();
String[] targetPaths = target.split("/");
ISandbox sbox = sm.getSandbox(sandBoxLocation, false);
System.out.println(sbox.getRoot());
IShare[] sss= sbox.allShares(null);
IRelativeLocation relativeLocation = new RelativeLocation(Arrays.asList(targetPaths));
IShareable shareable = sbox.findShareable(relativeLocation, ResourceType.FOLDER);
lcm.refreshChanges(new ISandbox[] { sbox },RefreshType.TRAVERSE_ALL_WITH_RECOMPUTE_OF_KNOWN, null);
ILocalChange[] localChanges = lcm.getPendingChanges(new IShareable[] { shareable }, null);
In the localChanges it was showing as:
"org.eclipse.debug.core.DebugException: com.sun.jdi.ClassNotLoadedException: Type has not been loaded occurred while retrieving component type of array."
i have used another method of localChanges but got same message.
IShare[] shares= sbox.allShares(null);
ILocalChange[] localChanges1 = lcm.getPendingChanges(shares);
Thanks in advance!!
I am trying to find out all the Unresolved changes of the loaded workspace(Loaded with the help of load file)
Code:
ISharingManager sm = FileSystemCore.getSharingManager();
ILocalChangeManager lcm = sm.getLocalChangeManager();
String target = "HWRef";
PathLocation pathlocation = new PathLocation(projectConfiguration.getSandBoxLocation() );
ILocation sandBoxLocation = pathlocation.getCanonicalForm();
String[] targetPaths = target.split("/");
ISandbox sbox = sm.getSandbox(sandBoxLocation, false);
System.out.println(sbox.getRoot());
IShare[] sss= sbox.allShares(null);
IRelativeLocation relativeLocation = new RelativeLocation(Arrays.asList(targetPaths));
IShareable shareable = sbox.findShareable(relativeLocation, ResourceType.FOLDER);
lcm.refreshChanges(new ISandbox[] { sbox },RefreshType.TRAVERSE_ALL_WITH_RECOMPUTE_OF_KNOWN, null);
ILocalChange[] localChanges = lcm.getPendingChanges(new IShareable[] { shareable }, null);
In the localChanges it was showing as:
"org.eclipse.debug.core.DebugException: com.sun.jdi.ClassNotLoadedException: Type has not been loaded occurred while retrieving component type of array."
i have used another method of localChanges but got same message.
IShare[] shares= sbox.allShares(null);
ILocalChange[] localChanges1 = lcm.getPendingChanges(shares);
Thanks in advance!!
One answer
Consider to check the imports of your application for the classes that can't be found. Remove unused imports, make sure the classes are the ones that they should be and not one with a similar name but a different package. Find the package name and identify where these classes your come from and how they could be provided.
Usually you should only need a JDK and the Plain Java Client Libraries in your class path, otherwise you use SDK or other classes you probably shouldn't.
Usually you should only need a JDK and the Plain Java Client Libraries in your class path, otherwise you use SDK or other classes you probably shouldn't.
Comments
vikas v
Mar 17 '16, 6:39 a.m.