KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > jdt > internal > debug > core > JDIDebugPluginPreferenceInitializer


1 /*******************************************************************************
2  * Copyright (c) 2004, 2007 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11 package org.eclipse.jdt.internal.debug.core;
12
13 import org.eclipse.core.runtime.Preferences;
14 import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;
15 import org.eclipse.jdt.debug.core.IJavaBreakpoint;
16 import org.eclipse.jdt.debug.core.JDIDebugModel;
17
18 public class JDIDebugPluginPreferenceInitializer extends AbstractPreferenceInitializer {
19
20     public JDIDebugPluginPreferenceInitializer() {
21         super();
22     }
23
24     /* (non-Javadoc)
25      * @see org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer#initializeDefaultPreferences()
26      */

27     public void initializeDefaultPreferences() {
28         Preferences prefs = JDIDebugPlugin.getDefault().getPluginPreferences();
29         prefs.setDefault(JDIDebugModel.PREF_REQUEST_TIMEOUT, JDIDebugModel.DEF_REQUEST_TIMEOUT);
30         prefs.setDefault(JDIDebugModel.PREF_HCR_WITH_COMPILATION_ERRORS, true);
31         prefs.setDefault(JDIDebugModel.PREF_SUSPEND_FOR_BREAKPOINTS_DURING_EVALUATION, true);
32         prefs.setDefault(JDIDebugPlugin.PREF_DEFAULT_BREAKPOINT_SUSPEND_POLICY, IJavaBreakpoint.SUSPEND_THREAD);
33         prefs.setDefault(JDIDebugPlugin.PREF_SHOW_REFERENCES_IN_VAR_VIEW, false);
34         prefs.setDefault(JDIDebugPlugin.PREF_ALL_REFERENCES_MAX_COUNT, 100);
35         prefs.setDefault(JDIDebugPlugin.PREF_ALL_INSTANCES_MAX_COUNT, 100);
36         prefs.addPropertyChangeListener(JDIDebugPlugin.getDefault());
37     }
38 }
39
Popular Tags