diff -r f40128debb5d -r e0d6e9bd3ca7 javacommons/utils/inc/javacommonutils.h --- a/javacommons/utils/inc/javacommonutils.h Wed Jun 23 18:07:10 2010 +0300 +++ b/javacommons/utils/inc/javacommonutils.h Tue Jul 06 14:10:26 2010 +0300 @@ -87,6 +87,23 @@ OS_IMPORT static std::string base64encode(const std::string& aData); /** + * Encode wstring to base64 wstring byte by byte. + * + * wstring aData is base64 encoded as a byte array. + * If the wstring has been created from TDesC16 in Symbian it contains + * UTF-16LE (UCS-2) encoded 16-bit characters. + * The result is byte array that contains 8-bit ASCII characters. + * Each of these 8-bit character is converted to the corresponding + * wchar and appended to the result wstring. + * + * @see \sf\app\jrt\javamanager\javainstaller\installer\javasrc\com\nokia + * \mj\impl\installer\utils\Args.java, decodeBase64Args() + * @param aData wstring containing the data to be encoded. + * @return base64 encoded result wstring. + */ + OS_IMPORT static std::wstring wbase64encode(const std::wstring& aData); + + /** * Decode base64 string. * * @param aData base64 encoded string.