Methods



+dataWithBase64EncodedString:

+ (NSData *)dataWithBase64EncodedString:(NSString *)inBase64String; 

This method returns an autoreleased NSData object. The NSData object is initialized with the contents of the Base 64 encoded string. This is a convenience function for -initWithBase64EncodedString:.

Parameters

NameDescription
inBase64StringAn NSString object that contains only Base 64 encoded data.
Result: The NSData object.

+isCharacterPartOfBase64Encoding:

+ (BOOL)isCharacterPartOfBase64Encoding:(char)inChar; 

This method returns YES or NO depending on whether the given character is a part of the Base64 encoding table.

Parameters

NameDescription
inCharAn character in ASCII encoding.
Result: YES if the character is a part of the Base64 encoding table.

-base64EncodingWithLineLength:

- (NSString *)base64EncodingWithLineLength:(unsigned int)inLineLength; 

This method returns a Base 64 encoded string representation of the data object.

Parameters

NameDescription
inLineLengthA value of zero means no line breaks. This is crunched to a multiple of 4 (the next one greater than inLineLength).
Result: The base 64 encoded data.

-initWithBase64EncodedString:

- (id)initWithBase64EncodedString:(NSString *)inBase64String; 

The NSData object is initialized with the contents of the Base 64 encoded string. This method returns self as a convenience.

Parameters

NameDescription
inBase64StringAn NSString object that contains only Base 64 encoded data.
Result: This method returns self.

© 2001, 2005 Kyle Hammond (Last Updated 1/12/2005)