commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ryan McGuinness" <>
Subject Re: questions
Date Tue, 08 Nov 2005 16:30:19 GMT

Basically if you want to add a property to the object simply do so in
standard bean fasion:

Qestions (Collection):
  pirvate String name;

  public void setName(String name) { ... }
  public String getName() { ... }

Then in your questions .betwixt file, you would simply add the following

   <element name='rq:questions'>
       <attribute name='name' property='name' />

I tried this on my demo project, and it worked fine.


> Hi Ryan,
> Thanks for your super-speedy response.  I think it will help me immensely
> (I am a complete betwixt newbie).
> I will try to cobble together a working example of the solution as you
> propose.
> If I succeed I will gladly update the Betwixt documentation (crediting you
> of course for the solution ;=)
> If I understand correctly you are mapping XML elements of type
> "questionGroup" to instances of the Java class "Questions".  I guess the
> system you modelled is bigger than what you have outlined so I am curious
> to know if the "Questions" class has to be just a simple collection as you
> show or if it possible for this class to also contain more properties?
> If it can't store more properties then it is not a big problem - I can use
> the collection to store the hierarchy and use a simple list elsewhere to
> store the remaining attributes.
> If you can easily send me more details then great otherwise no problem and
> thanks again for helping.
> ciao,
> Richard SULLIVAN (based in Brussels, Belgium)
> ______________________________________________________________
> Verschicken Sie romantische, coole und witzige Bilder per SMS!
> Jetzt bei WEB.DE FreeMail:

-- "Imagination is more important than knowledge" - Albert Einstein.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message