OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 // | 4 // |
5 // Protocol buffer definitions for Drive backend of Syncable FileSystem. | 5 // Protocol buffer definitions for Drive backend of Syncable FileSystem. |
6 | 6 |
7 syntax = "proto2"; | 7 syntax = "proto2"; |
8 | 8 |
9 option optimize_for = LITE_RUNTIME; | 9 option optimize_for = LITE_RUNTIME; |
10 | 10 |
11 package sync_file_system.drive_backend; | 11 package sync_file_system.drive_backend; |
12 | 12 |
13 enum FileKind { | 13 enum FileKind { |
14 KIND_UNSUPPORTED = 0; | 14 FILE_KIND_UNSUPPORTED = 0; |
15 KIND_FILE = 1; | 15 FILE_KIND_FILE = 1; |
16 KIND_FOLDER = 2; | 16 FILE_KIND_FOLDER = 2; |
17 } | 17 } |
18 | 18 |
19 message ServiceMetadata { | 19 message ServiceMetadata { |
20 optional int64 largest_change_id = 1; | 20 optional int64 largest_change_id = 1; |
21 optional int64 sync_root_tracker_id = 2; | 21 optional int64 sync_root_tracker_id = 2; |
22 | 22 |
23 // The sequence number of FileTrackers. Must be positive. | 23 // The sequence number of FileTrackers. Must be positive. |
24 optional int64 next_tracker_id = 3; | 24 optional int64 next_tracker_id = 3; |
25 } | 25 } |
26 | 26 |
27 // Holds details of file/folder metadata. | 27 // Holds details of file/folder metadata. |
28 message FileDetails { | 28 message FileDetails { |
29 repeated string parent_folder_ids = 1; | 29 repeated string parent_folder_ids = 1; |
30 | 30 |
31 optional string title = 2; | 31 optional string title = 2; |
32 optional FileKind kind = 3; | 32 optional FileKind file_kind = 3; |
33 optional string md5 = 4; | 33 optional string md5 = 4; |
34 optional string etag = 5; | 34 optional string etag = 5; |
35 | 35 |
36 // Creation time and modification time of the resource. | 36 // Creation time and modification time of the resource. |
37 // Serialized by Time::ToInternalValue. | 37 // Serialized by Time::ToInternalValue. |
38 optional int64 creation_time = 6; | 38 optional int64 creation_time = 6; |
39 optional int64 modification_time = 7; | 39 optional int64 modification_time = 7; |
40 | 40 |
41 optional bool deleted = 8; | 41 optional bool deleted = 8; |
42 optional int64 change_id = 9; | 42 optional int64 change_id = 9; |
(...skipping 27 matching lines...) Expand all Loading... |
70 | 70 |
71 // True if the FileTracker is active. | 71 // True if the FileTracker is active. |
72 // Remote file modification should only be applied to active trackers. | 72 // Remote file modification should only be applied to active trackers. |
73 // Active FileTracker must have a unique title under its parent. | 73 // Active FileTracker must have a unique title under its parent. |
74 optional bool active = 8; | 74 optional bool active = 8; |
75 | 75 |
76 // Valid only for folders. | 76 // Valid only for folders. |
77 // True if the folder contents have not yet been fetched. | 77 // True if the folder contents have not yet been fetched. |
78 optional bool needs_folder_listing = 9; | 78 optional bool needs_folder_listing = 9; |
79 } | 79 } |
OLD | NEW |