Replaces characters in string ``text`` based in regex sub

def transform(self, text):
        """Replaces characters in string ``text`` based in regex sub"""
        return re.sub(self.regex, self.repl, text)