Java Code Examples for org.eclipse.core.runtime.preferences.IEclipsePreferences#nodeExists()
The following examples show how to use
org.eclipse.core.runtime.preferences.IEclipsePreferences#nodeExists() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: FixedScopedPreferenceStore.java From xtext-eclipse with Eclipse Public License 2.0 | 6 votes |
/** * Dispose the preference store listener. */ private void disposePreferenceStoreListener() { IEclipsePreferences root = (IEclipsePreferences) Platform .getPreferencesService().getRootNode().node( Plugin.PLUGIN_PREFERENCE_SCOPE); try { if (!(root.nodeExists(nodeQualifier))) { return; } } catch (BackingStoreException e) { return;// No need to report here as the node won't have the // listener } IEclipsePreferences preferences = getStorePreferences(); if (preferences == null) { return; } if (preferencesListener != null) { preferences.removePreferenceChangeListener(preferencesListener); preferencesListener = null; } }
Example 2
Source File: ScopedPreferenceStore.java From e4Preferences with Eclipse Public License 1.0 | 6 votes |
/** * Dispose the receiver. */ private void disposePreferenceStoreListener() { IEclipsePreferences root = (IEclipsePreferences) Platform .getPreferencesService().getRootNode().node( Plugin.PLUGIN_PREFERENCE_SCOPE); try { if (!(root.nodeExists(nodeQualifier))) { return; } } catch (BackingStoreException e) { return;// No need to report here as the node won't have the // listener } IEclipsePreferences preferences = getStorePreferences(); if (preferences == null) { return; } if (preferencesListener != null) { preferences.removePreferenceChangeListener(preferencesListener); preferencesListener = null; } }