def METHOD_NAME(self):
    length = self.nvert + 1
    # parameters for both BFS and DFS
    self._processed = length * [False]
    self._discovered = length * [False]
    self._parent = length * [None]
    # additional parameters for DFS
    self._finished = False
    self._entry_time = length * [0]
    self._exit_time = length * [0]
    self._time = 0
    self.cycle = []  # cycle path if a cycle is found during DFS