how to convert binary data into jpg image through java. I have xml file which contain <Binary> element in which binary data of image is fill and through java swing we have to read it and display image in JFrame.
However XML is a text format that does not permit arbitrary binary data, so if it contains bytes to make a JPG then those bytes must have been encoded in some way. You will have to decode them in the corresponding way, whatever that is. It is common to use Base64 encoding to put binary data into XML but that does not mean your binary data was encoded that way.