mirror of https://github.com/aria2/aria2
2007-10-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* src/ConsoleStatCalc.cc: Let the user know that aria2 is now seeding after the download finishes.pull/1/head
parent
3ab9fe706d
commit
fdb2ee28cc
|
@ -1,3 +1,8 @@
|
||||||
|
2007-10-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
||||||
|
|
||||||
|
* src/ConsoleStatCalc.cc: Let the user know that aria2 is now seeding
|
||||||
|
after the download finishes.
|
||||||
|
|
||||||
2007-10-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
2007-10-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
||||||
|
|
||||||
* src/Piece.{h, cc}: Added SubPiece infrastructure to track down
|
* src/Piece.{h, cc}: Added SubPiece infrastructure to track down
|
||||||
|
|
|
@ -40,6 +40,9 @@
|
||||||
#include "CheckIntegrityMan.h"
|
#include "CheckIntegrityMan.h"
|
||||||
#include "CheckIntegrityEntry.h"
|
#include "CheckIntegrityEntry.h"
|
||||||
#include "Util.h"
|
#include "Util.h"
|
||||||
|
#ifdef ENABLE_BITTORRENT
|
||||||
|
# include "BtContext.h"
|
||||||
|
#endif // ENABLE_BITTORRENT
|
||||||
#include <iomanip>
|
#include <iomanip>
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -64,8 +67,17 @@ ConsoleStatCalc::calculateStat(const RequestGroupManHandle& requestGroupMan,
|
||||||
}
|
}
|
||||||
|
|
||||||
cout << "["
|
cout << "["
|
||||||
<< "#" << firstRequestGroup->getGID() << " "
|
<< "#" << firstRequestGroup->getGID() << " ";
|
||||||
<< "SIZE:"
|
#ifdef ENABLE_BITTORRENT
|
||||||
|
if(firstRequestGroup->downloadFinished() &&
|
||||||
|
!BtContextHandle(firstRequestGroup->getDownloadContext()).isNull()) {
|
||||||
|
cout << "SEEDING" << "(" << "ratio:"
|
||||||
|
<< fixed << setprecision(1) << stat.getAllTimeUploadLength()*1.0/firstRequestGroup->getCompletedLength()
|
||||||
|
<< ")";
|
||||||
|
} else
|
||||||
|
#endif // ENABLE_BITTORRENT
|
||||||
|
{
|
||||||
|
cout << "SIZE:"
|
||||||
<< Util::abbrevSize(firstRequestGroup->getCompletedLength())
|
<< Util::abbrevSize(firstRequestGroup->getCompletedLength())
|
||||||
<< "B"
|
<< "B"
|
||||||
<< "/"
|
<< "/"
|
||||||
|
@ -76,6 +88,7 @@ ConsoleStatCalc::calculateStat(const RequestGroupManHandle& requestGroupMan,
|
||||||
<< 100*firstRequestGroup->getCompletedLength()/firstRequestGroup->getTotalLength()
|
<< 100*firstRequestGroup->getCompletedLength()/firstRequestGroup->getTotalLength()
|
||||||
<< "%)";
|
<< "%)";
|
||||||
}
|
}
|
||||||
|
}
|
||||||
cout << " "
|
cout << " "
|
||||||
<< "CN:"
|
<< "CN:"
|
||||||
<< firstRequestGroup->getNumConnection();
|
<< firstRequestGroup->getNumConnection();
|
||||||
|
|
Loading…
Reference in New Issue