Use to_writer