Great. Thank you for the link. After Brett's comments, I created a JIRA issue: http://jira.codehaus.org/browse/MODELLO-118
-Nate On Fri, 5 Sep 2008 22:01:00 +0200, Hervé BOUTEMY <[EMAIL PROTECTED]> wrote: > see http://xircles.codehaus.org/projects/modello/lists > > regards, > > Hervé > > Le vendredi 05 septembre 2008, [EMAIL PROTECTED] a écrit : >> Which list would be more appropriate to post? I have some more question >> about how Modello is working, but I want to post to the correct list. >> >> Thanks, >> -Nate >> >> >> On Fri, 5 Sep 2008 20:16:00 +1000, "Brett Porter" > <[EMAIL PROTECTED]> >> >> wrote: >> > this is a bit OT for this list... but the reason it is occurring is >> >> because >> >> > it doesn't populate if it is the default value. Not sure if there's a > way >> > to >> > force that (other than changing the default). >> > - Brett >> > >> > 2008/9/5 <[EMAIL PROTECTED]> >> > >> >> Hello, >> >> >> >> I have created a .mdo with a required int attribute of "count", and I >> > >> > built >> > >> >> with the goals "java" and "xpp3-writer". >> >> >> >> Here is the snippet from my .mdo file for the attribute. >> >> >> >> <field xml.attribute="true"> >> >> <version>1.0.0</version> >> >> <name>count</name> >> >> <required>true</required> >> >> <type>int</type> >> >> </field> >> >> >> >> The java objects are all created correctly; however, if I put a zero >> > >> > into >> > >> >> the count field, it is not outputted in the >> >> XML. It does output if I use a non-zero value. I can see in the >> > >> > generated >> > >> >> file OutputXpp3Writer.java that it is checking for zero before it > writes >> >> the attribute. I assume this is done to determine if a value has > been >> >> written into that field. >> >> >> >> if ( tag.getCount() != 0 ) >> >> { >> >> ... output attribute ... >> >> } >> >> >> >> >> >> Is there something else I should put in the .mdo to force this > attribute >> > >> > to >> > >> >> write each time? I have put in a temporary hack of making that >> > >> > attribute a >> > >> >> String and used Integer.toString(...) in my code, but I don't think > this >> > >> > is >> > >> >> a good long term solution as the XML schema would be incorrect. Is >> > >> > there a >> > >> >> better work around? >> >> >> >> Thanks, >> >> -Nate >> >> >> >> >> >> --------------------------------------------------------------------- >> >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> >> For additional commands, e-mail: [EMAIL PROTECTED] >> > >> > -- >> > Brett Porter >> > Blog: http://blogs.exist.com/bporter/ >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
