當前位置: 首頁>>代碼示例>>Java>>正文


Java IEclipsePreferences.removeNodeChangeListener方法代碼示例

本文整理匯總了Java中org.eclipse.core.runtime.preferences.IEclipsePreferences.removeNodeChangeListener方法的典型用法代碼示例。如果您正苦於以下問題:Java IEclipsePreferences.removeNodeChangeListener方法的具體用法?Java IEclipsePreferences.removeNodeChangeListener怎麽用?Java IEclipsePreferences.removeNodeChangeListener使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在org.eclipse.core.runtime.preferences.IEclipsePreferences的用法示例。


在下文中一共展示了IEclipsePreferences.removeNodeChangeListener方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: removeNodeListeners

import org.eclipse.core.runtime.preferences.IEclipsePreferences; //導入方法依賴的package包/類
protected void removeNodeListeners() {
	for (IScopeContext scopeContext : SCOPE_CONTEXTS) {
		try {
			IEclipsePreferences node = scopeContext.getNode("");
			node.removeNodeChangeListener(nodeListener);
			node.accept((curNode) -> {
					curNode.removePreferenceChangeListener(changeListener);
					return true;
			});
		} catch (BackingStoreException e) {
			PrefEditorPlugin.log(e);
		}
	}
}
 
開發者ID:32kda,項目名稱:com.onpositive.prefeditor,代碼行數:15,代碼來源:PlatformPreferenceProvider.java

示例2: endRecording

import org.eclipse.core.runtime.preferences.IEclipsePreferences; //導入方法依賴的package包/類
/**
 * Ends the recording process. No other changes to the preference tree are
 * recorded after this method is called.
 * 
 * @throws IllegalStateException if {@code startRecording()} had not been
 *         previously called, or if recording has already completed on this
 *         object.
 */
public void endRecording() {
  synchronized (lock) {
    Preconditions.checkState(currState == State.RECORDING, "Recorder object is not currently recording");

    currState = State.COMPLETE;

    for (IEclipsePreferences node : recordedNodes) {
      node.removeNodeChangeListener(listener);
      node.removePreferenceChangeListener(listener);
    }

    recordedNodes.clear();
  }
}
 
開發者ID:alfsch,項目名稱:workspacemechanic,代碼行數:23,代碼來源:PreferenceRecorder.java

示例3: disposeNodeChangeListener

import org.eclipse.core.runtime.preferences.IEclipsePreferences; //導入方法依賴的package包/類
/**
 * Dispose the node change listener.
 */
private void disposeNodeChangeListener() {
	if (nodeChangeListener != null) {
		IEclipsePreferences preferences = getStorePreferences();
		if (preferences == null) {
			return;
		}
		IEclipsePreferences parent = (IEclipsePreferences) preferences.parent();
		if (parent == null)
			return;
		parent.removeNodeChangeListener(nodeChangeListener);
		nodeChangeListener = null;
	}
}
 
開發者ID:cplutte,項目名稱:bts,代碼行數:17,代碼來源:FixedScopedPreferenceStore.java


注:本文中的org.eclipse.core.runtime.preferences.IEclipsePreferences.removeNodeChangeListener方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。