Return-Path: Delivered-To: apmail-jakarta-struts-user-archive@jakarta.apache.org Received: (qmail 37699 invoked by uid 500); 27 Jun 2001 15:02:36 -0000 Mailing-List: contact struts-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk Reply-To: struts-user@jakarta.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list struts-user@jakarta.apache.org Received: (qmail 37660 invoked from network); 27 Jun 2001 15:02:36 -0000 Received: from mail-gw.juniper.com (63.238.186.21) by h31.sny.collab.net with SMTP; 27 Jun 2001 15:02:36 -0000 Received: from server03.juniper.com (mail.juniper.com [10.0.16.45]) by mail-gw.juniper.com (8.11.1/8.11.1) with ESMTP id f5RExfR17552 for ; Wed, 27 Jun 2001 10:59:41 -0400 (EDT) Received: by mail.juniper.com with Internet Mail Service (5.5.2650.21) id ; Wed, 27 Jun 2001 11:01:53 -0400 Message-ID: <1174A74803FDD411B5B00002A51B9A152A6244@PRODEX02> From: "Bauer, John" To: "'struts-user@jakarta.apache.org'" Subject: taglib bean property problem? Date: Wed, 27 Jun 2001 11:01:52 -0400 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2650.21) Content-Type: text/plain; charset="iso-8859-1" X-Spam-Rating: h31.sny.collab.net 1.6.2 0/1000/N I have a class which has a Vector property I wish to iterate over. It appears the logic:iterate tag is not finding the property for the Vector, even though it is clearly present and validated through other means. The iterate tag works fine when I use the 'collection' attribute to explicitly set the collection. The 'property' attribute does not function and I get the error below. Is there anything I am doing wrong here, or is this a bug? Wed Jun 27 10:39:35 EDT 2001: Root cause of ServletException javax.servlet.jsp.JspException: No getter method for property statementListBlock of bean list at org.apache.struts.util.RequestUtils.lookup(RequestUtils.java, Compiled Code) at org.apache.struts.taglib.logic.IterateTag.doStartTag(IterateTag.java, Compiled Code) at jsp_servlet._strutstester._jspService(_strutstester.java, Compiled Code) at weblogic.servlet.jsp.JspBase.service(JspBase.java:27) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java :120) at weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp l.java:9 15) at weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp l.java:8 79) at weblogic.servlet.internal.ServletContextManager.invokeServlet(ServletContext Manager. java:269) at weblogic.socket.MuxableSocketHTTP.invokeServlet(MuxableSocketHTTP.java:365) at weblogic.socket.MuxableSocketHTTP.execute(MuxableSocketHTTP.java:253) Here is a sample web page and output showing the issue: web page: <%@ page import="com.juniper.bus.statement.xmlapi.*" %> <%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %> <%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %> <% { StatementList list1 = new StatementList(); StatementListBlock block = new StatementListBlock(); list1.addStatementListBlock(block); block.setAccountNumber("1234123412341234"); Status status = new Status(); status.setType("success"); status.setCode("code"); status.setMessage("message"); block.setStatus(status); block.setType("DDA"); StatementListItem item = new StatementListItem(); block.addStatementListItem(item); item.setStartDate("20010501"); item.setStatementDate("20010601"); pageContext.setAttribute("list", list1, PageContext.PAGE_SCOPE); } %> Struts Tester Test page

Class Name: <%= list.getClass() %>

Block Count (script): <%= list.getStatementListBlockCount() %>

Statement list block count (bean tag):

block (script w/toString): <%= list.getStatementListBlock().toString() %>>

block (script without toString): <%= list.getStatementListBlock() %>

block (class): <%= list.getStatementListBlock().getClass() %>

output: Test page Class Name: class com.juniper.bus.statement.xmlapi.StatementList Block Count (script): 1 Statement list block count (bean tag): 1 block (script w/toString): [com.juniper.bus.statement.xmlapi.StatementListBlock@52caa8ea]> block (script without toString): [com.juniper.bus.statement.xmlapi.StatementListBlock@52caa8ea] block (class): class java.util.Vector 1234123412341234 20010501 Error 500--Internal Server Error John Bauer Technology Director Juniper Bank PH: (302) 255-8240 jbauer@juniper.com _______________________________________________________ Juniper Bank "Rated #1 in Customer Confidence" Gomez Inc., Winter 2000 Internet Credit Card Scorecard www.Juniper.com _______________________________________________________ This e-mail and any files transmitted with it may contain confidential and/or proprietary information. It is intended solely for the use of the individual or entity who is the intended recipient. Unauthorized use of this information is prohibited. If you have received this in error, please contact the sender by replying to this message and delete this material from any system it may be on.