this.body = body;
return body;
}
public MultipartBody fields(Map<String, Object> parameters) {
MultipartBody body = new MultipartBody(this);
if (parameters != null) {
for(Entry<String, Object> param : parameters.entrySet()) {
if (param.getValue() instanceof File) {
body.field(param.getKey(), (File)param.getValue());
} else {
body.field(param.getKey(), (param.getValue() == null) ? "" : param.getValue().toString());
}
}
}
this.body = body;
return body;