| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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 #include "sync/syncable/entry_kernel.h" | 5 #include "sync/syncable/entry_kernel.h" |
| 6 | 6 |
| 7 #include "base/string_number_conversions.h" | 7 #include "base/string_number_conversions.h" |
| 8 #include "sync/protocol/proto_value_conversions.h" | 8 #include "sync/protocol/proto_value_conversions.h" |
| 9 #include "sync/syncable/syncable_enum_conversions.h" | 9 #include "sync/syncable/syncable_enum_conversions.h" |
| 10 | 10 |
| 11 namespace syncer { |
| 11 namespace syncable { | 12 namespace syncable { |
| 12 | 13 |
| 13 EntryKernel::EntryKernel() : dirty_(false) { | 14 EntryKernel::EntryKernel() : dirty_(false) { |
| 14 // Everything else should already be default-initialized. | 15 // Everything else should already be default-initialized. |
| 15 for (int i = INT64_FIELDS_BEGIN; i < INT64_FIELDS_END; ++i) { | 16 for (int i = INT64_FIELDS_BEGIN; i < INT64_FIELDS_END; ++i) { |
| 16 int64_fields[i] = 0; | 17 int64_fields[i] = 0; |
| 17 } | 18 } |
| 18 } | 19 } |
| 19 | 20 |
| 20 EntryKernel::~EntryKernel() {} | 21 EntryKernel::~EntryKernel() {} |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 } | 142 } |
| 142 | 143 |
| 143 DictionaryValue* EntryKernelMutationToValue( | 144 DictionaryValue* EntryKernelMutationToValue( |
| 144 const EntryKernelMutation& mutation) { | 145 const EntryKernelMutation& mutation) { |
| 145 DictionaryValue* dict = new DictionaryValue(); | 146 DictionaryValue* dict = new DictionaryValue(); |
| 146 dict->Set("original", mutation.original.ToValue()); | 147 dict->Set("original", mutation.original.ToValue()); |
| 147 dict->Set("mutated", mutation.mutated.ToValue()); | 148 dict->Set("mutated", mutation.mutated.ToValue()); |
| 148 return dict; | 149 return dict; |
| 149 } | 150 } |
| 150 | 151 |
| 151 } | 152 } // namespace syncer |
| 153 } // namespace syncable |
| OLD | NEW |