Package org.eclipse.emf.ecp.internal.ui
Class PreferenceHelper
- java.lang.Object
-
- org.eclipse.emf.ecp.internal.ui.PreferenceHelper
-
public final class PreferenceHelper extends java.lang.Object
The preference helper aids storing {key, value} pairs.- Author:
- pfeifferc
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.lang.String
getPreference(java.lang.String key, java.lang.String defaultValue)
Get a preference value for a specific key.static void
setPreference(java.lang.String key, java.lang.String value)
Set the preference value for a specific key.
-
-
-
Method Detail
-
getPreference
public static java.lang.String getPreference(java.lang.String key, java.lang.String defaultValue)
Get a preference value for a specific key.- Parameters:
key
- thedefaultValue
- the- Returns:
- the value if it exists, otherwise the defaultValue
-
setPreference
public static void setPreference(java.lang.String key, java.lang.String value)
Set the preference value for a specific key. Key and value must not equal null.- Parameters:
key
- thevalue
- the
-
-