Chromium Code Reviews| Index: webkit/fileapi/media/picasa/picasa_album_table_reader.h |
| diff --git a/webkit/fileapi/media/picasa/picasa_album_table_reader.h b/webkit/fileapi/media/picasa/picasa_album_table_reader.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..efe9c83a963bc09c08bb2be4061954d67882450a |
| --- /dev/null |
| +++ b/webkit/fileapi/media/picasa/picasa_album_table_reader.h |
| @@ -0,0 +1,57 @@ |
| +// Copyright 2013 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef WEBKIT_FILEAPI_MEDIA_PICASA_PMP_ALBUM_TABLE_READER_H_ |
| +#define WEBKIT_FILEAPI_MEDIA_PICASA_PMP_ALBUM_TABLE_READER_H_ |
| + |
| +#include "base/basictypes.h" |
| +#include "base/files/file_path.h" |
| +#include "base/time.h" |
| +#include "webkit/storage/webkit_storage_export.h" |
| + |
| +namespace picasaimport { |
| + |
| +struct AlbumInfo { |
| + AlbumInfo(const std::string& name, const base::Time& timestamp, |
| + const std::string& uid); |
| + |
| + std::string name; |
| + base::Time timestamp; |
| + std::string uid; |
| +}; |
| + |
| +struct FolderInfo { |
| + FolderInfo(const std::string& name, const base::Time& timestamp, |
| + const base::FilePath& path); |
| + |
| + std::string name; |
| + base::Time timestamp; |
| + base::FilePath path; |
| +}; |
| + |
| +class WEBKIT_STORAGE_EXPORT_PRIVATE PicasaAlbumTableReader { |
| + public: |
| + PicasaAlbumTableReader(); |
|
Greg Billock
2013/04/11 23:12:44
Any reason this can't take the path argument and g
tommycli
2013/04/12 20:47:44
Callers need to know when it explicitly failed, an
|
| + virtual ~PicasaAlbumTableReader(); |
| + |
| + virtual bool Init(const base::FilePath& directory_path); |
|
Greg Billock
2013/04/11 23:12:44
Is this path like the path to a metadata file or s
tommycli
2013/04/12 20:47:44
Done.
|
| + |
| + std::vector<FolderInfo> folders() { |
|
Greg Billock
2013/04/11 23:12:44
Do you want to return const & here and below? Or r
tommycli
2013/04/12 20:47:44
Done.
|
| + return folders_; |
| + } |
| + |
| + std::vector<AlbumInfo> user_albums() { |
| + return user_albums_; |
| + } |
| + |
| + private: |
| + std::vector<FolderInfo> folders_; |
| + std::vector<AlbumInfo> user_albums_; |
| + |
| + DISALLOW_COPY_AND_ASSIGN (PicasaAlbumTableReader); |
| +}; |
| + |
| +} // namespace picasaimport |
| + |
| +#endif // WEBKIT_FILEAPI_MEDIA_PICASA_PMP_ALBUM_TABLE_READER_H_ |