![]() |
HAL
|
#include <hexadecimal_validator.h>
Public Member Functions | |
HexadecimalValidator () | |
bool | validate (const QString &input) |
![]() | |
void | setFailText (const QString &text) |
QString | failText () const |
Additional Inherited Members | |
![]() | |
QString | mFailText = "Chosen input is not allowed." |
The HexadecimalValidator class checks if a string is in a valid hexadecimal format (uses symbols 0-9, a-f). Its validate function returns true if that is the case.
Definition at line 37 of file hexadecimal_validator.h.
hal::HexadecimalValidator::HexadecimalValidator | ( | ) |
Definition at line 5 of file hexadecimal_validator.cpp.
References QRegularExpression::CaseInsensitiveOption, hal::Validator::setFailText(), and QRegularExpressionValidator::setRegularExpression().
|
virtual |
Given any string this function returns true if the string is in the hexadecimal format (0-9, a-f). The matches are case insensitive.
input | - The input string |
Implements hal::Validator.
Definition at line 12 of file hexadecimal_validator.cpp.
References hal::input, and QRegularExpressionValidator::validate().