Apply a function on given word :param str function_name: function to apply :param str word: word to apply function on :rtype: Query
(self, function_name, word)
| 1080 | |
| 1081 | @fluent |
| 1082 | def function(self, function_name, word): |
| 1083 | """ Apply a function on given word |
| 1084 | |
| 1085 | :param str function_name: function to apply |
| 1086 | :param str word: word to apply function on |
| 1087 | :rtype: Query |
| 1088 | """ |
| 1089 | word = self._parse_filter_word(word) |
| 1090 | # consume negation |
| 1091 | negation = self._negation |
| 1092 | if negation: |
| 1093 | self._negation = False |
| 1094 | self._add_filter( |
| 1095 | *self._prepare_function(function_name, self._attribute, word, negation)) |
| 1096 | return self |
| 1097 | |
| 1098 | @fluent |
| 1099 | def contains(self, word): |
no test coverage detected