@indexed_file.setter<EOL><INDENT>def indexed_file(self, f):<DEDENT>
filename, handle = f<EOL>if handle is None and filename is not None:<EOL><INDENT>handle = open(filename)<EOL><DEDENT>if (handle is None and filename is None) or(filename != self._indexed_filename) or(handle != self._indexed_file_handle):<EOL><INDENT>self.index = {}<EOL><DEDENT>if ((handle is not None or filename is not None) and<EOL>(self.record_iterator is None or self.record_hash_function is None)):<EOL><INDENT>raise IndexError("<STR_LIT>"<EOL>"<STR_LIT>"<EOL>"<STR_LIT>")<EOL><DEDENT>self._indexed_filename = filename<EOL>self._indexed_file_handle = handle<EOL>
Setter for information about the file this object indexes.

:param f: a tuple of (filename, handle), either (or both) of which can be
          None. If the handle is None, but filename is provided, then
          handle is created from the filename. If both handle and filename
          are None, or they don't match the previous values indexed by this
          object, any current data in this index is cleared. If either are
          not None, we require the iterator and the hash function for this
          object to already be set.