pub fn is_file_read_write(file: &File) -> Result<(bool, bool)>
Return a pair of booleans indicating whether the given file is opened for reading and writing, respectively.