Style Intelligence v12.0

inetsoft.sree
Interface ViewerAction

All Superinterfaces:
Serializable

public interface ViewerAction
extends Serializable

This class defines a custom button on a viewer. ViewerAction classes can be registered on the server to add custom buttons to the viewer. To add a custom button to the report viewer, register the ViewerAction class in the Adm GUI. A button is added to the viewer. When user clicks on the button, the ViewerAction's actionPerformed() is invoked.


Method Summary
 RepletCommand actionPerformed(Object rid, RepletRepository repo, Replet replet, RepletRequest req)
          Handle the action.
 String getIconResource()
          Get the resource name for an image to be used as a tool button in the viewer.
 String getLabel()
          Get the button label.
 RepletParameters getParameters()
          Get the parameters for this action.
 boolean isVisible(Object rid, Principal user, RepletRepository repo)
          Check if this action should be displayed for this report.
 

Method Detail

getIconResource

String getIconResource()
Get the resource name for an image to be used as a tool button in the viewer.


getLabel

String getLabel()
Get the button label. It is used as the tool tip or as the button label if text based toolbar is selected for DHTML viewer. The label is also used to uniquely identify a button, so it must be unique in each environment.


isVisible

boolean isVisible(Object rid,
                  Principal user,
                  RepletRepository repo)
Check if this action should be displayed for this report.

Parameters:
rid - replet id.
user - user object, an instance of SRPrincipal.
repo - replet repository object.

getParameters

RepletParameters getParameters()
Get the parameters for this action. If parameter is defined, the parameter will be prompted before the action is invoked.

Returns:
parameter definition or null if no parameter is needed.

actionPerformed

RepletCommand actionPerformed(Object rid,
                              RepletRepository repo,
                              Replet replet,
                              RepletRequest req)
Handle the action.

Parameters:
rid - replet id.
repo - replet repository object.
replet - replet object.

Copyright © 1996-2014 InetSoft Technology Corp. All Rights Reserved.