def resolve_for(self, node):
self.node = node<EOL>self.actual_text = normalize_text(<EOL>node.visible_text if self.query_type == "<STR_LIT>" else node.all_text)<EOL>self.count = len(re.findall(self.search_regexp, self.actual_text))<EOL>return self.count<EOL>
Resolves this query relative to the given node.

Args:
    node (node.Base): The node to be evaluated.

Returns:
    int: The number of matches found.