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

Side by Side Diff: components/payments/content/utility/payment_manifest_parser.cc

Issue 2759283002: Make payment manifest download/parse cross-platform (Closed)
Patch Set: Address comments Created 3 years, 9 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
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 "components/payments/content/android/utility/payment_manifest_parser.h" 5 #include "components/payments/content/utility/payment_manifest_parser.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <memory> 9 #include <memory>
10 #include <utility> 10 #include <utility>
11 11
12 #include "base/json/json_reader.h" 12 #include "base/json/json_reader.h"
13 #include "base/memory/ptr_util.h" 13 #include "base/memory/ptr_util.h"
14 #include "base/strings/string_util.h" 14 #include "base/strings/string_util.h"
15 #include "base/values.h" 15 #include "base/values.h"
16 #include "components/payments/content/android/utility/fingerprint_parser.h" 16 #include "components/payments/content/utility/fingerprint_parser.h"
17 #include "mojo/public/cpp/bindings/strong_binding.h" 17 #include "mojo/public/cpp/bindings/strong_binding.h"
18 18
19 namespace payments { 19 namespace payments {
20 20
21 // static 21 // static
22 void PaymentManifestParser::Create( 22 void PaymentManifestParser::Create(
23 mojom::PaymentManifestParserRequest request) { 23 mojom::PaymentManifestParserRequest request) {
24 mojo::MakeStrongBinding(base::MakeUnique<PaymentManifestParser>(), 24 mojo::MakeStrongBinding(base::MakeUnique<PaymentManifestParser>(),
25 std::move(request)); 25 std::move(request));
26 } 26 }
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 PaymentManifestParser::PaymentManifestParser() {} 133 PaymentManifestParser::PaymentManifestParser() {}
134 134
135 PaymentManifestParser::~PaymentManifestParser() {} 135 PaymentManifestParser::~PaymentManifestParser() {}
136 136
137 void PaymentManifestParser::Parse(const std::string& content, 137 void PaymentManifestParser::Parse(const std::string& content,
138 const ParseCallback& callback) { 138 const ParseCallback& callback) {
139 callback.Run(ParseIntoVector(content)); 139 callback.Run(ParseIntoVector(content));
140 } 140 }
141 141
142 } // namespace payments 142 } // namespace payments
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698