com.atlassian.gadgets.dashboard.internal.velocity
Class VelocityViewFactory
java.lang.Object
com.atlassian.gadgets.dashboard.internal.velocity.VelocityViewFactory
- All Implemented Interfaces:
- DashboardTabViewFactory
public class VelocityViewFactory
- extends Object
- implements DashboardTabViewFactory
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
VelocityViewFactory
public VelocityViewFactory(com.atlassian.templaterenderer.TemplateRenderer renderer,
StateConverter stateConverter,
PermissionService permissionService,
RepresentationFactory representationFactory,
DashboardEmbedder dashboardEmbedder)
createDashboardView
public ViewComponent createDashboardView(Iterable<DashboardTab> tabs,
DashboardState selectedTabDashboardState,
@Nullable
String username,
int maxGadgets,
GadgetRequestContext gadgetRequestContext)
- Description copied from interface:
DashboardTabViewFactory
Returns a ViewComponent
that will render the DashboardState
and DashboardTab
s
customizing the view based on the permissions the user has to view/edit the dashboard and the
specified Locale
.
This can be used by host applications to place dashboards in a place of their choosing, including tabs
to navigate to other dashboards.
- Specified by:
createDashboardView
in interface DashboardTabViewFactory
- Parameters:
tabs
- a list of dashboards a particular user can see. This can be empty if no tabs are desired.selectedTabDashboardState
- state of the dashboard to be rendered by the ViewComponent
username
- user that is viewing the dashboard and whose permissions will be checkedmaxGadgets
- the (application-wide) maximum number of supported gadgetsgadgetRequestContext
- the context of this request
- Returns:
- a
ViewComponent
that will render the DashboardState
Copyright © 2010 Atlassian. All Rights Reserved.