def invalidation_hash(self):
<INDENT>if not self.root:<EOL><INDENT>return '<STR_LIT>'<EOL><DEDENT><DEDENT>def _hash_for_split(split):<EOL><INDENT>result = []<EOL>for item in split:<EOL><INDENT>if isinstance(item, (VSplit, HSplit)):<EOL><INDENT>result.append(_hash_for_split(item))<EOL><DEDENT>elif isinstance(item, Pane):<EOL><INDENT>result.append('<STR_LIT>' % item.pane_id)<EOL><DEDENT><DEDENT>if isinstance(split, HSplit):<EOL><INDENT>return '<STR_LIT>' % ('<STR_LIT:U+002C>'.join(result))<EOL><DEDENT>else:<EOL><INDENT>return '<STR_LIT>' % ('<STR_LIT:U+002C>'.join(result))<EOL><DEDENT><DEDENT>return '<STR_LIT>' % (<EOL>self.window_id, self.zoom, _hash_for_split(self.root))<EOL>
Return a hash (string) that can be used to determine when the layout
has to be rebuild.