I need to return an object with byte[] . My return object looks like this :
class FileInfo {
String name;
byte[] fileContent;
boolean signRequired;
}
I need to return this object through a rest call. MediaType octet_stream is not suitable since my object FileInfo has both byte[] and other params. I would not want byte[] to be encoded to Base64 as it requires more work . Is there any other way to achieve this ? I saw references to mutipart data . But was not sure how to accomplish this
Thanks