Scott Nichol wrote:

You do not send arbitrary binary data as XML.  XML is "readable", i.e.
it is character based.  The typical encoding used is utf-8, which would
not allow you to send arbitrary binary data.  It is typical to base64
encode binary data, which increases its size 33%.  Welcome to XML, which
you can generally assume will be the worst-case serialization method in
terms of size and speed.  For size and speed, you might just use the
serialization built into Java.

The MIMEPartSerializer is for attachments.  It will typically base64
encode binary data.  The attachments are not part of the XML itself, so
if you really want to carry XML payloads, you cannot use this.

Scott Nichol

Hello Scott,

thanks for your very quick response!

No problem! Our protocol supports raw binary transfers and all XML is automatically zipped. Thus, this will not really be a problem. I think, in this case, we will use our own mechanism for binaries and use XML-serialization only for "small" data (no blobs).

I found my way through Castor (at least most of it) and was able to serialize to a file and to deserialize from it. It worked!!! Thus, thanks again for this tip. This means, I could continue now on my main task, but I really would like to be able to support SOAP, too, if it is not too hard to do that.

Best regards, Marco ;-)



--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to