Return-Path: Delivered-To: apmail-jakarta-commons-user-archive@www.apache.org Received: (qmail 22970 invoked from network); 13 Jan 2005 19:17:08 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 13 Jan 2005 19:17:08 -0000 Received: (qmail 22986 invoked by uid 500); 13 Jan 2005 19:17:03 -0000 Delivered-To: apmail-jakarta-commons-user-archive@jakarta.apache.org Received: (qmail 22924 invoked by uid 500); 13 Jan 2005 19:17:03 -0000 Mailing-List: contact commons-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Jakarta Commons Users List" Reply-To: "Jakarta Commons Users List" Delivered-To: mailing list commons-user@jakarta.apache.org Received: (qmail 22909 invoked by uid 99); 13 Jan 2005 19:17:03 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy) Received: from mail.auto-trol.com (HELO is3.auto-trol.com) (143.198.15.20) by apache.org (qpsmtpd/0.28) with ESMTP; Thu, 13 Jan 2005 11:17:01 -0800 Received: from endeavor.houdev.auto-trol.com ([143.198.5.23]) by is3.auto-trol.com with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2653.13) id CJYVLL3Z; Thu, 13 Jan 2005 12:16:59 -0700 Received: by endeavor.houdev.auto-trol.com with Internet Mail Service (5.5.2653.19) id ; Thu, 13 Jan 2005 13:22:06 -0600 Message-ID: <510A660320ABD61183BB00A0247D7C87010A949B@endeavor.houdev.auto-trol.com> From: Jason Wood To: 'Jakarta Commons Users List' Subject: RE: [betwixt] Collection property question Date: Thu, 13 Jan 2005 13:22:00 -0600 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain; charset="iso-8859-1" X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N I think you want this ... IntrospectionConfiguration.setWrapCollectionsInElement(false) Jason -----Original Message----- From: Matt Goodwin [mailto:mgoodwin@metalexis.com] Sent: Thursday, January 13, 2005 11:02 AM To: Jakarta Commons Users List Subject: [betwixt] Collection property question I have xml I need to map to my bean. It is very similar to the CustomerBean example, except I am using Collection instead of and array of objects (i.e. Order[]). Here is a sample of the xml, followed by my class, followed by my .betwixt file. The problem I am having is the List is always null. How do you map objects in the .betwixt file if the collection has no surrounding element tag (i.e. )? Example xml: 2004/10/08 ... ... ... ... Class: public class AgentStatement implements java.io.Serializable { private Date statementDate; private AgentInfo agentInfo; private Collection agentStatementDetails = new java.util.ArrayList(); private AgentEarning agentEarning; /* .. snip non-relevant getters/setters */ public Collection getAgentStatementDetails() { return agentStatementDetails; } public void setAgentStatementDetails(Collection agentStatementDetails) { this.agentStatementDetails = agentStatementDetails; } public void addAgentStatementDetail(AgentStatementDetail agentStatementDetail) { this.agentStatementDetails.add(agentStatementDetail); } } Betwixt file: Everything except the agentStatementDetails are populated correctly. Thanks, Matt -- Matt Goodwin mgoodwin@metalexis.com (515)708-0114 Metalexis "Transcending the Ordinary" --------------------------------------------------------------------- To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: commons-user-help@jakarta.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: commons-user-help@jakarta.apache.org