Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(98)

Side by Side Diff: blimp/helium/serializable_struct.cc

Issue 2602103002: Delete blimp/helium and remove references to it from dependent targets (Closed)
Patch Set: . Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « blimp/helium/serializable_struct.h ('k') | blimp/helium/serializable_struct_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2016 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 #include "blimp/helium/serializable_struct.h"
6
7 namespace blimp {
8 namespace helium {
9
10 SerializableStruct::SerializableStruct() {}
11
12 SerializableStruct::~SerializableStruct() {}
13
14 bool SerializableStruct::Parse(
15 google::protobuf::io::CodedInputStream* input_stream) {
16 for (auto* field : fields_) {
17 if (!field->Parse(input_stream)) {
18 return false;
19 }
20 }
21 return true;
22 }
23
24 void SerializableStruct::Serialize(
25 google::protobuf::io::CodedOutputStream* output_stream) const {
26 for (const auto* field : fields_) {
27 field->Serialize(output_stream);
28 }
29 }
30
31 SerializableStruct::FieldBase::FieldBase() {}
32
33 SerializableStruct::FieldBase::~FieldBase() {}
34
35 void SerializableStruct::FieldBase::RegisterWith(
36 SerializableStruct* container) {
37 container->fields_.push_back(this);
38 }
39
40 } // namespace helium
41 } // namespace blimp
OLDNEW
« no previous file with comments | « blimp/helium/serializable_struct.h ('k') | blimp/helium/serializable_struct_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698