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

Side by Side Diff: third_party/WebKit/Source/modules/payments/PaymentsValidators.h

Issue 2020913002: PaymentRequest: Rename ShippingAddress to PaymentAddress. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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 2016 The Chromium Authors. All rights reserved. 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 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 #ifndef PaymentsValidators_h 5 #ifndef PaymentsValidators_h
6 #define PaymentsValidators_h 6 #define PaymentsValidators_h
7 7
8 #include "modules/ModulesExport.h" 8 #include "modules/ModulesExport.h"
9 #include "public/platform/modules/payments/payment_request.mojom-blink.h" 9 #include "public/platform/modules/payments/payment_request.mojom-blink.h"
10 #include "wtf/Allocator.h" 10 #include "wtf/Allocator.h"
(...skipping 13 matching lines...) Expand all
24 24
25 // Returns true if |code| is a valid ISO 3166 country code. 25 // Returns true if |code| is a valid ISO 3166 country code.
26 static bool isValidRegionCodeFormat(const String& code, String* optionalErro rMessage); 26 static bool isValidRegionCodeFormat(const String& code, String* optionalErro rMessage);
27 27
28 // Returns true if |code| is a valid ISO 639 language code. 28 // Returns true if |code| is a valid ISO 639 language code.
29 static bool isValidLanguageCodeFormat(const String& code, String* optionalEr rorMessage); 29 static bool isValidLanguageCodeFormat(const String& code, String* optionalEr rorMessage);
30 30
31 // Returns true if |code| is a valid ISO 15924 script code. 31 // Returns true if |code| is a valid ISO 15924 script code.
32 static bool isValidScriptCodeFormat(const String& code, String* optionalErro rMessage); 32 static bool isValidScriptCodeFormat(const String& code, String* optionalErro rMessage);
33 33
34 // Returns true if the shipping address is valid: 34 // Returns true if the shipping address is valid:
please use gerrit instead 2016/05/31 01:44:43 s/shipping/payment/
zino 2016/05/31 02:58:30 Done.
35 // - Has a valid region code 35 // - Has a valid region code
36 // - Has a valid language code, if any. 36 // - Has a valid language code, if any.
37 // - Has a valid script code, if any. 37 // - Has a valid script code, if any.
38 // A script code should be present only if language code is present. 38 // A script code should be present only if language code is present.
39 static bool isValidShippingAddress(const mojom::blink::ShippingAddressPtr&, String* optionalErrorMessage); 39 static bool isValidShippingAddress(const mojom::blink::PaymentAddressPtr&, S tring* optionalErrorMessage);
40 }; 40 };
41 41
42 } // namespace blink 42 } // namespace blink
43 43
44 #endif // PaymentsValidators_h 44 #endif // PaymentsValidators_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698