|
From: | David Ayers |
Subject: | Re: base64 coder/decoder for GNUstep |
Date: | Fri, 27 Feb 2004 10:42:49 +0100 |
User-agent: | Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.6) Gecko/20040113 |
Fred Kiefer wrote:
Alexander Malmberg wrote:Andreas Hoeschler wrote:we need to decode a base64 stream in an NSData object. Do we need to implement a decoder on our own or is such a beast available for download anywhere? What I am looking for is a category method for NSData like - (NSData *)decodedBase64Stream; Any ideas? Thanks a lot!Pantomime's MimeUtility class can do that: + (NSData *) decodeBase64: (NSData *) theData;A similar method already exists in base/Source/Additions/GSMime.m on GSMimeDocument.
[switched lists]Actually we also have a uuencode implementation in GSMime, for which I already have the 'OK' to move it to an NSData category (as time permits and I'll wait until after the release). I'm haven't looked closely at base64 and the incremental decoding technique it uses, but maybe we should also consider whether it should be a Good Thing...
Thoughts? Cheers, David
[Prev in Thread] | Current Thread | [Next in Thread] |