OLD | NEW |
---|---|
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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 // Enumerate the various item subtypes that are supported by sync. | 5 // Enumerate the various item subtypes that are supported by sync. |
6 // Each sync object is expected to have an immutable object type. | 6 // Each sync object is expected to have an immutable object type. |
7 // An object's type is inferred from the type of data it holds. | 7 // An object's type is inferred from the type of data it holds. |
8 | 8 |
9 #ifndef SYNC_INTERNAL_API_PUBLIC_BASE_MODEL_TYPE_H_ | 9 #ifndef SYNC_INTERNAL_API_PUBLIC_BASE_MODEL_TYPE_H_ |
10 #define SYNC_INTERNAL_API_PUBLIC_BASE_MODEL_TYPE_H_ | 10 #define SYNC_INTERNAL_API_PUBLIC_BASE_MODEL_TYPE_H_ |
(...skipping 18 matching lines...) Expand all Loading... | |
29 class SyncEntity; | 29 class SyncEntity; |
30 } | 30 } |
31 | 31 |
32 namespace syncer { | 32 namespace syncer { |
33 | 33 |
34 // TODO(akalin): Move the non-exported functions in this file to a | 34 // TODO(akalin): Move the non-exported functions in this file to a |
35 // private header. | 35 // private header. |
36 | 36 |
37 // A Java counterpart will be generated for this enum. | 37 // A Java counterpart will be generated for this enum. |
38 // GENERATED_JAVA_ENUM_PACKAGE: org.chromium.sync | 38 // GENERATED_JAVA_ENUM_PACKAGE: org.chromium.sync |
39 | |
40 // |kModelTypeInfoMap| struct entries are in the same order as their defination | |
Nicolas Zea
2015/10/30 22:06:48
nit: "defination" -> "definition".
Deepak
2015/10/31 07:37:05
Done.
| |
41 // in ModelType enum. Don't forget to update the |kModelTypeInfoMap| struct in | |
42 // model_type.cc when you make changes in ModelType enum. | |
39 enum ModelType { | 43 enum ModelType { |
40 // Object type unknown. Objects may transition through | 44 // Object type unknown. Objects may transition through |
41 // the unknown state during their initial creation, before | 45 // the unknown state during their initial creation, before |
42 // their properties are set. After deletion, object types | 46 // their properties are set. After deletion, object types |
43 // are generally preserved. | 47 // are generally preserved. |
44 UNSPECIFIED, | 48 UNSPECIFIED, |
45 // A permanent folder whose children may be of mixed | 49 // A permanent folder whose children may be of mixed |
46 // datatypes (e.g. the "Google Chrome" folder). | 50 // datatypes (e.g. the "Google Chrome" folder). |
47 TOP_LEVEL_FOLDER, | 51 TOP_LEVEL_FOLDER, |
48 | 52 |
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
346 | 350 |
347 // Returns true if |model_type| supports ordering of sibling entries. | 351 // Returns true if |model_type| supports ordering of sibling entries. |
348 SYNC_EXPORT bool TypeSupportsOrdering(ModelType model_type); | 352 SYNC_EXPORT bool TypeSupportsOrdering(ModelType model_type); |
349 | 353 |
350 // Returns set of model types that should be backed up before first sync. | 354 // Returns set of model types that should be backed up before first sync. |
351 SYNC_EXPORT ModelTypeSet BackupTypes(); | 355 SYNC_EXPORT ModelTypeSet BackupTypes(); |
352 | 356 |
353 } // namespace syncer | 357 } // namespace syncer |
354 | 358 |
355 #endif // SYNC_INTERNAL_API_PUBLIC_BASE_MODEL_TYPE_H_ | 359 #endif // SYNC_INTERNAL_API_PUBLIC_BASE_MODEL_TYPE_H_ |
OLD | NEW |