com.crystaldecisions.report.web.jsf
Class UIReportPageViewer

java.lang.Object
  |
  +--UIComponentBase
        |
        +--com.crystaldecisions.report.web.jsf.UIReportPageViewer

public class UIReportPageViewer
extends UIComponentBase

The JavaServer Faces version of the DHTML report page viewer.

See Also:
Serialized Form

Field Summary
static java.lang.String COMPONENT_FAMILY
          For internal use only.
static java.lang.String COMPONENT_TYPE
          For internal use only.
 
Constructor Summary
UIReportPageViewer()
           
 
Method Summary
 void addViewerListener(JSFFacesListener facesListener)
          For internal use only.
 void broadcast(FacesEvent event)
          For internal use only.
 void decode(FacesContext context)
          For internal use only.
 java.lang.String getFamily()
          For internal use only.
 boolean needToQueueModelEvents()
          For internal use only.
 void restoreState(FacesContext context, java.lang.Object state)
          For internal use only.
 java.lang.Object saveState(FacesContext context)
          For internal use only.
 void setAllowDatabaseLogonPrompting(boolean canPrompt)
           Sets whether to allow users to be prompted for database logon information.
 void setAllowDrillDown(boolean canDrill)
           Sets whether to allow the user to drill down on the report.
 void setAllowParameterPrompting(boolean canPrompt)
           Sets whether to allow the user to be prompted for parameter values.
 void setDatabaseLogonInfos(ConnectionInfos newDatabaseLogonInfos)
           Sets the information required to log on to the database.
 void setDisplayGroupTree(boolean displayTree)
           Sets whether to display the Group Tree on viewer start up.
 void setDisplayPage(boolean displayPage)
           Sets whether to display the report page.
 void setDisplayToolbar(boolean displayToolbar)
           Sets whether to display the toolbar.
 void setDisplayToolbarExportButton(boolean displayToolbarExportButton)
           Sets whether to display the export button on the toolbar.
 void setDisplayToolbarFindButton(boolean displayToolbarFindButton)
           Sets whether to display the Search button on the toolbar.
 void setDisplayToolbarFindPageButton(boolean displayToolbarFindPageButton)
           Sets whether to display the Go To Page button on the toolbar.
 void setDisplayToolbarLogo(boolean displayToolbarLogo)
           Sets whether to display the Business Objects logo on the toolbar.
 void setDisplayToolbarPageNavigationButtons(boolean displayToolbarPageNavigationButtons)
           Sets whether to display the page navigation buttons on the toolbar.
 void setDisplayToolbarPrintButton(boolean displayToolbarPrintButton)
           Sets whether to display the print button on the toolbar.
 void setDisplayToolbarRefreshButton(boolean displayToolbarRefreshButton)
           Sets whether to display the Refresh button on the toolbar.
 void setDisplayToolbarToggleTreeButton(boolean displayToolbarToggleTreeButton)
           Sets whether to display the Group Tree toggle button on the toolbar.
 void setDisplayToolbarViewList(boolean displayToolbarViewList)
           Sets whether to display the view list on the toolbar.
 void setDisplayToolbarZoomList(boolean displayToolbarZoomList)
           Sets whether to display a zoom factor drop down list on the toolbar.
 void setEnablePageToGrow(boolean canGrow)
           Sets whether the viewer ignores the height and width values it is given and try to find the best fit for the report by taking up as much space as it needs to properly display the report.
 void setGroupTreeWidth(int w)
           Sets the width of the Group Tree.
 void setGroupTreeWidthUnit(CrHtmlUnitEnum unit)
           Specifies the units to use for the width of the Group Tree.
 void setHeight(int h)
           Sets the viewer height in pixels.
 void setHyperlinkTarget(java.lang.String target)
           Sets the window or frame where hyperlinked documents are displayed.
 void setLeft(int l)
           Sets the left position of the viewer.
 void setNeedToQueueModelEvents(boolean needToQueueModelEvents)
          For internal use only.
 void setParameterFields(Fields newParameterFields)
           Sets the parameter fields for the report.
 void setPrintMode(CrPrintMode printMode)
           Note: The JSF report page viewer only supports PDF printing.
 void setProductLocale(java.util.Locale newLocale)
           Sets the locale used to display all text and formatting generated by the viewer (such as the toolbar).
 void setReportSource(IReportSource reportSource)
           Sets the report instance that the viewer will render in HTML.
 void setStyleSheet(java.lang.String cssFileName)
           Sets the style sheet that is used to display the report content.
 void setTop(int t)
           Sets the top position of the viewer.
 void setViewerName(java.lang.String name)
           Sets the name of the viewer.
 void setWidth(int w)
           Sets the viewer width in pixels.
 void setZoomPercentage(int zoom)
           Sets the zoom factor used when displaying the report.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

COMPONENT_FAMILY

public static final java.lang.String COMPONENT_FAMILY

For internal use only.

See Also:
Constant Field Values

COMPONENT_TYPE

public static final java.lang.String COMPONENT_TYPE

For internal use only.

See Also:
Constant Field Values
Constructor Detail

UIReportPageViewer

public UIReportPageViewer()
Method Detail

decode

public void decode(FacesContext context)

For internal use only.


restoreState

public void restoreState(FacesContext context,
                         java.lang.Object state)

For internal use only.


saveState

public java.lang.Object saveState(FacesContext context)

For internal use only.


broadcast

public void broadcast(FacesEvent event)
               throws AbortProcessingException

For internal use only.

AbortProcessingException

needToQueueModelEvents

public boolean needToQueueModelEvents()

For internal use only.


setNeedToQueueModelEvents

public void setNeedToQueueModelEvents(boolean needToQueueModelEvents)

For internal use only.


addViewerListener

public void addViewerListener(JSFFacesListener facesListener)

For internal use only.


getFamily

public java.lang.String getFamily()

For internal use only.


setEnablePageToGrow

public void setEnablePageToGrow(boolean canGrow)

Sets whether the viewer ignores the height and width values it is given and try to find the best fit for the report by taking up as much space as it needs to properly display the report. Defaults to true.

Parameters:
canGrow - true to enable the viewer to find the best fit for the report, false otherwise.

setHeight

public void setHeight(int h)

Sets the viewer height in pixels. Together, the height and width attributes control the dimensions of the viewer. Defaults to 600.

Parameters:
h - The viewer height in pixels.

setWidth

public void setWidth(int w)

Sets the viewer width in pixels. Together, the height and width attributes control the dimensions of the viewer. Defaults to 800.

Parameters:
w - The viewer width in pixels.

setLeft

public void setLeft(int l)

Sets the left position of the viewer. The units used are browser dependent. Defaults to 0.

Parameters:
l - The left position of the viewer.

setTop

public void setTop(int t)

Sets the top position of the viewer. The units used are browser dependent. Defaults to 0.

Parameters:
t - The top position of the viewer.

setDisplayGroupTree

public void setDisplayGroupTree(boolean displayTree)

Sets whether to display the Group Tree on viewer start up. Defaults to true.

Parameters:
displayTree - true to display the Group Tree, false otherwise.

setDisplayPage

public void setDisplayPage(boolean displayPage)

Sets whether to display the report page. Defaults to true.

Parameters:
displayPage - true to display the page, false otherwise.

setDisplayToolbar

public void setDisplayToolbar(boolean displayToolbar)

Sets whether to display the toolbar. Defaults to true.

Parameters:
displayToolbar - true to display the toolbar, false otherwise.

setGroupTreeWidth

public void setGroupTreeWidth(int w)

Sets the width of the Group Tree. Defaults to 200.

Parameters:
w - The width of the Group Tree.

setGroupTreeWidthUnit

public void setGroupTreeWidthUnit(CrHtmlUnitEnum unit)

Specifies the units to use for the width of the Group Tree.

Parameters:
unit - a CrHtmlUnitEnum that specifies the units to use

setZoomPercentage

public void setZoomPercentage(int zoom)

Sets the zoom factor used when displaying the report. Acceptable values for the zoom factor range from 10 to 400 percent.

Parameters:
zoom - The zoom factor used when displaying the report.

setStyleSheet

public void setStyleSheet(java.lang.String cssFileName)

Sets the style sheet that is used to display the report content. The cascading style sheet that you use needs to contain the same classes as the default style sheet. The default style sheet is located in the /crystalreportviewers11/css directory. When specifying a custom style sheet, the paths are always relative to this directory. Defaults to default.css.

Parameters:
cssFileName - The style sheet that is used to display the report content.

setPrintMode

public void setPrintMode(CrPrintMode printMode)

Note: The JSF report page viewer only supports PDF printing. Sets whether to print using PDF or ActiveX print mode when the user clicks the Print button. In PDF print mode, the report is displayed as a PDF; users can then print the PDF from the PDF viewer. In ActiveX print mode, an ActiveX control is downloaded to the client machine and sent directly to the printer. If ActiveX print mode is selected on a system that does not support ActiveX controls, the print mode defaults to PDF print mode. Use PDF to specify PDF print mode and ActiveX to specify ActiveX print mode.

Parameters:
printMode - The print mode (either PDF or ActiveX) used to print the report.

setAllowDatabaseLogonPrompting

public void setAllowDatabaseLogonPrompting(boolean canPrompt)

Sets whether to allow users to be prompted for database logon information. Defaults to true.

Parameters:
canPrompt - true to enable database logon prompting, false otherwise.

setAllowDrillDown

public void setAllowDrillDown(boolean canDrill)

Sets whether to allow the user to drill down on the report. Defaults to true.

Parameters:
canDrill - true to enable drill down, false otherwise.

setAllowParameterPrompting

public void setAllowParameterPrompting(boolean canPrompt)

Sets whether to allow the user to be prompted for parameter values. Defaults to true.

Parameters:
canPrompt - true to enable parameter prompting, false otherwise.

setHyperlinkTarget

public void setHyperlinkTarget(java.lang.String target)

Sets the window or frame where hyperlinked documents are displayed. Use the target _self to display the HTML document in the same frame, _parent to display HTML document in the same frame or window that contains the current frameset, _top to display HTML document in the entire browser window, and _blank to display HTML document in a new browser window. Defaults to _self.

Parameters:
target - The window or frame where hyperlinked documents are displayed.

setDisplayToolbarViewList

public void setDisplayToolbarViewList(boolean displayToolbarViewList)

Sets whether to display the view list on the toolbar. Defaults to true.
Note: The view list includes the Main Report and any views you have drilled-down into. This can include groups, charts and subreports.

Parameters:
displayToolbarViewList - true to display the view list on the toolbar, false otherwise.

setDisplayToolbarExportButton

public void setDisplayToolbarExportButton(boolean displayToolbarExportButton)

Sets whether to display the export button on the toolbar. Defaults to true.

Parameters:
displayToolbarExportButton - true to display the export button on the toolbar, false otherwise.

setDisplayToolbarFindPageButton

public void setDisplayToolbarFindPageButton(boolean displayToolbarFindPageButton)

Sets whether to display the Go To Page button on the toolbar.
Note: If true, the HTML that is returned includes a text box, into which the user can type a page number to navigate to a specific page in the report. If false, the HTML returned displays the current page, but does not allow the user to navigate by page number. Defaults to true.


setDisplayToolbarPageNavigationButtons

public void setDisplayToolbarPageNavigationButtons(boolean displayToolbarPageNavigationButtons)

Sets whether to display the page navigation buttons on the toolbar. Defaults to true.


setDisplayToolbarPrintButton

public void setDisplayToolbarPrintButton(boolean displayToolbarPrintButton)

Sets whether to display the print button on the toolbar. Defaults to true.
Note: The default setting is PDF print mode.

Parameters:
displayToolbarPrintButton - true to display the print button on the toolbar, false otherwise.

setDisplayToolbarRefreshButton

public void setDisplayToolbarRefreshButton(boolean displayToolbarRefreshButton)

Sets whether to display the Refresh button on the toolbar. Defaults to false.

Parameters:
displayToolbarRefreshButton - true to display the Refresh button on the toolbar, false otherwise.

setDisplayToolbarFindButton

public void setDisplayToolbarFindButton(boolean displayToolbarFindButton)

Sets whether to display the Search button on the toolbar. Defaults to true.

Parameters:
displayToolbarFindButton - true to display the Search button on the toolbar, false otherwise.

setDisplayToolbarToggleTreeButton

public void setDisplayToolbarToggleTreeButton(boolean displayToolbarToggleTreeButton)

Sets whether to display the Group Tree toggle button on the toolbar. Defaults to true.

Parameters:
displayToolbarToggleTreeButton - true to display the Group Tree toggle button on the toolbar, false otherwise.

setDisplayToolbarZoomList

public void setDisplayToolbarZoomList(boolean displayToolbarZoomList)

Sets whether to display a zoom factor drop down list on the toolbar. Defaults to true.

Parameters:
displayToolbarZoomList - true to display a zoom factor drop down list on the toolbar, false otherwise.

setDisplayToolbarLogo

public void setDisplayToolbarLogo(boolean displayToolbarLogo)

Sets whether to display the Business Objects logo on the toolbar. Defaults to true.

Parameters:
displayToolbarLogo - true to display the Business Objects logo on the toolbar, false otherwise.

setReportSource

public void setReportSource(IReportSource reportSource)

Sets the report instance that the viewer will render in HTML.

Parameters:
reportSource - An Object representing the report instance that the viewer will render in HTML.

setViewerName

public void setViewerName(java.lang.String name)

Sets the name of the viewer. The name represents the HTML form name that is used to post back requests to the server. When a page has more than one viewer, each viewer must be given a unique name; otherwise, a post back in one viewer may be sent to the wrong viewer. Defaults to CrystalViewer.

Parameters:
name - A String represents the HTML form name.

setDatabaseLogonInfos

public void setDatabaseLogonInfos(ConnectionInfos newDatabaseLogonInfos)

Sets the information required to log on to the database.

Parameters:
newDatabaseLogonInfos - A com.crystaldecisions.sdk.occa.report.data.ConnectionInfo object that specifies the information required to log on to the database.

setParameterFields

public void setParameterFields(Fields newParameterFields)

Sets the parameter fields for the report.

Parameters:
newParameterFields - A com.crystaldecisions.sdk.occa.report.data.Fields object that specifies the new parameter fields for the report.

setProductLocale

public void setProductLocale(java.util.Locale newLocale)

Sets the locale used to display all text and formatting generated by the viewer (such as the toolbar). The productLocale setting does not apply to text associated with the report content (the browser locale is used to determine how to format report-related text). Additionally, the productLocale setting does not apply to the groupTree text.

Parameters:
newLocale - can be set using a locale string formats such as en_us, en-us, and en