Back to index

python3.2  3.2.2
Classes | Functions
encodings.base64_codec Namespace Reference

Classes

class  Codec
class  IncrementalEncoder
class  IncrementalDecoder
class  StreamWriter
class  StreamReader

Functions

def base64_encode
 Codec APIs.
def base64_decode
def getregentry

Detailed Description

Python 'base64_codec' Codec - base64 content transfer encoding.

This codec de/encodes from bytes to bytes and is therefore usable with
bytes.transform() and bytes.untransform().

Written by Marc-Andre Lemburg (mal@lemburg.com).

Function Documentation

def encodings.base64_codec.base64_decode (   input,
  errors = 'strict' 
)

Definition at line 18 of file base64_codec.py.

00018 
00019 def base64_decode(input, errors='strict'):
00020     assert errors == 'strict'
00021     return (base64.decodebytes(input), len(input))

Here is the call graph for this function:

Here is the caller graph for this function:

def encodings.base64_codec.base64_encode (   input,
  errors = 'strict' 
)

Codec APIs.

Definition at line 14 of file base64_codec.py.

00014 
00015 def base64_encode(input, errors='strict'):
00016     assert errors == 'strict'
00017     return (base64.encodebytes(input), len(input))

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 46 of file base64_codec.py.

00046 
00047 def getregentry():
00048     return codecs.CodecInfo(
00049         name='base64',
00050         encode=base64_encode,
00051         decode=base64_decode,
00052         incrementalencoder=IncrementalEncoder,
00053         incrementaldecoder=IncrementalDecoder,
00054         streamwriter=StreamWriter,
00055         streamreader=StreamReader,
00056     )