<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _try_switches(self, lines, index):
 """ For each switch in the Collector object, pass a list of string, representing lines of text in a file, and an index to the current line to try to flip the switch. A switch will only flip on if the line passes its 'test_on' method, and will only flip off if the line passes its 'test_off' method. :param lines: List of strings, usually the lines in a text file :param index: Number index pointing to the current line """

        for s in self._switches:
            s.switch(lines, index)