com.opera.core.systems.scope.services
Interface IPrefs

All Known Implementing Classes:
Prefs

public interface IPrefs


Method Summary
 java.lang.String getPref(java.lang.String section, java.lang.String key, PrefsProtos.GetPrefArg.Mode mode)
          Gets a preference from the operaprefs.ini from a specific section.
 void init()
           
 java.util.List<PrefsProtos.Pref> listPrefs(java.lang.Boolean sort, java.lang.String section)
          Lists the preferences in a specific section from operaprefs.ini.
 void setPrefs(java.lang.String section, java.lang.String key, java.lang.String value)
          Sets a preference in operaprefs.ini in a specific section.
 

Method Detail

init

void init()

getPref

java.lang.String getPref(java.lang.String section,
                         java.lang.String key,
                         PrefsProtos.GetPrefArg.Mode mode)
Gets a preference from the operaprefs.ini from a specific section. Optionally it can get the default setting of the preference.

Parameters:
section - section to get the preference from
key - key in the section
mode - get the current or default setting of the preference
Returns:
returns the preference in a string

listPrefs

java.util.List<PrefsProtos.Pref> listPrefs(java.lang.Boolean sort,
                                           java.lang.String section)
Lists the preferences in a specific section from operaprefs.ini.

Parameters:
sort - if true returned list is sorted
section - list prefs in this section
Returns:
a list of preferences in a particular section

setPrefs

void setPrefs(java.lang.String section,
              java.lang.String key,
              java.lang.String value)
Sets a preference in operaprefs.ini in a specific section.

Parameters:
section - the section name
key - the key in the section
value - value to set this preference to


Copyright © 2011. All Rights Reserved.