The Message Group component provides a way to show a list of global messages
for a page, such as system runtime errors, or a list of messages related to components. To show individual component errors, such as
validation and conversion errors, clear
the showGlobalOnly property in the Message Group Properties Window.
This component is a JavaServer Faces 1.2 component. You see components that use this
version of JavaServer Faces when your project uses Java EE 5. For more information on JavaServer Faces 1.2,
see:
The two message components, Message Group and Message,
display error messages concerning component rendering and validation.
This component, Message Group, reports either global errors only or all errors on all
components on the page, including errors with the page itself.
You can put a Message Group component on your page to assist
with debugging as you are developing the page.
The Message component
reports errors for a single component. Use Message
if you want to provide your users with messages related to a specific component, like validation errors when they enter invalid data in a field. Message Group also reports validation errors, but it reports them for all components, not just one.
To write your own text to this component, call info(String summary), warn(String summary), error(String summary), or fatal(String summary). The web application applies different styles to the text, depending on the method's severity level.
To write both a summary message and a detail message, use FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(summary, detail)) or ValidatorException(new FacesMessage(severity, summary, detail)).
You must set the component's showDetail property for detail messages to appear.