Re: How to insert a new child under an XML element that has no child (simple (stupid) XmlCursor question)

2008-03-12 Thread Radu Preotiuc-Pietro
Think about the XmlCursor as a cursor in a text editor. If the cursor is on the startelement of , what you insert comes right before b, if you want to insert something right before the endelement of do cursor.toEndToken() before doing cursor.beginElement(). You may also want to look at cursor.inse

Re: How to remove an object

2008-03-12 Thread Radu Preotiuc-Pietro
If the element has minOccurs="0" in the Schema, you should see a method like: businessDescription.unsetBS7666Coordinate() If your minOccurs is 1, then you can still remove it, but you will need to use XmlCursor to do that. Anyway, IMO is better to change the existing element to what you want it t

Re: found bug minOccures=0 ignored for xs:any

2008-03-12 Thread Radu Preotiuc-Pietro
In this case, I am afraid I am not very familiar with how Axis2 packages XmlBeans, but it does sound surprising that they would change the result of compilation in this way. You are going to have to bring this up on Axis' mailing list. Radu On Wed, 2008-03-12 at 19:18 +0100, Stefan Lischke wrote:

Re: Set value of ComplexType

2008-03-12 Thread Radu Preotiuc-Pietro
It's too bad you consider it a hack. For mixed content at least, it is a good approach (alternatively, you can use DOM for this purpose). See sample/MixedContent, which is the recommended way of doing it. How else would you deal with being able to control where does your text get added in relation

Re: found bug minOccures=0 ignored for xs:any

2008-03-12 Thread Stefan Lischke
Hi, I found out, that it works great if i compile the beans with XMLBeans 2.3.0 only. But when i use Axis2 with XMLBeans the validation fails. I even tried the xmlbeans version that is deliverd with Axis2 with the xmlbeans generated classes and it validates fine. It must be something at the bean g

RE: [is this a bug?] Re: xs:string - Isn't whitespaces preserved by default?

2008-03-12 Thread Wing Yew Poon
Well, that's a crucial piece of information that you left out of your original question - you were using xmlText(XmlOptions), not xmlText() - and that's why you led others on a wild goose chase. This is NOT a bug then. Pretty print by its nature (by design) does not preserve whitespace. If you need

Scientific notation decimal type

2008-03-12 Thread Joe White
I have a very simple schema that I would like to return a price from (below). However when I generate output the prices are returned in scientific notation. Is there a way to suppress the scientific notation output? Thank you for your help Joe http://www.w3.org/2001/XMLSchema";

XMLBEANS 2.3.0 and CDATA issue

2008-03-12 Thread Alex Florentino
I am using the xmlbeans 2.3.0 I have a document that have another xml document sample: the problem is that xmlbeans put this xml content(CONFIRMMESSAGE) how cdata content, and my third-partner don't is be able handler it. I need that xmlbeans don't put the content as CDATA . I already