com.atlassian.gadgets.dashboard.internal.rest
Interface AddGadgetHandler

All Known Implementing Classes:
AddGadgetHandlerImpl

public interface AddGadgetHandler

Interface for adding a gadget spec URI to a dashboard.


Method Summary
 javax.ws.rs.core.Response addGadget(DashboardId dashboardId, GadgetRequestContext gadgetRequestContext, String gadgetUrl)
          Adds the specified gadget to the specified dashboard.
 javax.ws.rs.core.Response addGadget(DashboardId dashboardId, GadgetRequestContext gadgetRequestContext, String gadgetUrl, DashboardState.ColumnIndex columnIndex)
          Adds the specified gadget to the specified dashboard in the specified column.
 javax.ws.rs.core.Response moveGadget(DashboardId targetDashboardId, GadgetId gadgetId, DashboardId sourceDashboardId, DashboardState.ColumnIndex columnIndex, int rowIndexAsInt, GadgetRequestContext gadgetRequestContext)
          Moves the gadget specified by id from the source dashboard to the target dashboard.
 

Method Detail

addGadget

javax.ws.rs.core.Response addGadget(DashboardId dashboardId,
                                    GadgetRequestContext gadgetRequestContext,
                                    String gadgetUrl)
Adds the specified gadget to the specified dashboard.

Parameters:
dashboardId - the ID of the dashboard to add to
gadgetRequestContext - the context of this request
gadgetUrl - the URL to the gadget spec
Returns:
a Response for the client with details on the success or failure

addGadget

javax.ws.rs.core.Response addGadget(DashboardId dashboardId,
                                    GadgetRequestContext gadgetRequestContext,
                                    String gadgetUrl,
                                    DashboardState.ColumnIndex columnIndex)
Adds the specified gadget to the specified dashboard in the specified column.

Parameters:
dashboardId - the ID of the dashboard to add to
gadgetRequestContext - the context of this request
gadgetUrl - the URL to the gadget spec
columnIndex - the column index to add the gadget to
Returns:
a Response for the client with details on the success or failure

moveGadget

javax.ws.rs.core.Response moveGadget(DashboardId targetDashboardId,
                                     GadgetId gadgetId,
                                     DashboardId sourceDashboardId,
                                     DashboardState.ColumnIndex columnIndex,
                                     int rowIndexAsInt,
                                     GadgetRequestContext gadgetRequestContext)
Moves the gadget specified by id from the source dashboard to the target dashboard.

Parameters:
targetDashboardId - The dashboard to move the gadget to
gadgetId - The gadget to move
sourceDashboardId - The source dashboard where the gadget will be deleted
columnIndex - The column to add the gadget to
rowIndexAsInt - The row to insert the gadget in
gadgetRequestContext - the context of this request
Returns:
a Response for the client with details on the success or failure


Copyright © 2009 Atlassian. All Rights Reserved.