(self, target, index=0)
| 247 | # parser to find angle brackets embedded in element attributes. |
| 248 | self.endbracket = re.compile('''([^'"<>]|"[^"]*"(?=>|/|\s|\w+=)|'[^']*'(?=>|/|\s|\w+=))*(?=[<>])|.*?(?=[<>])''') |
| 249 | def search(self, target, index=0): |
| 250 | match = self.endbracket.match(target, index) |
| 251 | if match is not None: |
| 252 | # Returning a new object in the calling thread's context |
| 253 | # resolves a thread-safety. |
| 254 | return EndBracketMatch(match) |
| 255 | return None |
| 256 | class EndBracketMatch: |
| 257 | def __init__(self, match): |
| 258 | self.match = match |
no test coverage detected