Apache Jakarta and Beyond: A Java Programmeramp;#039;s Introduction [Electronic resources] نسخه متنی

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

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

Apache Jakarta and Beyond: A Java Programmeramp;#039;s Introduction [Electronic resources] - نسخه متنی

Larne Pekowsky

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

فونت

اندازه قلم

+ - پیش فرض

حالت نمایش

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







19.6. The Pros and Cons of Struts


It should be clear at this point that struts provides a very clean, very sharp distinction between model, view, and controller. It also simplifies some aspects of creating the view by communicating problems to the user in a flexible way and maintaining valid inputs as errors are corrected. These are undeniably good things.

However, these benefits are not without their costs. It is also clear that using struts adds a great deal of overhead. Creating a new form requires creation of at least an action handler, plus possibly a form bean, plus several entries in several different files. On sites with many forms the configuration files may become overwhelming.

In the process of adding a new page and fine-tuning the entries in the XML file it is likely that Tomcat, or at least the particular Web application, will need to be restarted several times. This may take only thirty seconds each time, but those delays quickly add up.

It must also be said that struts's error reporting leaves a very great deal to be desired. Any mistake in the configuration, including mistyping the location of the application or config files, omitting the load-on-startup flag or any syntactic errors will result in the utterly unhelpful error message "Cannot find Action-Mappings or ActionFormBeans collection." There is no way to narrow down what

/ 207