1 /*
2  * Copyright 2013-2015  Christian Dávid <christian-david@web.de>
3  *
4  * This program is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU General Public License as
6  * published by the Free Software Foundation; either version 2 of
7  * the License, or (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
16  */
17 
18 #ifndef BICVALIDATOR_H
19 #define BICVALIDATOR_H
20 
21 #include <QValidator>
22 #include "kmm_widgets_export.h"
23 #include "kmymoneyvalidationfeedback.h"
24 
25 namespace eWidgets { namespace ValidationFeedback { enum class MessageType; } }
26 
27 class KMM_WIDGETS_EXPORT bicValidator : public QValidator
28 {
29   Q_OBJECT
30 
31 public:
32   explicit bicValidator(QObject* parent = 0);
33   QValidator::State validate(QString& , int&) const final override;
34 
35   static QPair<eWidgets::ValidationFeedback::MessageType, QString> validateWithMessage(const QString&);
36 };
37 
38 #endif // BICVALIDATOR_H
39