tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bruno Salgueiro ...@sibs.pt>
Subject [Resending Again] Using a Java Bean inside a declaration
Date Mon, 22 May 2000 16:49:37 GMT
Hi everyone,

 In the JSP 1.1 spec it says that if you implement the
jspDestory()
method it should be called when the page is destroyed, if I'm not
mistaken (it is one of the API contracts). Can I use a declaration
to override it and close connections cleanly?
  I tried the following (which BTW may be very stupid but here it
goes):

  <jsp:useBean id="bdcon" class="bd.BDBean" scope="session">
  ...
  <%! public void jspDestroy() {
         bdcon.Disconnect();
      }
  %>

  Jasper complains loudly when it tries to compile the page
because he does not know what the object bdcon is.

  Can someone help me with this scope error?

Regards,
-- 
=======================================================
Bruno Salgueiro       (mailto:bs@sibs.pt)
                   
SIBS - Sociedade Interbancária de Serviços
Rua Soeiro Pereira Gomes, Lote 1, 1600 Lisboa, Portugal

Tel: + 351 21 791 88 33
Fax: + 351 21 794 24 40
http://www.sibs.pt

Esta mensagem foi assinada com certificado MULTIcert.
Para obter o certificado da Autoridade de Certificação
PILOTO MULTIcert dirija-se ao site
            http://www.sibs.multicert.com

"Computers are useless. They can only give you answers."
                                        --Pablo Picasso
=======================================================

Mime
View raw message