Return-Path: Delivered-To: apmail-jakarta-commons-user-archive@www.apache.org Received: (qmail 58248 invoked from network); 5 Sep 2005 09:56:48 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 5 Sep 2005 09:56:48 -0000 Received: (qmail 86162 invoked by uid 500); 5 Sep 2005 09:56:40 -0000 Delivered-To: apmail-jakarta-commons-user-archive@jakarta.apache.org Received: (qmail 86094 invoked by uid 500); 5 Sep 2005 09:56:39 -0000 Mailing-List: contact commons-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: 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 86039 invoked by uid 99); 5 Sep 2005 09:56:38 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 05 Sep 2005 02:56:38 -0700 X-ASF-Spam-Status: No, hits=0.4 required=10.0 tests=SPF_HELO_FAIL X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [158.227.67.106] (HELO bipt106.bi.ehu.es) (158.227.67.106) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 05 Sep 2005 02:56:46 -0700 Received: from [158.227.75.43] (helo=[192.168.1.43]) by bipt106.bi.ehu.es with esmtp (Exim 3.35 #1 (Debian)) id 1ECDiH-0000Q8-00 for ; Mon, 05 Sep 2005 11:56:29 +0200 Message-ID: <431C1653.5090603@aintel.bi.ehu.es> Date: Mon, 05 Sep 2005 11:56:35 +0200 From: Rodrigo Partearroyo User-Agent: Mozilla Thunderbird 1.0.2 (Windows/20050317) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Jakarta Commons Users List Subject: Re: [Betwixt] Customizing Vector binding with dot betwixt file References: <42E663EE.4030804@aintel.bi.ehu.es> <1122842227.26558.46.camel@knossos.elmet> In-Reply-To: <1122842227.26558.46.camel@knossos.elmet> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Thank for your response Robert, i�ve been on vacations till today. I'll try your solution. robert burrell donkin wrote: > On Tue, 2005-07-26 at 18:25 +0200, Rodrigo Partearroyo wrote: > >>I�m trying to serialize a Vector of Strings. They are the security-roles >>allowed to access some part of my webapp. The output i need is this: >> >> >> >> >> >> >> >> >>but all i can obtain is this: >> >> >> >> >> >>The bean i'm using is : >> >>public class SecurityRolesBean { >> private Vector rolesList; >> public SecurityRolesBean (){ >> rolesList = new Vector(); >> } >> public Vector getRolesList(){ >> return rolesList; >> } >> public void setServiceRole(String role){ >> setRolesList(role); >> } >> private void setRolesList(String rol){ >> rolesList.addElement(rol); >> } >>} >> >>and the dot betwixt file: >> >> >> >> >> >> >> >> >> >> >>The question is: How can i put each of the Vector's elements (which are >>Strings) in separate xml elements? > > > that 'attribute' tag needs to be an 'element' tag > > > > > > > > > > >>The inverse step (populating the Bean with data read from a xml file) is >>done with Digester following this rule: >> >>[...] >> >> >> >> >> >>[...] >> >>Due to Digester cannot perform the inverse operation (writting beans to >>xml files) i�m trying to move it to Betwixt, but the xml format cannot >>change. > > > betwixt should handle this pretty easily. you'll need to add the name of > the adder to be used to the dot betwixt file > > > > > > > > > > > please take a look at the documentation > (http://jakarta.apache.org/commons/betwixt) for more details. > > - robert > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org > For additional commands, e-mail: commons-user-help@jakarta.apache.org > -- Rodrigo Partearroyo Gonz�lez --------------------------------------------------------------------- To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: commons-user-help@jakarta.apache.org