summaryrefslogtreecommitdiffstats
path: root/google_apis/drive/drive_api_parser.h
diff options
context:
space:
mode:
authorkinaba@chromium.org <kinaba@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-12-05 11:09:52 +0000
committerkinaba@chromium.org <kinaba@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-12-05 11:09:52 +0000
commitb0b3dbd9358e55e70a4592428c6dca07f76eccde (patch)
tree055d90c2581792b42eb7b8bd7f91b9a1a342dfad /google_apis/drive/drive_api_parser.h
parent67a8f5a2310ebd4a6936a17632169d7660ebb3df (diff)
downloadchromium_src-b0b3dbd9358e55e70a4592428c6dca07f76eccde.zip
chromium_src-b0b3dbd9358e55e70a4592428c6dca07f76eccde.tar.gz
chromium_src-b0b3dbd9358e55e70a4592428c6dca07f76eccde.tar.bz2
Parse 'shared' attribute in WAPI/DriveAPI.
In WAPI, a label "shared" is added to the category of an entry. In Drive API, the File resources contain a boolean field "shared". BUG=264812 Review URL: https://codereview.chromium.org/104193002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@238936 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'google_apis/drive/drive_api_parser.h')
-rw-r--r--google_apis/drive/drive_api_parser.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/google_apis/drive/drive_api_parser.h b/google_apis/drive/drive_api_parser.h
index 1f7ddb8..2ee230d 100644
--- a/google_apis/drive/drive_api_parser.h
+++ b/google_apis/drive/drive_api_parser.h
@@ -525,6 +525,9 @@ class FileResource {
return shared_with_me_date_;
}
+ // Returns the 'shared' attribute of the file.
+ bool shared() const { return shared_; }
+
// Returns the short-lived download URL for the file. This field exists
// only when the file content is stored in Drive.
const GURL& download_url() const { return download_url_; }
@@ -596,6 +599,9 @@ class FileResource {
void set_shared_with_me_date(const base::Time& shared_with_me_date) {
shared_with_me_date_ = shared_with_me_date;
}
+ void set_shared(bool shared) {
+ shared_ = shared;
+ }
void set_download_url(const GURL& download_url) {
download_url_ = download_url;
}
@@ -645,6 +651,7 @@ class FileResource {
base::Time modified_by_me_date_;
base::Time last_viewed_by_me_date_;
base::Time shared_with_me_date_;
+ bool shared_;
GURL download_url_;
std::string file_extension_;
std::string md5_checksum_;