Base64 encoding in Java.
I want to read in the raw data from an image file, encode it using Base64, and save into an XML file. I'm pretty sure reading it in will just be a stream of some kind, and I already have methods for saving into XML format, but where I'm stuck is how to actually perform the base64 encoding. I googled it and found some possible methods, but I'd like to avoid using third party libraries as much as possible, as this project is aimed toward being a marketable product. Is there something within the Java library that can do base64 encoding?