| Index: third_party/WebKit/Source/modules/payments/PaymentsValidators.h
|
| diff --git a/third_party/WebKit/Source/modules/payments/PaymentsValidators.h b/third_party/WebKit/Source/modules/payments/PaymentsValidators.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..837d68d7e8c912a09c3b015c0df21b046b344a34
|
| --- /dev/null
|
| +++ b/third_party/WebKit/Source/modules/payments/PaymentsValidators.h
|
| @@ -0,0 +1,30 @@
|
| +// Copyright 2016 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef PaymentsValidators_h
|
| +#define PaymentsValidators_h
|
| +
|
| +#include "modules/ModulesExport.h"
|
| +#include "wtf/text/WTFString.h"
|
| +
|
| +namespace blink {
|
| +
|
| +// Returns true if |code| is a valid ISO 4217 currency code.
|
| +bool MODULES_EXPORT isValidCurrencyCodeFormat(const String& code, String* optionalErrorMessage);
|
| +
|
| +// Returns true if |amount| is a valid currency code as defined in ISO 20022 CurrencyAnd30Amount.
|
| +bool MODULES_EXPORT isValidAmountFormat(const String& amount, String* optionalErrorMessage);
|
| +
|
| +// Returns true if |code| is a valid ISO 3166 country code.
|
| +bool MODULES_EXPORT isValidRegionCodeFormat(const String& code, String* optionalErrorMessage);
|
| +
|
| +// Returns true if |code| is a valid ISO 639 language code.
|
| +bool MODULES_EXPORT isValidLanguageCodeFormat(const String& code, String* optionalErrorMessage);
|
| +
|
| +// Returns true if |code| is a valid ISO 1524 script code.
|
| +bool MODULES_EXPORT isValidScriptCodeFormat(const String& code, String* optionalErrorMessage);
|
| +
|
| +} // namespace blink
|
| +
|
| +#endif // PaymentsValidators_h
|
|
|