com.crystaldecisions.sdk.plugin.desktop.common
Interface IReportAlert


public interface IReportAlert

This interface allows you to specify the alert information that is displayed in an alert notification email. Alerts are custom messages that appear when certain conditions are met by data in a report; they must be added when the report is created. An alert may indicate an action to be taken by the user or information about report data.

Alerts are created from formulas that evaluate conditions you specify. If the condition is true, the alert is triggered. For each triggered alert, the alert message and a link to a filtered view of the report are displayed in a notification email. Alert messages for records that match the alert condition will also be included in the email, but links to these instances will not be provided.

Information about report alert destinations can be found using the ISchedulingInfo getAlertDestination method. This method returns the IDestination object that contains the report alert destination. To disable alert notification for a report, set the IDestination method setName to an empty String.

Note: The IReportAlert interface is most frequently used in conjunction with the IReportProcessingInfo interface.


Method Summary
 int getAlertSetSize()
           Returns the maximum number of records that will be shown for each alert in the alert notification email.
 java.lang.String getName()
          Returns the name of the alert.
 java.lang.String getViewerURL()
           Returns the viewer URL associated with an alert that will be included in the alert notification email.
 boolean isEnabled()
          Returns true if the alert is enabled, and false otherwise.
 void setAlertSetSize(int size)
           Sets the maximum number of records that will be shown for each alert in the alert notification email.
 void setViewerURL(java.lang.String strURL)
           Sets the viewer URL associated with an alert that will be included in the alert notification email.
 

Method Detail

getName

public java.lang.String getName()
                         throws SDKException

Returns the name of the alert.

Returns:
A String containing the alert name.
Throws:
SDKException - This is thrown if the process is unsuccessful.

getViewerURL

public java.lang.String getViewerURL()
                              throws SDKException

Returns the viewer URL associated with an alert that will be included in the alert notification email. The URL is a link to the report that contains the triggered alert. This URL should contain the HTTP protocol, the web server name, the web server virtual path, the name of the JSP page used to view the report, and the report ID (or some other property that identifies the report, such as the report name). For example:
http://server/viewer.jsp?id=%SI_ID%

Note: The percentage signs around the property name indicate that a variable is being used; the Enterprise system will substitute the property name with the appropriate value (for example, the ID of a specific report).

Returns:
A String containing the viewer URL associated with an alert that will be included in the alert notification email.
Throws:
SDKException - This is thrown if the process is unsuccessful.
See Also:
com.crystaldecisions.com.sdk.plugin.desktop.report.IReportGlobal.setEmbeddedLinkURL

setViewerURL

public void setViewerURL(java.lang.String strURL)

Sets the viewer URL associated with an alert that will be included in the alert notification email. The URL is a link to the report that contains the triggered alert. This URL should contain the HTTP protocol, the web server name, the web server virtual path, the name of the JSP page used to view the report, and the report ID (or some other property that identifies the report, such as the report name). For example:
http://server/viewer.jsp?id=%SI_ID%. or %SI_VIEWER_URL%

Note: The percentage signs around the property name indicate that a variable is being used; the Enterprise system will substitute the property name with the appropriate value (for example, the ID of a specific report).

Parameters:
strURL - A String containing the viewer URL associated with an alert that will be included in the alert notification email.
See Also:
com.crystaldecisions.com.sdk.plugin.desktop.report.IReportGlobal.setEmbeddedLinkURL

isEnabled

public boolean isEnabled()
                  throws SDKException

Returns true if the alert is enabled, and false otherwise. This is set when you design the report.

Returns:
true if alert is enabled, and false otherwise.
Throws:
SDKException - This is thrown if the process is unsuccessful.

getAlertSetSize

public int getAlertSetSize()
                    throws SDKException

Returns the maximum number of records that will be shown for each alert in the alert notification email. A report may contain a number of records that match the condition of a particular alert. An alert message for each of these instances will be displayed unless you limit the size of the alert set. For example, if you set the AlertSetSize property to 5, then an alert message for the first five records in the report that meet the alert condition will be displayed in the alert notification email.

Returns:
An int specifying the maximum number of records that will be shown for each alert in the alert notification email.
Throws:
SDKException - This is thrown if the process is unsuccessful.

setAlertSetSize

public void setAlertSetSize(int size)

Sets the maximum number of records that will be shown for each alert in the alert notification email. A report may contain a number of records that match the condition of a particular alert. An alert message for each of these instances will be displayed unless you limit the size of the alert set. For example, if you set the AlertSetSize property to 5, then an alert message for the first five records in the report that meet the alert condition will be displayed in the alert notification email. The default value is 5.

Parameters:
size - An int specifying the maximum number of records that will be shown for each alert in the alert notification email.