tuchulcha  0.10.1
Graphical Workflow Configuration Editor
PrefixValidator Class Reference

Validator for prefix edit widgets. More...

#include <PrefixValidator.h>

Inheritance diagram for PrefixValidator:

Public Member Functions

 PrefixValidator (const QParameterFile &data, QObject *parent=0)
 default constructor More...
 
virtual void fixup (QString &input) const
 Fix given input string. More...
 
virtual QValidator::State validate (QString &input, int &pos) const
 Validate input string. More...
 

Private Attributes

const QParameterFile_parameterFile
 parent ParameterFile
 

Detailed Description

It serves to check if an entered prefix is valid or not.

Definition at line 32 of file PrefixValidator.h.

Constructor & Destructor Documentation

PrefixValidator::PrefixValidator ( const QParameterFile data,
QObject *  parent = 0 
)
Parameters
datainput parameter file
parentparent object

Definition at line 27 of file PrefixValidator.cpp.

Member Function Documentation

void PrefixValidator::fixup ( QString &  input) const
virtual

This function attempts to change input to be valid according to this validator's rules. Here, the first compatible prefix will be returned, if there is no such prefix, nothing happens.

Parameters
inputinput string

Definition at line 46 of file PrefixValidator.cpp.

References _parameterFile, and QParameterFile::getKeyList().

QValidator::State PrefixValidator::validate ( QString &  input,
int &  pos 
) const
virtual

This virtual function returns Invalid if input is invalid according to this validator's rules, Intermediate if it is likely that a little more editing will make the input acceptable (e.g. the user types "inp" when "input" is a valid prefix), and Acceptable if the input is valid.

Parameters
inputinput string
poscurrent editing position
Returns
validation result

Definition at line 33 of file PrefixValidator.cpp.

References _parameterFile, and QParameterFile::getKeyList().


The documentation for this class was generated from the following files: