Version: 8.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
LightApp_PyFileValidator Class Reference

Validator for Python scripts file names.

#include <LightApp_FileValidator.h>

Inheritance diagram for LightApp_PyFileValidator:
Inheritance graph

Public Member Functions

 LightApp_PyFileValidator (QWidget *)
 Constructor. More...
 
virtual bool canSave (const QString &, bool)
 Check if the specified file can be written. More...
 
- Public Member Functions inherited from SUIT_FileValidator
 SUIT_FileValidator (QWidget *=0)
 Constructor. More...
 
virtual ~SUIT_FileValidator ()
 
virtual bool canOpen (const QString &, bool=true)
 Check if the specified file exists and (optionally) can be read. More...
 
virtual bool canReadDir (const QString &, bool=true)
 Check if the specified directory exists and (optionally) can be read. More...
 
virtual bool canWriteDir (const QString &, bool=true)
 Check if the specified directory can be written. More...
 
QWidgetparent () const
 Get parent widget. More...
 

Constructor & Destructor Documentation

LightApp_PyFileValidator::LightApp_PyFileValidator ( QWidget parent)
Parameters
parentparent widget

Member Function Documentation

bool LightApp_PyFileValidator::canSave ( const QString &  fileName,
bool  checkPermission 
)
virtual

Checks if file name is valid for Python script.

Parameters
fileNamefile path
checkPermissionif true (default) check also file permissions
Returns
false if file exists and user rejects file overwriting or if file does not have write permissions (if checkPermission is true)
See Also
SUIT_FileValidator

Reimplemented from SUIT_FileValidator.

References SUIT_FileValidator::canSave(), SUIT_MessageBox::critical(), and SUIT_FileValidator::parent().


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