21 #ifndef BT_TORRENTSTATS_H
22 #define BT_TORRENTSTATS_H
25 #include <util/constants.h>
26 #include <ktorrent_export.h>
27 #include <qdatetime.h>
54 struct KTORRENT_EXPORT TorrentStats
65 Uint64 imported_bytes;
67 Uint64 bytes_downloaded;
69 Uint64 bytes_uploaded;
73 Uint64 bytes_left_to_download;
77 Uint64 total_bytes_to_download;
85 Uint32 num_chunks_downloading;
89 Uint32 num_chunks_downloaded;
91 Uint32 num_chunks_excluded;
93 Uint32 num_chunks_left;
99 Uint32 seeders_connected_to;
101 Uint32 leechers_total;
103 Uint32 leechers_connected_to;
105 TorrentStatus status;
107 Uint64 session_bytes_downloaded;
109 Uint64 session_bytes_uploaded;
119 bool stopped_by_error;
131 bool multi_file_torrent;
135 float max_share_ratio;
139 Uint32 num_corrupted_chunks;
141 TimeStamp last_download_activity_time;
143 TimeStamp last_upload_activity_time;
148 float shareRatio()
const;
151 bool overMaxRatio()
const;
154 QString statusToString()
const;
158 #endif // BT_TORRENTSTATS_H