Validator classes validate data before their GUI representation is closed by the user. The validator class also takes care of informing the user where the data is invalid.
This prevents the user from entering invalid data into the model or flushing it to the database.
Bases: camelot.admin.validator.object_validator.ObjectValidator
A validator class validates an entity before flushing it to the database and provides the user with feedback if the entity is not ready to flush
Bases: PyQt4.QtCore.QObject
A validator class for normal python objects. By default this validator declares all objects valid. Subclass this class and overwrite it’s objectValidity method to change it’s behaviour.
Verify if a row in a model is ‘valid’ meaning it could be flushed to the database
Returns: | the number of invalid rows in a model, as they have been verified |
---|
Returns: | list of messages explaining invalid data |
---|
empty list if object is valid
Return a QDialog that asks the user to discard his changes or continue to edit the row until it is valid.