Creating a page-level ErrorBuffer JavaBean

A

Andy

Hi all,

First off, I'm a newbie, so please move along if you don't like
helping people get to grips with stuff :)

Basically, I'm trying to work out how to create a bean that would
buffer errors (not compilation/runtime Java errors, but business logic
errors eg "Password too short"), which would be instantiated at the
top of each JSP with a scope of "page", and which all actions
performed in the page can add to. The problem is, a lot of the actual
functionality in the pages is going to be carried out by worker
classes, rather than in Java within the actual JSP page. So, the
question is how do I access a page-level bean from the individual
classes (and possibly classes instantiated within those classes, ad
infinitum)?

I think this might be something to do with contexts, but I can't work
out how they'd get accessed by the worker classes. Would I have to
pass a context object to every single class?

Thanks for any pointers you can give me!

Andy
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,995
Messages
2,570,233
Members
46,820
Latest member
GilbertoA5

Latest Threads

Top