Added exists() * src/FileEntry.cc * src/FileEntry.h
@@ -1,3 +1,9 @@
+2009-03-12 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
+
+ Added exists()
+ * src/FileEntry.cc
+ * src/FileEntry.h
2009-03-10 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Added missing prefix dir.
@@ -69,4 +69,9 @@ bool FileEntry::operator<(const FileEntry& fileEntry) const
return offset < fileEntry.offset;
}
+bool FileEntry::exists() const
+{
+ return File(getPath()).exists();
+}
} // namespace aria2
@@ -99,6 +99,8 @@ public:
bool operator<(const FileEntry& fileEntry) const;
+ bool exists() const;
};
typedef SharedHandle<FileEntry> FileEntryHandle;