|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectsk.baka.ambient.AppStateHandler
public final class AppStateHandler
Handles application configuration and state storage.
| Constructor Summary | |
|---|---|
AppStateHandler(AmbientApplication app)
Creates new handler. |
|
| Method Summary | |
|---|---|
boolean |
containsStateAware(Class<? extends AppState.IAppStateAware> clazz)
Checks if a handler with given class is present in the state aware handlers. |
ConfigurationBean |
getConfig()
Returns the configuration bean. |
AppState |
getStartupState()
Returns the startup application state. |
void |
registerStateAware(AppState.IAppStateAware aware)
Registers given state aware object. |
void |
saveConfig()
Stores the configuration bean to the shared preferences. |
void |
saveState()
Saves the state. |
void |
unregisterStateAware(AppState.IAppStateAware aware)
Unregisters given state aware object. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AppStateHandler(AmbientApplication app)
app - owning application.| Method Detail |
|---|
public boolean containsStateAware(Class<? extends AppState.IAppStateAware> clazz)
clazz - the handler class, must not be null.
true if given handler is present, false
otherwise.public void saveState()
public void registerStateAware(AppState.IAppStateAware aware)
aware - the object instance.public void unregisterStateAware(AppState.IAppStateAware aware)
aware - the object instance.public AppState getStartupState()
null.public void saveConfig()
public ConfigurationBean getConfig()
ConfigActivity may
modify this bean!
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||