On Tue, 2011-06-07 at 09:06 +0200, joh sar..... wrote: > Hi ! > > I'm writing because I didn't find how i can change the type of content > Transfer Encoding in a multipart message that i send with a HTTP Post > request . > > For this, i use the library httpmime-4.1.1.jar from: > http://hc.apache.org/htppcomponents-client/httpmime/index.html. > > In my project, i try to send a base64 JPG but for the moment i have > just send a binary JPEG and my hope is so with a base64. > > Does anyone know how change this content transfer type or help me ? it > will be very helpful. > > I have tried with an instance of FileBody but it was a flop... and i > have read the code but i found nothing. > > Thanks > johan S. > > PS: If I find before, i will write you and sorry for my english ! >
HttpMime supports the binary (identity) transfer encoding only. If you need to support more complex transfer encodings there is no way around having to build custom ContentBody implementations. You might want to do that using Apache Mime4j that supports all standard MIME codecs such as BASE64 and Quoted-Printable out of the box. Oleg --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
