def __init__(self, regex=None, message=None, code=None):
        if regex is not None:
            self.regex = regex
        if message is not None:
            self.message = message
        if code is not None:
            self.code = code

        if isinstance(self.regex, basestring):
            self.regex = re.compile(regex)
dataset/ETHPy150Open AppScale/appscale/AppServer/lib/django-1.3/django/core/validators.py/RegexValidator.__init__/original