You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@commons.apache.org by denis queffeulou <de...@wokup.com> on 2006/04/07 14:12:55 UTC
[betwixt] attributes inside list items
Hi ,
I'm using a bean that contains a list of String (items) and a
getMessageId() method.
I have the following betwixt:
<element name="list">
<element name="item" property="items">
<attribute name="attr1" value=""/>
<attribute name="attr2" property="messageId"/>
</element>
</element>
and I hope get the following XML :
<list>
<item attr1="" attr2="somevalue of main bean"/>
<item attr1="" attr2="somevalue of main bean"/>
...
</list>
but I got:
<list>
<item>some value</item>
<item>some value</item>
...
</list>
It seems that attributes are not processed ??
anyone knows why ?
--
Denis
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org
Re: [betwixt] attributes inside list items
Posted by Mornak <dm...@gmail.com>.
I think it is the same problem that I answer a minute ago in this list
i am copying the message
From: Mornak <dm...@gmail.com>
Date: Apr 7, 2006 5:40 PM
Subject: Re: [betwixt] attributes disables a element ?
To: Jakarta Commons Users List <co...@jakarta.apache.org>
You are right! the attribute disbles the content
If you want to read both of them you youl use the tag text
Something like this
<element name="list">
<element name="id">
<attribute name="recipient" property="recipient"/>
<text property="id" />
</element>
</element>
When i tried this with the 0.7 release it didn't work. I got a
nightbuild and it worked fine
I hope this will help you
PD: excuse my terrible english
On 4/7/06, denis queffeulou <de...@wokup.com> wrote:
> Hi,
>
> I have the following betwixt :
>
> <element name="list">
> <element name="id" property="id"/>
> <!--
> <attribute name="recipient"
> property="recipient"/>
> </element>
> -->
> </element>
>
> With comment, I can retrieve the id property from XML,
> but if I add the attribute "recipient", then I get a *null* "id" and a
> good "recipient".
>
> The XML is
> <list>
> <id recipient="089786756">8090</id>
> </list>
>
>
> I don't undertsand why this doesn't work with the attribute ??
> --
> Denis
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
>
On 4/7/06, denis queffeulou <de...@wokup.com> wrote:
> Hi ,
>
> I'm using a bean that contains a list of String (items) and a
> getMessageId() method.
> I have the following betwixt:
>
> <element name="list">
> <element name="item" property="items">
> <attribute name="attr1" value=""/>
> <attribute name="attr2" property="messageId"/>
> </element>
> </element>
>
> and I hope get the following XML :
>
> <list>
> <item attr1="" attr2="somevalue of main bean"/>
> <item attr1="" attr2="somevalue of main bean"/>
> ...
> </list>
>
> but I got:
> <list>
> <item>some value</item>
> <item>some value</item>
> ...
> </list>
>
> It seems that attributes are not processed ??
>
> anyone knows why ?
> --
> Denis
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
>
--
To Iterate is Human, to Recurse, Divine
- James O. Coplien, Bell Labs
-------------------------------------
<EPI/> - Deploying ideas
-------------------------------------
Ing. Diego H. Mornacco
Desarrollador
Epidata Consulting
Maipú 521 1er piso Of. A
Ofi: 5031 0060 / 61
Cel: 15-5884-0040
www.epidataconsulting.com
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org
Re: [betwixt] attributes disables a element ?
Posted by denis queffeulou <de...@wokup.com>.
thanks for help,
I tried it but I ran into other problems
Actually I found too much strange thing in betwixt so I moved to jibx
which works well for my needs.
--
Denis
>You are right! the attribute disbles the content
>
>If you want to read both of them you youl use the tag text
>
>Something like this
><element name="list">
> <element name="id">
> <attribute name="recipient" property="recipient"/>
> <text property="id" />
> </element>
></element>
>
>When i tried this with the 0.7 release it didn't work. I got a
>nightbuild and it worked fine
>
>I hope this will help you
>
>PD: excuse my terrible english
>
>
>
>
>On 4/7/06, denis queffeulou <de...@wokup.com> wrote:
>
>
>>Hi,
>>
>>I have the following betwixt :
>>
>> <element name="list">
>> <element name="id" property="id"/>
>> <!--
>> <attribute name="recipient"
>>property="recipient"/>
>> </element>
>> -->
>> </element>
>>
>>With comment, I can retrieve the id property from XML,
>>but if I add the attribute "recipient", then I get a *null* "id" and a
>>good "recipient".
>>
>>The XML is
>> <list>
>> <id recipient="089786756">8090</id>
>> </list>
>>
>>
>>I don't undertsand why this doesn't work with the attribute ??
>>--
>>Denis
>>
>>
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
>>For additional commands, e-mail: commons-user-help@jakarta.apache.org
>>
>>
>>
>>
>
>
>--
>
>To Iterate is Human, to Recurse, Divine
> - James O. Coplien, Bell Labs
>
>-------------------------------------
><EPI/> - Deploying ideas
>-------------------------------------
>Ing. Diego H. Mornacco
>Desarrollador
>Epidata Consulting
>Maipú 521 1er piso Of. A
>Ofi: 5031 0060 / 61
>Cel: 15-5884-0040
>www.epidataconsulting.com
>
>---------------------------------------------------------------------
>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
Re: [betwixt] attributes disables a element ?
Posted by Mornak <dm...@gmail.com>.
You are right! the attribute disbles the content
If you want to read both of them you youl use the tag text
Something like this
<element name="list">
<element name="id">
<attribute name="recipient" property="recipient"/>
<text property="id" />
</element>
</element>
When i tried this with the 0.7 release it didn't work. I got a
nightbuild and it worked fine
I hope this will help you
PD: excuse my terrible english
On 4/7/06, denis queffeulou <de...@wokup.com> wrote:
> Hi,
>
> I have the following betwixt :
>
> <element name="list">
> <element name="id" property="id"/>
> <!--
> <attribute name="recipient"
> property="recipient"/>
> </element>
> -->
> </element>
>
> With comment, I can retrieve the id property from XML,
> but if I add the attribute "recipient", then I get a *null* "id" and a
> good "recipient".
>
> The XML is
> <list>
> <id recipient="089786756">8090</id>
> </list>
>
>
> I don't undertsand why this doesn't work with the attribute ??
> --
> Denis
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
>
--
To Iterate is Human, to Recurse, Divine
- James O. Coplien, Bell Labs
-------------------------------------
<EPI/> - Deploying ideas
-------------------------------------
Ing. Diego H. Mornacco
Desarrollador
Epidata Consulting
Maipú 521 1er piso Of. A
Ofi: 5031 0060 / 61
Cel: 15-5884-0040
www.epidataconsulting.com
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org
[betwixt] attributes disables a element ?
Posted by denis queffeulou <de...@wokup.com>.
Hi,
I have the following betwixt :
<element name="list">
<element name="id" property="id"/>
<!--
<attribute name="recipient"
property="recipient"/>
</element>
-->
</element>
With comment, I can retrieve the id property from XML,
but if I add the attribute "recipient", then I get a *null* "id" and a
good "recipient".
The XML is
<list>
<id recipient="089786756">8090</id>
</list>
I don't undertsand why this doesn't work with the attribute ??
--
Denis
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org