Base64 Class Reference

Base-64 encoding and decoding routines. More...

#include <Base64.h++>

List of all members.

Static Public Member Functions

static size_t encode (ByteBuffer &input, CharBuffer &output) throw ()
 Base64-encode the contents of a buffer.
static size_t encode (const byte_t *input, size_t inputLen, char *output, size_t outputLen) throw ()
 Base64-encode a block of bytes.
static size_t decode (CharBuffer &input, ByteBuffer &output) throw ()
 Base64-decode the contents of a buffer.
static size_t decode (const char *input, size_t inputLen, byte_t *output, size_t outputLen) throw ()
 Base64-decode a block of characters.


Detailed Description

Base-64 encoding and decoding routines.

Author:
Mark Lindner

Member Function Documentation

size_t decode ( const char *  input,
size_t  inputLen,
byte_t output,
size_t  outputLen 
) throw () [static]

Base64-decode a block of characters.

Parameters:
input The input buffer.
inputLen The length of the input buffer.
output The output buffer.
outputLen The length of the output buffer. If NULL, the function returns the amount of space needed.
Returns:
The number of characters written to the output buffer, or 0 if a decoding error occurred. If the output buffer was too small, the value returned will be greater than outputLen, and will indicate the size required.

size_t decode ( CharBuffer input,
ByteBuffer output 
) throw () [static]

Base64-decode the contents of a buffer.

Parameters:
input The buffer containing the input data.
output The output buffer. If NULL, the function returns the amount of space needed.
Returns:
The number of characters written to the output buffer, or 0 if a decoding error occurred. If there was not enough room in the output buffer, the value returned will indicate the amount of space needed.

size_t encode ( const byte_t input,
size_t  inputLen,
char *  output,
size_t  outputLen 
) throw () [static]

Base64-encode a block of bytes.

Parameters:
input The input buffer.
inputLen The length of the input buffer.
output The output buffer.
outputLen The length of the output buffer.
Returns:
The number of characters written to the output buffer, or 0 if an encoding error occurred. If the output buffer was too small, the value returned will be greater than outputLen, and will indicate the size required.

size_t encode ( ByteBuffer input,
CharBuffer output 
) throw () [static]

Base64-encode the contents of a buffer.

Parameters:
input The buffer containing the input data.
output The output buffer.
Returns:
The number of characters written to the output buffer, or 0 if an encoding error occurred. If there was not enough room in the output buffer, the value returned will indicate the amount of space needed.


The documentation for this class was generated from the following files:

Generated on Sat Apr 17 23:03:07 2010 for libcommonc++ by  doxygen 1.5.9