/* */ #include "BtFileAllocationEntry.h" #include "BtSetup.h" #include "RequestGroup.h" #include "Command.h" #include "DownloadEngine.h" #include namespace aria2 { BtFileAllocationEntry::BtFileAllocationEntry(RequestGroup* requestGroup): FileAllocationEntry(requestGroup, 0) {} BtFileAllocationEntry::~BtFileAllocationEntry() {} Commands BtFileAllocationEntry::prepareForNextAction(DownloadEngine* e) { Commands commands = BtSetup().setup(_requestGroup, e, e->option); if(!_requestGroup->downloadFinished()) { Commands streamCommands = _requestGroup->createNextCommandWithAdj(e, 0); std::copy(streamCommands.begin(), streamCommands.end(), std::back_inserter(commands)); } return commands; } } // namespace aria2