I have a idea about how to realize the logic of visibility judgment through xml.
Multiple visibility elements can be written at the same level, the attributes under the same element is the relationship of logical AND, and the relationship between different elements is the logical OR,
E.g:
<visibility start_time="08:00" end_time="10:00"/>
<visibility start_time="14:00" end_time="16:00"/>
it mean visible when 08:00<current_time<10:00 or 14:00<current_time<16:00