"Joseph B. Ottinger" wrote:
>
> On Thu, 30 Mar 2000, Glenn Nielsen wrote:
>
> > But we have not found a way yet to pass an object from one bean to
> > another.  For example, say they use one bean that performs a query
> > of a database to generate a Vector containing a result set.  And
> > need to pass that Vector object on to another bean that formats the
> > result set into an HTML table.
> >
> > We could package everything into one bean, but then that defeats
> > the component nature of using beans.
>
> Sure. You've got a couple of options. One is to store beans in the page or
> session contexts, and provide references to the beans around (or use
> naming conventions.)
>

Exactly how would you do that?

Beans will already be stored in the appropriate context by the JSP Factory.
When you write and compile the bean, everything it needs has to be encapsulated
within it.  How do you get access to the PageContext, HttpSession, etc. objects
so that you can do a getAttribute("bean_id")?

Glenn

----------------------------------------------------------------------
Glenn Nielsen             [EMAIL PROTECTED] | /* Spelin donut madder    |
MOREnet System Programming               |  * if iz ina coment.      |
Missouri Research and Education Network  |  */                       |
----------------------------------------------------------------------

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to