Set the list of regex that will parse the SQL.
(self, SQL_REGEX)
| 79 | self._keywords = [] |
| 80 | |
| 81 | def set_SQL_REGEX(self, SQL_REGEX): |
| 82 | """Set the list of regex that will parse the SQL.""" |
| 83 | FLAGS = re.IGNORECASE | re.UNICODE |
| 84 | self._SQL_REGEX = [ |
| 85 | (re.compile(rx, FLAGS).match, tt) |
| 86 | for rx, tt in SQL_REGEX |
| 87 | ] |
| 88 | |
| 89 | def add_keywords(self, keywords): |
| 90 | """Add keyword dictionaries. Keywords are looked up in the same order |
no outgoing calls