Bitcoin ABC 0.26.3
P2P Digital Currency
Loading...
Searching...
No Matches
bitcoinaddressvalidator.h
Go to the documentation of this file.
1// Copyright (c) 2011-2014 The Bitcoin Core developers
2// Copyright (c) 2017-2018 The Bitcoin developers
3// Distributed under the MIT software license, see the accompanying
4// file COPYING or http://www.opensource.org/licenses/mit-license.php.
5
6#ifndef BITCOIN_QT_BITCOINADDRESSVALIDATOR_H
7#define BITCOIN_QT_BITCOINADDRESSVALIDATOR_H
8
9#include <QValidator>
10
15class BitcoinAddressEntryValidator : public QValidator {
17
18public:
19 explicit BitcoinAddressEntryValidator(const std::string &cashaddrprefixIn,
20 QObject *parent);
21
22 State validate(QString &input, int &pos) const override;
23
24private:
25 std::string cashaddrprefix;
26};
27
30class BitcoinAddressCheckValidator : public QValidator {
32
33public:
34 explicit BitcoinAddressCheckValidator(QObject *parent);
35
36 State validate(QString &input, int &pos) const override;
37};
38
39#endif // BITCOIN_QT_BITCOINADDRESSVALIDATOR_H
Bitcoin address widget validator, checks for a valid bitcoin address.
State validate(QString &input, int &pos) const override
Bitcoin address entry widget validator, checks for valid characters and removes some whitespace.
State validate(QString &input, int &pos) const override
std::string cashaddrprefix
T GetRand(T nMax=std::numeric_limits< T >::max()) noexcept
Generate a uniform random integer of type T in the range [0..nMax) nMax defaults to std::numeric_limi...
Definition random.h:85