BPS C++ API  2.24.4
bpsmaskvalidator.h
Go to the documentation of this file.
1 
4 #ifndef BPSMASKVALIDATOR_H
5 #define BPSMASKVALIDATOR_H
6 
7 #include "bpsgui_global.h"
8 #include <QValidator>
9 
16 {
17  Q_OBJECT
19 
20 public:
25 
30  BpsMaskValidator(const QString& aMask, QObject* aParent);
31 
33  virtual ~BpsMaskValidator();
34  virtual State validate(QString& aInput, int& aPos) const;
35  virtual void fixup(QString& aInput) const;
37 
41  QString mask() const;
42 
47  void setMask(const QString& aMask);
48 
52  int maxLength() const;
53 
57  int minLength() const;
58 };
59 
60 #endif // BPSMASKVALIDATOR_H
#define BPS_PRIVATE(Class)
Declare pointer to private object in a public class.
Definition: bpsglobals.h:102
Public include file for BPS GUI library macros.
#define BPSGUI_EXPORT
Declare class an import from the shared library.
Definition: bpsgui_global.h:22
This class implements the BPS mask validator for input text.
Definition: bpsmaskvalidator.h:16
int minLength() const
Returns the minimum input length (including fillers)
BpsMaskValidator(const QString &aMask, QObject *aParent)
QString mask() const
BpsMaskValidator(QObject *aParent)
int maxLength() const
Returns the maximum input length (including fillers)
void setMask(const QString &aMask)
Set the new mask.
virtual void fixup(QString &input) const const
virtual QValidator::State validate(QString &input, int &pos) const const=0