| |||||||
FRAMES NO FRAMES |
Use the webuijsf:alarmStatus
tag to display alarm information as hyperlinks. This
tag is typically specified as part of the webuijsf:masthead
tag's statusArea
facet. The webuijsf:alarmStatus
tag produces alarm information identical to the webuijsf:masthead
tag's alarmCounts
attribute. See the webuijsf:masthead
documentation for more information about the statusArea
facet.
statusArea
facet overrides the masthead's status area attributes.
The webuijsf:alarmStatus
tag enables you to include the alarm counts in the status area,
along with your custom components. The webuijsf:jobStatus
,
webuijsf:timeStamp
, and webuijsf:notificationPhrase
tags enable you to include the other standard status area components as
well. Note that when you use the webuijsf:masthead
attributes, spacing between the components is handled
automatically. When
you use the webuijsf:alarmStatus
, webuijsf:jobStatus
, webuijsf:timeStamp
,
and webuijsf:notificationPhrase
tags in the statusArea
facet,
you may have to add code to handle the spacing between the components,
as demonstrated in the example below.
Note that the AlarmStatus
component is deprecated. Look at the examples to see
how the equivalent of webuijsf:alarmStatus
can be created in the masthead.
The rendered HTML page includes a <span>
element
that contains the label for the alarm count. The label text is "Current
Alarms:" by default. Immediately following the <span>
element are four image hyperlinks that show the number of alarms for each severity.
You can determine how the links respond when clicked by specifying attributes such
as url
, action
,
or actionListener
. The links can be used to show
the user more information about the alarms.
webuijsf:alarmStatus
tagUse the text
attribute to specify a title or label for the alarmStatus component. The default
text is "Current Alarms:".
The immediate
attribute should be set to true when this component
is used in the masthead.
By default, all four alarm icons and counts are displayed. You can prevent any alarm type from being displayed by setting the following attributes to false:
criticalAlarms
downAlarms
majorAlarms
minorAlarms
numCriticalAlarms
numDownAlarms
numMajorAlarms
numMinorAlarms
The order in which you specify the attributes does not matter because the alarms are always displayed in the order of severity: down, critical, major, minor. If the count of an alarm type is 0, a dimmed version of the icon is displayed.
You can also specify key identifiers for alternative theme image files to use for the icons. See the Theme Identifiers section.
The image-related attributes such as align, border and vspace apply to all the alarm images. The link-related attributes such as type, url, and action apply to all the alarm count links.
If you want to customize a particular alarm count icon count, you can use facets to replace any of the icons. See Facets for more information.
The webuijsf:alarmStatus
tag supports the following facets.
alarmLabel |
Specifies a custom component to use for the label. This facet overrides the static text label that is rendered by default, and also overrides the text attribute. This facet might be used to create a hyperlink label, instead of static text. |
criticalAlarms |
Specifies a custom component for the icon and count
for critical alarms. Overrides criticalAlarms and
numCriticalAlarms attributes.
|
downAlarms |
Specifies a custom component for the icon and
count for down alarms. Overrides downAlarms and
numDownAlarms attributes.
|
majorAlarms |
Specifies a custom component for the icon and
count for major alarms. Overrides majorAlarms and
numMajorAlarms attributes.
|
minorAlarms |
Specifies a custom component for the icon and
count for minor alarms. Overrides minorAlarms and
numMinorAlarms attributes.
|
For example, to replace the down alarms icon, use the following facet in the
webuijsf:alarmStatus
tag:
<f:facet name="downAlarms">
<h:panelGroup id="downAlarmsPanel">
<webuijsf:imageHyperlink id="downAlarmsLink"
styleClass="#{themeStyles.MASTHEAD_ALARM_LINK}"
icon="ALARM_DOWN_MEDIUM" text=" 3"
url="downAlarms.jsp" />
<f:verbatim> </f:verbatim>
</h:panelGroup>
</f:facet>
Note that you can use the theme style class MstAlmLnk
to apply
appropriate spacing for links you create with facets.
The theme provides the following alarm icon key identifiers.
ALARM_CRITICAL_SMALL ALARM_CRITICAL_MEDIUM ALARM_MAJOR_SMALL ALARM_MAJOR_MEDIUM ALARM_MINOR_SMALL ALARM_MINOR_MEDIUM ALARM_DOWN_SMALL ALARM_DOWN_MEDIUM ALARM_MASTHEAD_CRITICAL_MEDIUM ALARM_MASTHEAD_CRITICAL_DIMMED ALARM_MASTHEAD_DOWN_MEDIUM ALARM_MASTHEAD_DOWN_DIMMED ALARM_MASTHEAD_MAJOR_MEDIUM ALARM_MASTHEAD_MAJOR_DIMMED ALARM_MASTHEAD_MINOR_MEDIUM ALARM_MASTHEAD_MINOR_DIMMED
These identifiers can be specified with the criticalIcon
,
majorIcon
, minorIcon
,
downIcon
attributes to vary the appearance of the icons.
None.
This example shows the webuijsf:alarmStatus
tag with attributes set to indicate the
numbers of each type of alarm. The example shows literal values for these
attributes, but you can set them to a JavaServer Faces EL expression
that resolves to a backing bean property. The f:verbatim
tags are
used to add style selectors that are defined in the theme style sheet.
<webuijsf:masthead id="Masthead" productImageURL="../images/webconsole.png"
productImageDescription="Java Web Console" userInfo="user_name"
serverInfo="server_name">
<f:facet name="statusArea">
<webuijsf:panelGroup id="statusPanel" separator="">
<webuijsf:markup tag="div" styleClass="#{themeStyles.MASTHEAD_STATUS_DIV}">
<webuijsf:notificationPhrase text="Important info goes here" />
<webuijsf:image icon="DOT" border="0" width="20" height="1" />
<webuijsf:jobStatus numJobs="1" />
</webuijsf:markup>
<webuijsf:markup tag="div" styleClass="#{themeStyles.MASTHEAD_TIME_DIV}">
<webuijsf:timeStamp />
</webuijsf:markup>
<webuijsf:markup tag="div" styleClass="#{themeStyles.MASTHEAD_ALARM_DIV}">
<webuijsf:alarmStatus numDownAlarms="0" numCriticalAlarms="1" numMajorAlarms="2" numMinorAlarms="3" />
</webuijsf:markup>
</webuijsf:panelGroup>
</f:facet>
</webuijsf:masthead>
webuijsf:alarmStatus
tag
<f:facet name="currentAlarmsInfo">
<webuijsf:panelGroup id="alarmStatus">
<webuijsf:staticText id="labelstatus" text="Current Info :" styleClass="#{themeStyles.MASTHEAD_TEXT}"/>
<webuijsf:panelGroup id="downAlarmsPanel">
<webuijsf:imageHyperlink id="downAlarmsLink"
icon="ALARM_MASTHEAD_DOWN_DIMMED" text="0" disabled="true" >
<f:param name="severity" value="down" />
</webuijsf:imageHyperlink>
<f:verbatimk> </f:verbatim>
</webuijsf:panelGroup>
<webuijsf:panelGroup id="criticalAlarmsPanel">
<webuijsf:imageHyperlink id="criticalAlarmsLink" styleClass="#{themeStyles.MASTHEAD_ALARM_LINK}"
icon="ALARM_MASTHEAD_CRITICAL_MEDIUM" text="1" actionExpression="#{MastheadBean.alarmClicked}">
<f:param name="severity" value="critical"/>
</webuijsf:imageHyperlink>
<f:verbatim> </f:verbatim>
</webuijsf:panelGroup>
<webuijsf:panelGroup id="majorAlarmsPanel">
<webuijsf:imageHyperlink id="majorAlarmsLink" styleClass="#{themeStyles.MASTHEAD_ALARM_LINK}"
icon="ALARM_MASTHEAD_MAJOR_MEDIUM" text="2" actionExpression="#{MastheadBean.alarmClicked}">
<f:param name="severity" value="major"/>
</webuijsf:imageHyperlink>
<f:verbatim> </f:verbatim>
</webuijsf:panelGroup>
<webuijsf:panelGroup id="minorAlarmsPanel">
<webuijsf:imageHyperlink id="minorAlarmsLink" styleClass="#{themeStyles.MASTHEAD_ALARM_LINK}"
icon="ALARM_MASTHEAD_MINOR_MEDIUM" text="3" actionExpression="#{MastheadBean.alarmClicked}">
<f:param name="severity" value="minor"/>
</webuijsf:imageHyperlink>
<f:verbatim> </f:verbatim>
</webuijsf:panelGroup>
</webuijsf:panelGroup>
</f:facet>
Tag Information | |
Tag Class | com.sun.webui.jsf.component.AlarmStatusTag |
TagExtraInfo Class | None |
Body Content | JSP |
Display Name | None |
Attributes | ||||
Name | Required | Request-time | Type | Description |
binding | false | false | java.lang.String | A ValueExpression that resolves to the UIComponent that corresponds to this tag. This binding allows the Java bean that contains the UIComponent to manipulate the UIComponent, its properties, and its children. |
numMajorAlarms | false | false | java.lang.String | The number of major alarms, can be displayed next to the appropriate icon. |
value | false | false | java.lang.String | The current value of this component. |
onDblClick | false | false | java.lang.String | Scripting code that is executed when a mouse double-click occurs over this component. |
majorIcon | false | false | java.lang.String | The key identifier for the theme image to use for the major alarms icon. |
numDownAlarms | false | false | java.lang.String | The number of down alarms, to display next to the appropriate icon. |
criticalAlarms | false | false | java.lang.String | Specifies if the critical alarm count should be displayed. Is false to prevent display of critical alarm count and icon. |
minorIcon | false | false | java.lang.String | The key identifier for the theme image to use for the minor alarms icon. |
numCriticalAlarms | false | false | java.lang.String | The number of critical alarms, to display next to the appropriate icon. |
styleClass | false | false | java.lang.String | CSS style class or classes to be applied to the outermost HTML element when this component is rendered. |
majorAlarms | false | false | java.lang.String | Specify if the major alarm count should be displayed. Set to false to prevent display of minor alarm count and icon. |
minorAlarms | false | false | java.lang.String | Specifies if the minor alarm count should be displayed. Is false to prevent display of minor alarm count and icon. |
criticalIcon | false | false | java.lang.String | The key identifier for the theme image to use for the critical alarms icon. |
visible | false | false | java.lang.String | Indicates whether the component should be viewable by the user in the rendered HTML page. If false, the HTML code for the component is present in the page, but the component is hidden with style attributes. By default, this setting is true, so HTML for the component HTML is included and visible to the user. If the AlarmStatus component is not visible, it can still be processed on subsequent form submissions because the HTML is present. |
style | false | false | java.lang.String | CSS style or styles to be applied to the outermost HTML element when this component is rendered. |
downAlarms | false | false | java.lang.String | Specifies if the down alarm count should be displayed. Is false to prevent display of down alarm count and icon. |
numMinorAlarms | false | false | java.lang.String | The number of minor alarms that can be displayed next to the appropriate icon. |
downIcon | false | false | java.lang.String | The key identifier for the theme image to use for the down alarms icon. |
imageURL | false | false | java.lang.String | Absolute or relative URL to the image to be rendered. |
width | false | false | java.lang.String | Image width override. When specified, the width and height attributes tell user agents to override the natural image or object size in favor of these values. |
onKeyPress | false | false | java.lang.String | Scripting code executed when the user presses and releases a key while the component has focus. |
target | false | false | java.lang.String | The resource at the specified URL is displayed in the frame that is specified with the target attribute. Values such as "_blank" that are valid for the target attribute of a HTML anchor element are also valid for this attribute in this component |
onFocus | false | false | java.lang.String | Scripting code executed when this component receives focus. An element receives focus when the user selects the element by pressing the tab key or clicking the mouse. |
rendered | false | false | java.lang.String | Use the rendered attribute to indicate whether the HTML code for the component should be included in the rendered HTML page. If set to false, the rendered HTML page does not include the HTML for the component. If the component is not rendered, it is also not processed on any subsequent form submission. |
urlLang | false | false | java.lang.String | The language code of the resource designated by this hyperlink. |
id | false | true | java.lang.String | No Description |
onKeyUp | false | false | java.lang.String | Scripting code executed when the user releases a key while the component has focus. |
onMouseUp | false | false | java.lang.String | Scripting code executed when the user releases a mouse button while the mouse pointer is on the component. |
height | false | false | java.lang.String | When specified, the width and height attributes tell the client browser to override the natural image or object size in favor of these values, specified in pixels. Some browsers might not support this behavior. |
actionListenerExpression | false | false | java.lang.String | Use the actionListenerExpression attribute to cause the component to fire an event. The value must be an EL expression and it must evaluate to the name of a public method that takes an ActionEvent parameter and returns void. |
align | false | false | java.lang.String | Specifies the position of the image with respect to its context. Valid values are: bottom (the default); middle; top; left; right. |
vspace | false | false | java.lang.String | Specifies the amount of white space in pixels to be inserted above and below the image. The default value is not specified but is generally a small, non-zero size. |
border | false | false | java.lang.String | Specifies the width of the img border in pixels. The default value for this attribute depends on the client browser |
url | false | false | java.lang.String | Absolute, relative, or context relative (starting with "/") URL to the resource selected by this hyperlink. If the url attribute is specified, clicking this hyperlink sends the browser to the new location. If the action attribute is specified, the form is submitted. If both are specified, the url attribute takes precedence. |
onClick | false | false | java.lang.String | Scripting code executed when a mouse click occurs over this component. If the component submits the form (by using the action attribute), the script that you use with the onClick attribute should not return from the function. When the action attribute is used, the component handles the return with a script that is appended to the anchor element's onclick property. When you supply an onClick attribute, this return script is appended after your script in the anchor's onclick. It is ok to return from your script to abort the submit process if necessary. |
onBlur | false | false | java.lang.String | Scripting code executed when this element loses focus. |
onMouseDown | false | false | java.lang.String | Scripting code executed when the user presses a mouse button while the mouse pointer is on the component. |
toolTip | false | false | java.lang.String | Sets the value of the title attribute for the HTML element. The specified text will display as a tooltip if the mouse cursor hovers over the HTML element. |
type | false | false | java.lang.String | The MIME content type of the resource specified by this component. |
actionExpression | false | false | java.lang.String | MethodExpression representing the application action to invoke when this component is activated by the user. The expression must evaluate to a either a String or a public method that takes no parameters, and returns a String (the logical outcome) which is passed to the NavigationHandler for this application. |
disabled | false | false | java.lang.String | Flag indicating that clicking of this component by the user is not currently permitted. |
onMouseOut | false | false | java.lang.String | Scripting code executed when a mouse out movement occurs over this component. |
alt | false | false | java.lang.String | Alternative textual description of the image rendered by this component. The alt text can be used by screen readers and in tool tips, and when image display is turned off in the web browser. |
onMouseOver | false | false | java.lang.String | Scripting code executed when the user moves the mouse pointer into the boundary of this component. |
htmlTemplate | false | false | java.lang.String | Alternative HTML template to be used by this component. |
onMouseMove | false | false | java.lang.String | Scripting code executed when the user moves the mouse pointer while over the component. |
text | false | false | java.lang.String | The text to be displayed for the hyperlink. |
immediate | false | false | java.lang.String | Flag indicating that event handling for this component should be handled immediately (in Apply Request Values phase) rather than waiting until Invoke Application phase. |
hspace | false | false | java.lang.String | Specifies the amount of white space in pixels to be inserted to the left and right of the image. The default value is not specified but is generally a small, non-zero size. |
onKeyDown | false | false | java.lang.String | Scripting code executed when the user presses down on a key while the component has focus. |
tabIndex | false | false | java.lang.String | Position of this element in the tabbing order of the current document. Tabbing order determines the sequence in which elements receive focus when the tab key is pressed. The value must be an integer between 0 and 32767. |
Variables | No Variables Defined. |
| |||||||
FRAMES NO FRAMES |