encoding - How to decode a string on runtime in java? -
I am creating an email client, when I receive an email from the Blackberry server, then this file name "=? Utf -8 "? B? AnBlZ2F0dGFjaG1lbnQuSlBFRw ==? = "But the original file name was" jpegattachment.JPEG ", and for some time when I get from other mail servers, I get plain text so here my problem is that I can get a string that can not be encoded .
Is there any way, I can get the encoding of the string and put it in plain text.
Either the input string "=? UTF-8? B? AnBlZ2F0dGFjaG1lbnQuSlBFRw ==? = "Or" JPGactact. JPEG should be "output" jpegattachment.JPEG ".
Any Idea ??
It is MIME-encoded, although Base64 is the most popular, it can use other encoding such as quoted-printable, binary etc. Therefore you should use the current DDOD, in any mail program the decoder will be created.
You can use decodeWord ()
from java mail,
try
Comments
Post a Comment