Content


NTL
Core
CDbValidatorMatch

CDbValidatorMatch


Match validator checks whether an attribute value corresponds to the specified pattern.

You can find more information in comments below. Overrided methods can be found in corresponding base class or interface.

class CDbValidatorMatch :public CDbValidator
{
public:
    // IDbValidator methods 
    bool Validate(CDbModel *model, IDbAttribute *attribute, String &error) override;

    CDbValidatorMatch();

    CDbValidatorMatch *setNot(const bool &value); // Set whether to inverse comparison (NOT match) 
    CDbValidatorMatch *setPattern(const String &value); // Set pattern (regular expression) to compare against 

    static ReleasablePtr<CDbValidatorMatch> Create(); // Helper static method to create validator in form used in model rule adding methods 
};
Namespace: nitisa
Include: Nitisa/Db/DbValidatorMatch.h