VirtualMailManager/Domain.py
changeset 32 ceb700bc4a80
parent 24 48ea255e8a85
child 34 6d74e20c5b3b
equal deleted inserted replaced
31:b7a7e566833c 32:ceb700bc4a80
    11 __author__ = 'Pascal Volk <p.volk@veb-it.de>'
    11 __author__ = 'Pascal Volk <p.volk@veb-it.de>'
    12 __version__ = VERSION
    12 __version__ = VERSION
    13 __revision__ = 'rev '+'$Rev$'.split()[1]
    13 __revision__ = 'rev '+'$Rev$'.split()[1]
    14 __date__ = '$Date$'.split()[1]
    14 __date__ = '$Date$'.split()[1]
    15 
    15 
       
    16 import gettext
    16 from random import choice
    17 from random import choice
    17 
    18 
    18 from Exceptions import VMMDomainException
    19 from Exceptions import VMMDomainException
    19 import constants.ERROR as ERR
    20 import constants.ERROR as ERR
    20 from Transport import Transport
    21 from Transport import Transport
    21 
    22 
    22 MAILDIR_CHARS = '0123456789abcdefghijklmnopqrstuvwxyz'
    23 MAILDIR_CHARS = '0123456789abcdefghijklmnopqrstuvwxyz'
       
    24 
       
    25 gettext.bindtextdomain('vmm', '/usr/local/share/locale')
       
    26 gettext.textdomain('vmm')
       
    27 _ = gettext.gettext
    23 
    28 
    24 class Domain:
    29 class Domain:
    25     """Class to manage e-mail domains."""
    30     """Class to manage e-mail domains."""
    26     def __init__(self, dbh, domainname, basedir=None, transport=None):
    31     def __init__(self, dbh, domainname, basedir=None, transport=None):
    27         """Creates a new Domain instance.
    32         """Creates a new Domain instance.