View Single Post
Join Date: Sep 2008
Posts: 2
Reputation: afolli is an unknown quantity at this point 
Solved Threads: 0
afolli afolli is offline Offline
Newbie Poster

Re: Include Base64 encoded data into XML

 
0
  #3
Sep 16th, 2008
In fact I'm encoding binary data. Actually, I have changed it in the following way.

  1. import com.sun.xml.rpc.encoding.simpletype.XSDBase64BinaryEncoder;
  2. ...
  3. OMElement part = factory.createOMElement("part", emptyNs);
  4. part.addAttribute("length", "" + this.attachment.getLength() + "",null);
  5. part.setText(XSDBase64BinaryEncoder.getInstance().objectToString( this.attachment.get_value() , null ));

Alessandro
Reply With Quote