Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrian Vosburgh2012-11-06 13:44:33 -0500
committerBrian Vosburgh2012-11-06 13:45:12 -0500
commit49a50606b1c3b748e012127a7802e9fc9e96e0f5 (patch)
tree52f60f9d81a9bf1d1b6b050b01406ea129344808
parent2c6ddfd1cdc27b9094ecd97d194519cc72ec69bc (diff)
downloadwebtools.dali-49a50606b1c3b748e012127a7802e9fc9e96e0f5.tar.gz
webtools.dali-49a50606b1c3b748e012127a7802e9fc9e96e0f5.tar.xz
webtools.dali-49a50606b1c3b748e012127a7802e9fc9e96e0f5.zip
[392584] fix BackingStoreException during JAXB project creation - it's
possible this is a Faceted Project bug...
-rw-r--r--jaxb/plugins/org.eclipse.jpt.jaxb.core/src/org/eclipse/jpt/jaxb/core/JaxbPreferences.java31
1 files changed, 4 insertions, 27 deletions
diff --git a/jaxb/plugins/org.eclipse.jpt.jaxb.core/src/org/eclipse/jpt/jaxb/core/JaxbPreferences.java b/jaxb/plugins/org.eclipse.jpt.jaxb.core/src/org/eclipse/jpt/jaxb/core/JaxbPreferences.java
index 74fa591eb3..e9e18c4447 100644
--- a/jaxb/plugins/org.eclipse.jpt.jaxb.core/src/org/eclipse/jpt/jaxb/core/JaxbPreferences.java
+++ b/jaxb/plugins/org.eclipse.jpt.jaxb.core/src/org/eclipse/jpt/jaxb/core/JaxbPreferences.java
@@ -14,14 +14,8 @@ import java.util.Collections;
import java.util.List;
import org.eclipse.core.resources.IProject;
import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jpt.common.core.internal.JptCommonCoreMessages;
import org.eclipse.jpt.common.utility.internal.StringTools;
import org.eclipse.jpt.jaxb.core.internal.plugin.JptJaxbCorePlugin;
-import org.eclipse.osgi.util.NLS;
import org.eclipse.wst.common.project.facet.core.IFacetedProject;
import org.eclipse.wst.common.project.facet.core.ProjectFacetsManager;
import org.osgi.service.prefs.BackingStoreException;
@@ -179,27 +173,10 @@ public class JaxbPreferences {
// ********** flush preferences **********
private static void flushPreferences(Preferences prefs) {
- new FlushPreferencesJob(prefs).schedule();
- }
-
- /* CU private */ static class FlushPreferencesJob
- extends Job
- {
- private final Preferences prefs;
-
- FlushPreferencesJob(Preferences prefs) {
- super(NLS.bind(JptCommonCoreMessages.PREFERENCES_FLUSH_JOB_NAME, prefs.absolutePath()));
- this.prefs = prefs;
- }
-
- @Override
- protected IStatus run(IProgressMonitor monitor) {
- try {
- this.prefs.flush();
- } catch(BackingStoreException ex) {
- return JptJaxbCorePlugin.instance().logError(ex);
- }
- return Status.OK_STATUS;
+ try {
+ prefs.flush();
+ } catch (BackingStoreException ex) {
+ JptJaxbCorePlugin.instance().logError(ex);
}
}

Back to the top