Programming Jakarta Struts, 2nd Edition [Electronic resources] نسخه متنی

اینجــــا یک کتابخانه دیجیتالی است

با بیش از 100000 منبع الکترونیکی رایگان به زبان فارسی ، عربی و انگلیسی

Programming Jakarta Struts, 2nd Edition [Electronic resources] - نسخه متنی

Chuck Cavaness

| نمايش فراداده ، افزودن یک نقد و بررسی
افزودن به کتابخانه شخصی
ارسال به دوستان
جستجو در متن کتاب
بیشتر
تنظیمات قلم

فونت

اندازه قلم

+ - پیش فرض

حالت نمایش

روز نیمروز شب
جستجو در لغت نامه
بیشتر
لیست موضوعات
توضیحات
افزودن یادداشت جدید








Chapter 10. Exception Handling


Throwing exceptions is
Java's way of informing dependent clients that
something abnormal occurred during the processing of a method. The
client is notified of the type of problem by an instance of a
specific exception being thrown, and it's entirely
up to the client what course of action to take when an exception
occurs. In some cases, the client may even choose not to take any
action, which causes the JVM to continue to search for a handler for
the exception.

Handling exceptions within your Struts applications is not much
different. When an abnormal condition occurs, an exception is thrown
to the calling client to notify it of the abnormality. What is
different for web applications, and specifically the Struts
framework, is what action is taken on behalf of the client and how
these exceptions are reported back to the end user.

This chapter looks at how you can properly use the Java
exception-handling mechanism within your Struts applications to help
make your applications more robust and allow them to gracefully
respond when things do not go as expected. Special attention is given
to the differences between performing the exception handling
programmatically and using the new declarative feature added to the
Struts framework in Version 1.1.


    / 181