Lines Matching full:string
28 def _add_regex(self, string, flags):
32 self.regex = re_cache.get(string, None)
34 self.regex = re.compile(string, flags=flags)
36 re_cache[string] = self.regex
38 def __init__(self, string, cache=True, flags=0):
46 self._add_regex(string, flags)
65 def match(self, string):
70 self.last_match = self.regex.match(string)
73 def search(self, string):
78 self.last_match = self.regex.search(string)
81 def findall(self, string):
86 return self.regex.findall(string)
88 def split(self, string):
93 return self.regex.split(string)
95 def sub(self, sub, string, count=0):
100 return self.regex.sub(sub, string, count=count)
121 string search STRUCT_GROUP(),
132 will ignore the search string.
258 # replaces \1 at the sub string, if \1 is used there
274 # Append the remaining string