Kevin,

Have you seen this class:

http://www.docjar.com/html/api/org/apache/commons/fileupload/MultipartStream.java.html

I *think* its only dependencies are Java.io.* classes, and (in the current version) a couple of small utility classes.

-- Kostya

20.12.2010 20:52, Kevin Tambascio пишет:
Hi,

I'm playing around with writing a web service that runs on Android
that handles uploading photos.  I am only writing the server, and do
not have any control over the client.

Inside of the message is a small SOAP message, and then the binary
data.  I am trying to figure out if there's a library that can do the
parsing of the two pieces.  Apache Commons FileUpload looked like the
obvious choice, however, it seems to be heavily intertwined with
servlet libraries, and I don't know if it's possible (or if it's a
good idea) to put too much J2EE infrastructure on a phone.

Parsing it myself doesn't seem too bad.  I'm not too familiar with the
raw HTTP layers/protocol, but it looks like the the boundary delimiter
string is given in the content type header.  If I find and index past
those, I should be able to find the two halves of the multi-part
message that I need to deal with.  At least that's what I seem to
think after looking at a wireshark trace of the client talking to the
real server.

Any thoughts would be appreciated.

-Kevin



--
Kostya Vasilyev -- WiFi Manager + pretty widget -- http://kmansoft.wordpress.com

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to