summaryrefslogtreecommitdiff
path: root/src/PieceStorage.h
diff options
context:
space:
mode:
authorTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2011-08-24 23:16:06 +0900
committerTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2011-08-24 23:16:06 +0900
commitc7ac14728730d683ca281f9b5dbbac9f3ceaeafa (patch)
treebfb4b6684db67bafe12706dce4599d5666630350 /src/PieceStorage.h
parentb94bf3355b349f6d7824a1ab67c7a1d695e9314a (diff)
Added PieceStorage::onDownloadIncomplete() virtual function.
In DefaultPieceStorage::onDownloadIncomplete(), we call StreamPieceSelector::onBitfieldInit(). Added GeomStreamPieceSelectorTest.
Diffstat (limited to 'src/PieceStorage.h')
-rw-r--r--src/PieceStorage.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/PieceStorage.h b/src/PieceStorage.h
index e50495b7..b3d3e46c 100644
--- a/src/PieceStorage.h
+++ b/src/PieceStorage.h
@@ -283,6 +283,9 @@ public:
// are not used and not completed. If all pieces after index+1 are
// used or completed, returns the number of pieces.
virtual size_t getNextUsedIndex(size_t index) = 0;
+
+ // Called when system detects download is not finished
+ virtual void onDownloadIncomplete() = 0;
};
typedef SharedHandle<PieceStorage> PieceStorageHandle;