VirtualMailManager/AliasDomain.py
changeset 122 30abf0abf8f8
parent 102 485d3f7d6981
child 133 2d5c4745efec
equal deleted inserted replaced
121:7ccc05774118 122:30abf0abf8f8
     8 
     8 
     9 from Exceptions import VMMAliasDomainException as VADE
     9 from Exceptions import VMMAliasDomainException as VADE
    10 import constants.ERROR as ERR
    10 import constants.ERROR as ERR
    11 import VirtualMailManager as VMM
    11 import VirtualMailManager as VMM
    12 
    12 
    13 class AliasDomain:
    13 class AliasDomain(object):
    14     """Class to manage e-mail alias domains."""
    14     """Class to manage e-mail alias domains."""
       
    15     __slots__ = ('__gid', '__name', '_domain', '_dbh')
    15     def __init__(self, dbh, domainname, targetDomain=None):
    16     def __init__(self, dbh, domainname, targetDomain=None):
    16         self._dbh = dbh
    17         self._dbh = dbh
    17         self.__name = VMM.VirtualMailManager.chkDomainname(domainname)
    18         self.__name = VMM.VirtualMailManager.chkDomainname(domainname)
    18         self.__gid = 0
    19         self.__gid = 0
    19         self._domain = targetDomain
    20         self._domain = targetDomain