info.magnolia.ui.framework.app
Class BaseApp

java.lang.Object
  extended by info.magnolia.ui.framework.app.BaseApp
All Implemented Interfaces:
App
Direct Known Subclasses:
ContentApp

public class BaseApp
extends Object
implements App

Basic app implementation with default behavior suitable for most apps.

See Also:
App

Field Summary
protected  AppContext appContext
           
 
Constructor Summary
protected BaseApp(AppContext appContext, AppView view)
           
 
Method Summary
protected  AppContext getAppContext()
           
 AppView getView()
           
 void locationChanged(Location location)
          Called when the location changes and the app is already running.
 void openChooseDialog(UiContext overlayLayer, String selectedId, ChooseDialogCallback callback)
          Open a dialog which enables a user to choose an item from the app.
 void start(Location location)
          Called when the app is started.
 void stop()
          Called when the user stops the app.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

appContext

protected AppContext appContext
Constructor Detail

BaseApp

@Inject
protected BaseApp(AppContext appContext,
                         AppView view)
Method Detail

locationChanged

public void locationChanged(Location location)
Description copied from interface: App
Called when the location changes and the app is already running.

Specified by:
locationChanged in interface App
Parameters:
location - the new location

start

public void start(Location location)
Description copied from interface: App
Called when the app is started. The location passed in is the location that triggered the app to be started.

Specified by:
start in interface App
Parameters:
location - the location that triggered the app to be started

getAppContext

protected AppContext getAppContext()

stop

public void stop()
Description copied from interface: App
Called when the user stops the app.

Specified by:
stop in interface App

getView

public AppView getView()
Specified by:
getView in interface App

openChooseDialog

public void openChooseDialog(UiContext overlayLayer,
                             String selectedId,
                             ChooseDialogCallback callback)
Description copied from interface: App
Open a dialog which enables a user to choose an item from the app.

Specified by:
openChooseDialog in interface App
Parameters:
overlayLayer - The layer over which the opened dialog should be presented and be modal. See Shell, SubAppContext, AppContext.


Copyright © 2013 Magnolia International Ltd.. All Rights Reserved.