if (params != null) {
for (Entry<String, String> entry : params.entrySet()) {
filePost.addParameter(entry.getKey(), entry.getValue());
}
}
filePost.setRequestEntity(new MultipartRequestEntity(parts, filePost.getParams()));
InputStream in = null;
try {
int res = client.executeMethod(filePost);
Utils.processResultCode(res, url);