Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

Web developers tend to spend a lot of time tinkering with how data is input into an application. This only makes sense — after all, garbage in, garbage out — right?

0
Posted

Web developers tend to spend a lot of time tinkering with how data is input into an application. This only makes sense — after all, garbage in, garbage out — right?

0

Absolutely! There is nothing more important then getting correct input from a user. Much of the Struts framework centers on gathering and validating input. But that’s no reason to give output the short-shift. Presenting our hard-won data back to the user can be just as important as gathering it in the first place. Most presentation components, like JSP tags and Velocity templates, are quite adept at rendering data from objects in a servlet context. So much so, that many developers just tuck their data into one of the standard Collection classes and leave the rest to the presentation layer. While this works, using a specialized result object works even better. A result object is simply a transfer object equipped with methods designed to give the presentation layer a helping hand. Most often these are very simple methods, like a helper to return the size of the collection as a standard JavaBean accessor. Other common helpers could include a function to render text in all upper case, a fu

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123