loopback_server.proto 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. // Copyright (c) 2012 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. //
  5. // Sync protocol for persisting the loopback server state to disk.
  6. syntax = "proto2";
  7. option java_multiple_files = true;
  8. option java_package = "org.chromium.components.sync.protocol";
  9. option optimize_for = LITE_RUNTIME;
  10. package sync_pb;
  11. import "components/sync/protocol/sync_entity.proto";
  12. // Serialization of the LoopbackServerEntity and its ancestors.
  13. message LoopbackServerEntity {
  14. // Entity type mapping to one of the subclasses of LoopbackServerEntity.
  15. enum Type {
  16. UNKNOWN = 0;
  17. BOOKMARK = 1;
  18. PERMANENT = 2;
  19. TOMBSTONE = 3;
  20. UNIQUE = 4;
  21. }
  22. optional Type type = 1;
  23. optional SyncEntity entity = 2;
  24. optional int64 model_type = 3;
  25. }
  26. // Contains the loopback server state.
  27. message LoopbackServerProto {
  28. // The protocol buffer format version.
  29. optional int64 version = 1;
  30. optional int64 store_birthday = 2;
  31. repeated LoopbackServerEntity entities = 3;
  32. // All Keystore keys known to the server.
  33. repeated bytes keystore_keys = 4;
  34. // The last entity ID that was assigned to an entity.
  35. optional int64 last_version_assigned = 5;
  36. }