KiCad PCB EDA Suite
|
Custom validator that checks verifies that a string exactly matches a regular expression. More...
#include <validators.h>
Public Member Functions | |
REGEX_VALIDATOR (const wxString &aRegEx, wxString *aValue=nullptr) | |
REGEX_VALIDATOR (const wxString &aRegEx, int aFlags, wxString *aValue=nullptr) | |
REGEX_VALIDATOR (const REGEX_VALIDATOR &aOther) | |
virtual wxObject * | Clone () const override |
bool | Validate (wxWindow *aParent) override |
const wxString & | GetRegEx () const |
Protected Member Functions | |
void | compileRegEx (const wxString &aRegEx, int aFlags) |
Compiles and stores a regular expression. | |
Protected Attributes | |
wxString | m_regExString |
Original regular expression (for copy constructor). | |
int | m_regExFlags |
Original compilation flags (for copy constructor). | |
wxRegEx | m_regEx |
Compiled regular expression. | |
Custom validator that checks verifies that a string exactly matches a regular expression.
Definition at line 115 of file validators.h.
|
inline |
aRegEx | is a regular expression to validate strings. |
aValue | is a pointer to a wxString containing the value to validate. |
Definition at line 122 of file validators.h.
References compileRegEx().
|
inline |
aRegEx | is a regular expression to validate strings. |
aFlags | are compilation flags (normally wxRE_DEFAULT). |
aValue | is a pointer to a wxString containing the value to validate. |
Definition at line 133 of file validators.h.
References compileRegEx().
|
inline |
Definition at line 139 of file validators.h.
References compileRegEx(), m_regExFlags, and m_regExString.
|
inlineoverridevirtual |
Definition at line 144 of file validators.h.
|
protected |
Compiles and stores a regular expression.
Definition at line 232 of file validators.cpp.
References m_regEx, m_regExFlags, and m_regExString.
Referenced by REGEX_VALIDATOR().
|
inline |
Definition at line 151 of file validators.h.
References m_regExString.
|
override |
Definition at line 194 of file validators.cpp.
References _, DisplayErrorMessage(), and m_regEx.
|
protected |
Compiled regular expression.
Definition at line 167 of file validators.h.
Referenced by compileRegEx(), and Validate().
|
protected |
Original compilation flags (for copy constructor).
Definition at line 164 of file validators.h.
Referenced by compileRegEx(), and REGEX_VALIDATOR().
|
protected |
Original regular expression (for copy constructor).
Definition at line 161 of file validators.h.
Referenced by compileRegEx(), GetRegEx(), and REGEX_VALIDATOR().