![]() ![]() But none of them are url friendly, so just use different chars for them and you're set. You need two more and a padding char '='. But essentially you need 65 chars to encode: 26 lowercase 26 uppercase 10 digits = 62. ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789 /= Now we create a function to generate a MIME buffer for test: import, you would need to url-encode it, since base64 strings can contain the " ", "=" and "/" characters which could alter the meaning of your data - look like a sub-folder. The MIME encoder generates a Base64 encoded output but in a MIME friendly format. Val decodedUrlBytes = Base64.getUrlDecoder().decode(encodedUrl)
0 Comments
Leave a Reply. |