diff --git a/docs/manual.html b/docs/manual.html index b3d5df54a..10ace1e2c 100755 --- a/docs/manual.html +++ b/docs/manual.html @@ -59,61 +59,63 @@
Returns true if the torrent is in seed mode (i.e. if it has finished downloading).
+has_metadata()
++++bool has_metadata() const; ++
Returns true if this torrent has metadata (either it was started from a .torrent file or the +metadata has been downloaded). The only scenario where this can return false is when the torrent +was started torrent-less (i.e. with just an info-hash and tracker ip). Note that if the torrent +doesn't have metadata, the member get_torrent_info() will throw.
+++std::vector<char> const& metadata() const; ++
metadata() will return a reference to a buffer containing the exact info part of the +.torrent file. This buffer will be valid as long as the torrent is still running. When hashed, +it will produce the same hash as the info-hash.
+@@ -1064,7 +1090,10 @@ torrent_info const& get_torrent_info();
Returns a const reference to the torrent_info object associated with this torrent. This reference is valid as long as the torrent_handle is valid, no longer. If the -torrent_handle is invalid, invalid_handle exception will be thrown.
+torrent_handle is invalid or if it doesn't have any metadata, invalid_handle +exception will be thrown. The torrent may be in a state without metadata only if +it was started without a .torrent file, i.e. by using the libtorrent extension of +just supplying a tracker and info-hash.This alert is generated when the metadata has been completely received and the torrent +can start downloading. It is not generated on torrents that are started with metadata, bu +only those that needs to download it from peers (when utilizing the libtorrent extension). +It is generated at severity level info.
++struct metadata_received_alert: alert +{ + metadata_received_alert( + const torrent_handle& h + , const std::string& msg); + + virtual std::auto_ptr<alert> clone() const; + + torrent_handle handle; +}; +