![]() |
QxOrm 1.4.9
C++ Object Relational Mapping library
|
qx::QxValidator<Owner> : concrete class for a custom validator More...
#include <QxValidator.h>
Public Types | |
typedef std::function< void(Owner *, QxInvalidValueX &)> | type_fct_custom_validator_member |
typedef std::function< void(const QVariant &, QxInvalidValueX &)> | type_fct_custom_validator_variant |
typedef std::function< void(const QVariant &, const IxValidator *, QxInvalidValueX &)> | type_fct_custom_validator_variant_validator |
![]() | |
enum | validator_type { not_null , not_empty , min_value , max_value , min_length , max_length , date_past , date_future , min_decimal , max_decimal , regular_expression , e_mail , recursive_validator , custom_validator } |
Public Member Functions | |
QxValidator () | |
virtual | ~QxValidator () |
void | setFunction (type_fct_custom_validator_member fct) |
void | setFunction (type_fct_custom_validator_variant fct) |
void | setFunction (type_fct_custom_validator_variant_validator fct) |
virtual void | validate (void *pOwner, QxInvalidValueX &lstInvalidValues) const |
![]() | |
IxValidator (validator_type type) | |
virtual | ~IxValidator () |
validator_type | getType () const |
QString | getMessage () const |
QString | getGroup () const |
QVariant | getConstraint () const |
QVariantList | getConstraints () const |
IxDataMember * | getDataMember () const |
void | setMessage (const QString &s) |
void | setGroup (const QString &s) |
void | setConstraint (const QVariant &v) |
void | setConstraints (const QVariantList &lst) |
void | setDataMember (IxDataMember *p) |
![]() | |
QxPropertyBag () | |
virtual | ~QxPropertyBag () |
void | setPropertyBag (const QString &key, const QVariant &value) |
QVariant | getPropertyBag (const QString &key) const |
void | removePropertyBag (const QString &key) |
void | clearPropertyBag () |
long | countPropertyBag () const |
QList< QString > | getAllPropertyBagKeys () const |
Protected Attributes | |
type_fct_custom_validator_member | m_fctCustomValidator_Member |
Custom validator function : class method. | |
type_fct_custom_validator_variant | m_fctCustomValidator_Variant |
Custom validator function : global function with value converted to QVariant type. | |
type_fct_custom_validator_variant_validator | m_fctCustomValidator_VariantValidator |
Custom validator function : global function with value converted to QVariant type and a IxValidator pointer containing all parameters. | |
![]() | |
validator_type | m_type |
Validator type. | |
QString | m_message |
Validator message when invalid value is detected. | |
QString | m_group |
Validator group. | |
QVariantList | m_Constraints |
List of constraints to verify. | |
IxDataMember * | m_pDataMember |
Registered property associated to validator. | |
![]() | |
type_hash_prop_bag_ptr | m_lstPropertyBag |
List of all properties in the bag (meta-data) | |
Additional Inherited Members | |
![]() | |
typedef QHash< QString, QVariant > | type_hash_prop_bag |
typedef std::shared_ptr< type_hash_prop_bag > | type_hash_prop_bag_ptr |
![]() | |
void | initDefaultMessage () |
void | validateNotNull (const QVariant &v, QxInvalidValueX &lstInvalidValues) const |
void | validateNotEmpty (const QVariant &v, QxInvalidValueX &lstInvalidValues) const |
void | validateMinValue (const QVariant &v, QxInvalidValueX &lstInvalidValues) const |
void | validateMaxValue (const QVariant &v, QxInvalidValueX &lstInvalidValues) const |
void | validateMinDecimal (const QVariant &v, QxInvalidValueX &lstInvalidValues) const |
void | validateMaxDecimal (const QVariant &v, QxInvalidValueX &lstInvalidValues) const |
void | validateMinLength (const QVariant &v, QxInvalidValueX &lstInvalidValues) const |
void | validateMaxLength (const QVariant &v, QxInvalidValueX &lstInvalidValues) const |
void | validateDatePast (const QVariant &v, QxInvalidValueX &lstInvalidValues) const |
void | validateDateFuture (const QVariant &v, QxInvalidValueX &lstInvalidValues) const |
void | validateRegularExpression (const QVariant &v, QxInvalidValueX &lstInvalidValues) const |
void | validateEMail (const QVariant &v, QxInvalidValueX &lstInvalidValues) const |
qx::QxValidator<Owner> : concrete class for a custom validator
For more informations about QxValidator module, goto the FAQ of QxOrm website : https://www.qxorm.com/qxorm_en/faq.html#faq_250
Definition at line 64 of file QxValidator.h.
typedef std::function<void (Owner *, QxInvalidValueX &)> qx::QxValidator< Owner >::type_fct_custom_validator_member |
Definition at line 69 of file QxValidator.h.
typedef std::function<void (const QVariant &, QxInvalidValueX &)> qx::QxValidator< Owner >::type_fct_custom_validator_variant |
Definition at line 70 of file QxValidator.h.
typedef std::function<void (const QVariant &, const IxValidator *, QxInvalidValueX &)> qx::QxValidator< Owner >::type_fct_custom_validator_variant_validator |
Definition at line 71 of file QxValidator.h.
|
inline |
Definition at line 81 of file QxValidator.h.
|
inlinevirtual |
Definition at line 82 of file QxValidator.h.
|
inline |
Definition at line 84 of file QxValidator.h.
|
inline |
Definition at line 85 of file QxValidator.h.
|
inline |
Definition at line 86 of file QxValidator.h.
|
inlinevirtual |
Reimplemented from qx::IxValidator.
Definition at line 88 of file QxValidator.h.
|
protected |
Custom validator function : class method.
Definition at line 75 of file QxValidator.h.
|
protected |
Custom validator function : global function with value converted to QVariant type.
Definition at line 76 of file QxValidator.h.
|
protected |
Custom validator function : global function with value converted to QVariant type and a IxValidator pointer containing all parameters.
Definition at line 77 of file QxValidator.h.