public class GGPreferences
extends java.lang.Object
| Constructor and Description | 
|---|
GGPreferences(android.app.Activity activity)
Creates a GGPreferences instance to retrieve and store 
 default shared preferences of the given activity. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
void | 
remove(java.lang.String key)
Remove the preference value associated to the given key. 
 | 
void | 
removeAll()
Remove all preferences. 
 | 
java.lang.Boolean | 
retrieveBoolean(java.lang.String key)
Retrieves a boolean value associated to the given key. 
 | 
java.lang.Float | 
retrieveFloat(java.lang.String key)
Retrieves a float value associated to the given key. 
 | 
java.lang.Integer | 
retrieveInt(java.lang.String key)
Retrieves an integer value associated to the given key. 
 | 
java.lang.Long | 
retrieveLong(java.lang.String key)
Retrieves a long value associated to the given key. 
 | 
java.lang.String | 
retrieveString(java.lang.String key)
Retrieves an string value associated to the given key. 
 | 
void | 
storeBoolean(java.lang.String key,
            boolean value)
Stores a boolean value associated to the given key. 
 | 
void | 
storeFloat(java.lang.String key,
          int value)
Stores a float value associated to the given key. 
 | 
void | 
storeInt(java.lang.String key,
        int value)
Stores an integer value associated to the given key. 
 | 
void | 
storeLong(java.lang.String key,
         long value)
Stores a long value associated to the given key. 
 | 
void | 
storeString(java.lang.String key,
           java.lang.String value)
Stores a string value associated to the given key. 
 | 
public GGPreferences(android.app.Activity activity)
activity - the activity whose default preferences are usedpublic void storeBoolean(java.lang.String key,
                boolean value)
key - the key stringvalue - the associated valuepublic void storeInt(java.lang.String key,
            int value)
key - the key stringvalue - the associated valuepublic void storeLong(java.lang.String key,
             long value)
key - the key stringvalue - the associated valuepublic void storeFloat(java.lang.String key,
              int value)
key - the key stringvalue - the associated valuepublic void storeString(java.lang.String key,
               java.lang.String value)
key - the key stringvalue - the associated valuepublic java.lang.Boolean retrieveBoolean(java.lang.String key)
key - the key string; null, if key is not foundpublic java.lang.Integer retrieveInt(java.lang.String key)
key - the key string; null, if key is not foundpublic java.lang.Long retrieveLong(java.lang.String key)
key - the key string; null, if key is not foundpublic java.lang.Float retrieveFloat(java.lang.String key)
key - the key string; null, if key is not foundpublic java.lang.String retrieveString(java.lang.String key)
key - the key string; null, if key is not foundpublic void removeAll()
public void remove(java.lang.String key)
key - the key string