Json pass binary

If you want to pass the binary data (array) read from the server to the client in Json format, I don't know how people generally deal with this situation. I used a dirty method to format binary data into the character form of two hexadecimal numbers: such as (C++ code): for(int i=0;i sprintf(temp,"%2x",bintemp[i] ) ; // char temp[4]; str.insert(temp,2*i);   

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325376295&siteId=291194637