Inherits from NSObject
Declared in DTBase64Coding.h

Overview

Utility class for encoding and decoding data in base64 format.

This was formerly a category on NSData but since Matt Gallagher’s category has become so enormously popular people where reporting more and more conflicts. Thus we decided to move it into a properly named class.

Since all methods are class methods you never need to actually initialize it, doing so will raises a DTAbstractClassException.

Class Methods

dataByDecodingString:

Encodes data as base64 string.

+ (NSData *)dataByDecodingString:(NSString *)string

Parameters

string

The string with data encoded in base64 format

Return Value

data The decoded data

Declared In

DTBase64Coding.h

stringByEncodingData:

Encodes data as base64 string.

+ (NSString *)stringByEncodingData:(NSData *)data

Parameters

data

The data to encode

Return Value

The encoded string

Declared In

DTBase64Coding.h