I'm using Apache HTTPClient 4. I'm doing very normal multipart that:
val entity = new MultipartEntity(HttpMultipartMode.BROWSER_COMPATIBLE); entity.addPart("filename", new FileBody(new File(fileName), "application/zip").asInstanceOf[ContentBody]) entity.addPart("shared", new StringBody(sharedValue, "text/plain", Charset.forName("UTF-8"))); val post = new HttpPost(uploadUrl); post.setEntity(entity);
I wish to begin to see the items in the entity (or publish, whatever) before I send it. However, that technique is not implemented:
entity.getContent() // not defined for MultipartEntity
How do i see things i am posting?
Would you not be aware of content? Although, you're building the
StringBody by delivering
sharedValue. So, how can it be diverse from