alt
Sponsored links
Online Training
Career Series
Exforsys
Exforsys arrow Tech Articles arrow Jakarta Struts arrow Handling Messages, Errors and Exceptions in Struts 1.1
Site Search


Handling Messages, Errors and Exceptions in Struts 1.1

This article is about Jakarta Struts 1.1, the most popular framework for building Java servlet applications. One of the new, useful features in 1.1 is the possibility to specify exception handling in the Struts config file. It's called "declarative exception handling", and it's one of the topics for this article.

You use exceptions when the application has encountered a serious error. The error could be an SQL statement that fails, or a connection to another computer that couldn't be established. As a programmer, you should first of all record the situation as precisely as you can. For example, writing information to a log file. You might also have to fix up a few things to keep the program state stable, but eventually you'll also have to inform the user of the situation. So to move forward, one issue in exception handling is how to handle messages, and I'll therefore start by explaining how you generally should handle messages for the end user in Struts. A special class of messages are "validation messages", which are sent out as the result of the validation of a form.

Click here for the article.


Trackback(0)
Comments (0)add comment

Write comment

busy
 
< Prev   Next >
Exforsys Offers
© 2008 Exforsys.com
Joomla! is Free Software released under the GNU/GPL License.
Page copy protected against web site content infringement by Copyscape