Chromium Code Reviews| Index: net/disk_cache/simple/simple_util.h |
| diff --git a/net/disk_cache/simple/simple_util.h b/net/disk_cache/simple/simple_util.h |
| index ef518695813cff891658644aa2a831da35c3b1a8..3c3bd3600f06ec0c35a1264585387c13b19b554e 100644 |
| --- a/net/disk_cache/simple/simple_util.h |
| +++ b/net/disk_cache/simple/simple_util.h |
| @@ -56,12 +56,21 @@ NET_EXPORT_PRIVATE int32 GetDataSizeFromKeyAndFileSize(const std::string& key, |
| // returns the number of bytes in the file. |
| NET_EXPORT_PRIVATE int64 GetFileSizeFromKeyAndDataSize(const std::string& key, |
| int32 data_size); |
| +// Given the stream index, returns the number of the file the stream is stored |
| +// in. |
| +NET_EXPORT_PRIVATE int GetFileIndexFromStreamIndex(int stream_index); |
| + |
| +// Given the data size for all streams and a file index, gives the offset of the |
| +// last EOF record. |
| +NET_EXPORT_PRIVATE int GetLastEOFRecordOffset(int file_index, |
| + const int data_size[]); |
| // Given the key to an entry, and an offset into a stream on that entry, returns |
| // the file offset corresponding to |data_offset|. |
| -NET_EXPORT_PRIVATE int64 GetFileOffsetFromKeyAndDataOffset( |
| - const std::string& key, |
| - int data_offset); |
| +NET_EXPORT_PRIVATE int64 GetFileOffsetFromDataOffset(const std::string& key, |
| + int data_offset, |
| + int index, |
| + int stream_1_size); |
|
pasko
2013/09/17 11:29:01
Originally I did not like this stream_1_size in th
clamy
2013/09/17 13:59:42
Done.
|
| // Fills |out_time| with the time the file last modified time. Unlike the |
| // functions in platform_file.h, the time resolution is milliseconds. |