commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeffrey Dever <>
Subject Re: [codec] RE:
Date Tue, 04 Feb 2003 21:09:31 GMT
>Base64 is well understood just as a general encoding scheme outside of RFC
>2045 MIME.   RFC 2045 MIME adds a further requirement that the content be
>put into 76 character chunks.  Past 1.1 we could also talk about
>providing the core "base64" encoding, and extending Base64
>and adding "pre" and "post" processing to the algorithm.
As long as efficiency is held as a key requirement over OO purity. 
 After all, Base64 is functional in nature.  

There should only be one memory allocation for the output, and one 
iteration over the input.  It would be inefficient to allocate the 
output array, iterate over the input for the general algorithm, then 
have to reallocate another array and iterate over the intermediate 
output just to drop in '\n' every 76 characters.

But in the HttpClient case, we only encode/decode small inputs (few 
hundred bytes) anyway.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message