From 241b72aabe0a5dd02313ec035b33f45704402b9a Mon Sep 17 00:00:00 2001 From: Arvid Norberg Date: Mon, 22 Mar 2010 17:20:41 +0000 Subject: [PATCH] added documentation to explain that remap_files can be used to rename the base name of a torrent --- docs/manual.html | 5 ++++- docs/manual.rst | 6 +++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/docs/manual.html b/docs/manual.html index 208ea175f..50de8f5c5 100644 --- a/docs/manual.html +++ b/docs/manual.html @@ -1728,7 +1728,7 @@ which the trackers are to be tried. For more information see -file_storage const& file() const; +file_storage const& files() const; file_storage const& orig_files() const; @@ -1766,6 +1766,9 @@ void rename_file(int index, std::wstring const& new_filename);

Renames a the file with the specified index to the new name. The new filename is reflected by the file_storage returned by files() but not by the one returned by orig_files().

+

If you want to rename the base name of the torrent (for a multifile torrent), you +can copy the file_storage (see files() orig_files()), change the name, and +then use remap_files().

begin_files() end_files() rbegin_files() rend_files()

diff --git a/docs/manual.rst b/docs/manual.rst index 935adbaa5..48e4974cd 100644 --- a/docs/manual.rst +++ b/docs/manual.rst @@ -1582,7 +1582,7 @@ files() orig_files() :: - file_storage const& file() const; + file_storage const& files() const; file_storage const& orig_files() const; The ``file_storage`` object contains the information on how to map the pieces to @@ -1623,6 +1623,10 @@ Renames a the file with the specified index to the new name. The new filename is reflected by the ``file_storage`` returned by ``files()`` but not by the one returned by ``orig_files()``. +If you want to rename the base name of the torrent (for a multifile torrent), you +can copy the ``file_storage`` (see `files() orig_files()`_), change the name, and +then use `remap_files()`_. + begin_files() end_files() rbegin_files() rend_files() -----------------------------------------------------