public static void decodeFieldData ( BaseField field , String string ) { if ( ( string == null ) || ( string . length ( ) == 0 ) ) return ; byte [ ] ba = Base64 . decode ( string . toCharArray ( ) ) ; InputStream is = new ByteArrayInputStream ( ba ) ; DataInputStream daIn = new DataInputStream ( is ) ; field . read ( daIn , false ) ; }
Change this base64 string to raw data and set the value in this field . WARNING - This requires 64bit encoding found in javax . mail!