info.magnolia.ui.contentapp.browser
Class BrowserPresenter

java.lang.Object
  extended by info.magnolia.ui.contentapp.browser.BrowserPresenter
All Implemented Interfaces:
ActionbarPresenter.Listener, BrowserView.Listener

public class BrowserPresenter
extends Object
implements ActionbarPresenter.Listener, BrowserView.Listener

The browser is a core component of AdminCentral. It represents the main hub through which users can interact with JCR data. It is compounded by three main sub-components:

Its main configuration point is the WorkbenchDefinition through which one defines the JCR workspace to connect to, the columns/properties to display, the available actions and so on.


Constructor Summary
BrowserPresenter(ActionExecutor actionExecutor, SubAppContext subAppContext, BrowserView view, info.magnolia.event.EventBus admincentralEventBus, info.magnolia.event.EventBus subAppEventBus, ActionbarPresenter actionbarPresenter, info.magnolia.objectfactory.ComponentProvider componentProvider, WorkbenchPresenter workbenchPresenter)
           
 
Method Summary
 ActionbarPresenter getActionbarPresenter()
           
 String getDefaultViewType()
           
 String getIcon(String itemName)
           
 String getLabel(String itemName)
           
 List<String> getSelectedItemIds()
           
 BrowserView getView()
           
 String getWorkspace()
           
 boolean hasViewType(String viewType)
           
 void onActionbarItemClicked(String itemName)
           
 void onActionBarSelection(String actionName)
           
 void resync(List<String> itemIds, String viewType, String query)
          Synchronizes the underlying view to reflect the status extracted from the Location token, i.e.
 BrowserView start()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BrowserPresenter

@Inject
public BrowserPresenter(ActionExecutor actionExecutor,
                               SubAppContext subAppContext,
                               BrowserView view,
                               @Named(value="admincentral")
                               info.magnolia.event.EventBus admincentralEventBus,
                               @Named(value="subapp")
                               info.magnolia.event.EventBus subAppEventBus,
                               ActionbarPresenter actionbarPresenter,
                               info.magnolia.objectfactory.ComponentProvider componentProvider,
                               WorkbenchPresenter workbenchPresenter)
Method Detail

start

public BrowserView start()

getSelectedItemIds

public List<String> getSelectedItemIds()

getDefaultViewType

public String getDefaultViewType()
Returns:
The configured default view Type.
If non define, return the first Content Definition as default.

hasViewType

public boolean hasViewType(String viewType)

getView

public BrowserView getView()

getActionbarPresenter

public ActionbarPresenter getActionbarPresenter()

getWorkspace

public String getWorkspace()

resync

public void resync(List<String> itemIds,
                   String viewType,
                   String query)
Synchronizes the underlying view to reflect the status extracted from the Location token, i.e. selected itemId, view type and optional query (in case of a search view).


onActionbarItemClicked

public void onActionbarItemClicked(String itemName)
Specified by:
onActionbarItemClicked in interface ActionbarPresenter.Listener

onActionBarSelection

public void onActionBarSelection(String actionName)
Specified by:
onActionBarSelection in interface BrowserView.Listener

getLabel

public String getLabel(String itemName)
Specified by:
getLabel in interface ActionbarPresenter.Listener

getIcon

public String getIcon(String itemName)
Specified by:
getIcon in interface ActionbarPresenter.Listener


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