Hi,
i want to create an image resource by uploading an image and setting
some informations for this image.
The following is a possible POST body:
Content-type: multipart/form-data, boundary=AaB03x
--AaB03x
content-disposition: form-data; name="field1"
Joe Blow
--AaB03x
content-disposition: form-data; name="pics"; filename="file1.txt"
Content-Type: text/plain
... contents of file1.txt ...
--AaB03x--
I tried to use the following code:
@POST
public Response createGraphic ( @FormParam( "field1" ) String name,
@FormParam( "pics" ) Object object ) {
...
}
But this approach didn't work fine.
How can I fetch the parameters (in this example: field1) and the file?
Greetings
Max