strut 1.2.7 and web.xml
Hi, I'm in process of upgrading of strut 1.0 to 1.2.7 but cannot start the app server because of this error. Is this the correct tld declaration for web.xml? http://java.sun.com/dtd/web-app_2_3.dtd'> -- Notice: This e-mail message, together with any attachments, contains information of Merck & Co., Inc. (One Merck Drive, Whitehouse Station, New Jersey, USA 08889), and/or its affiliates (which may be known outside the United States as Merck Frosst, Merck Sharp & Dohme or MSD and in Japan, as Banyu) that may be confidential, proprietary copyrighted and/or legally privileged. It is intended solely for the use of the individual or entity named on this message. If you are not the intended recipient, and have received this message in error, please notify us immediately by reply e-mail and then delete it from your system. -- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Iterate question
You can have nested iterate. I think you can do something like this ... From Subject In reply to messageId references Message Parent : -Original Message- From: Rutger Heijmerikx [mailto:[EMAIL PROTECTED] Sent: Thursday, March 31, 2005 9:47 AM To: user@struts.apache.org Subject: Iterate question Hi all, Maybe it's clear what my problem exactly is when i post the jsp contents and my question. JSP contents: <%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean"%> <%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic"%> <%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html"%> <%@ taglib uri="/WEB-INF/taglibs-string" prefix="str"%> test >From Subject In reply to messageId references Message Parent : Now, the problem is, that the bean property "parent" is a new bean itself. How can i iterate through this bean in the same jsp? Hopefully you understand my problem, if not i'll be glad to explain it better. Rutger - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Notice: This e-mail message, together with any attachments, contains information of Merck & Co., Inc. (One Merck Drive, Whitehouse Station, New Jersey, USA 08889), and/or its affiliates (which may be known outside the United States as Merck Frosst, Merck Sharp & Dohme or MSD and in Japan, as Banyu) that may be confidential, proprietary copyrighted and/or legally privileged. It is intended solely for the use of the individual or entity named on this message. If you are not the intended recipient, and have received this message in error, please notify us immediately by reply e-mail and then delete it from your system. -- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Use Indexed properties - Encounter IndexOutOfBound Exception
That's not it. I still get same error. I thought when the form is submitted, Strut will re-construct the collection of objects with values from the input form. Therefore, I don't have to specify the Collection/List size in the form bean constructor. -Original Message- From: Slattery, Tim - BLS [mailto:[EMAIL PROTECTED] Sent: Friday, March 25, 2005 12:11 PM To: 'Struts Users Mailing List' Subject: RE: Use Indexed properties - Encounter IndexOutOfBound Exception > I'm trying to use Strut indexed tag but keep getting > java.lang.IndexOutOfBoundsException: Index: -9. It > displays with correct values but when the form is submitted, > I got the error. Below is a snip of my code. Do you know > what's wrong with it? When you submit your form, the Struts controller finds what form bean is associated with it and constructs an instance of that form. It then starts assigning values to it, using the accessor methods. For indexed properties, it uses an accessor to retrieve a collection of objects, then gets the object indicated by the index from the collection, then uses an accessor method in that object to assign a value. And there's your problem. If your form bean's constructor doesn't create a collection with enough items in it, the struts controller will try to access a non-existent member of the collection at this point. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Notice: This e-mail message, together with any attachments, contains information of Merck & Co., Inc. (One Merck Drive, Whitehouse Station, New Jersey, USA 08889), and/or its affiliates (which may be known outside the United States as Merck Frosst, Merck Sharp & Dohme or MSD and in Japan, as Banyu) that may be confidential, proprietary copyrighted and/or legally privileged. It is intended solely for the use of the individual or entity named on this message. If you are not the intended recipient, and have received this message in error, please notify us immediately by reply e-mail and then delete it from your system. -- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Use Indexed properties - Encounter IndexOutOfBound Exception
Hello, I'm trying to use Strut indexed tag but keep getting java.lang.IndexOutOfBoundsException: Index: -9. It displays with correct values but when the form is submitted, I got the error. Below is a snip of my code. Do you know hat's wrong with it? JSP code: Form Code: List pools = new ArrayList(); public List getPools() { return this.pools; } public Pool getPools(int i) { return (Pool) this.pools.get(i); } public void setPools(List v) { this.pools = v; } public void setPools(int i, Pool v) { this.pools.set(i, v); } -- Notice: This e-mail message, together with any attachments, contains information of Merck & Co., Inc. (One Merck Drive, Whitehouse Station, New Jersey, USA 08889), and/or its affiliates (which may be known outside the United States as Merck Frosst, Merck Sharp & Dohme or MSD and in Japan, as Banyu) that may be confidential, proprietary copyrighted and/or legally privileged. It is intended solely for the use of the individual or entity named on this message. If you are not the intended recipient, and have received this message in error, please notify us immediately by reply e-mail and then delete it from your system. -- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Indexed property throws exception - HELP!
Hi, I encountered an index out of bound exception when using the indexed property. The problem I'm facing is that I can't debug this. The exception is not thrown either in the the form or the action. Do you know what cause this? <101017> <[ServletContext(id=4601745,name=scheduler,context-path=/scheduler)] Root cause of ServletException java.lang.IndexOutOfBoundsException: Index: 1, Size: 0 at java.util.ArrayList.RangeCheck(ArrayList.java:486) at java.util.ArrayList.get(ArrayList.java:302) at org.apache.commons.beanutils.PropertyUtils.getIndexedProperty(PropertyUtils. java:521) at org.apache.commons.beanutils.PropertyUtils.getIndexedProperty(PropertyUtils. java:428) at org.apache.commons.beanutils.PropertyUtils.getNestedProperty(PropertyUtils.j ava:770) at org.apache.commons.beanutils.PropertyUtils.getProperty(PropertyUtils.java:80 1) at org.apache.commons.beanutils.BeanUtils.setProperty(BeanUtils.java:881) at org.apache.commons.beanutils.BeanUtils.populate(BeanUtils.java:808) at org.apache.struts.util.RequestUtils.populate(RequestUtils.java:1096) at org.apache.struts.action.RequestProcessor.processPopulate(RequestProcessor.j ava:816) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:254) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1420) at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:520) at javax.servlet.http.HttpServlet.service(HttpServlet.java:760) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run(Servle tStubImpl.java:1058) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java :401) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java :306) at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(W ebAppServletContext.java:5445) at weblogic.security.service.SecurityServiceManager.runAs(SecurityServiceManage r.java:780) at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletCo ntext.java:3105) at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java :2588) at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:213) at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:189) > -- Notice: This e-mail message, together with any attachments, contains information of Merck & Co., Inc. (One Merck Drive, Whitehouse Station, New Jersey, USA 08889), and/or its affiliates (which may be known outside the United States as Merck Frosst, Merck Sharp & Dohme or MSD and in Japan, as Banyu) that may be confidential, proprietary copyrighted and/or legally privileged. It is intended solely for the use of the individual or entity named on this message. If you are not the intended recipient, and have received this message in error, please notify us immediately by reply e-mail and then delete it from your system. -- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]