Public Slots | Public Member Functions | List of all members
pqAutoSaveBehavior Class Reference

: pqAutoSaveBehavior save states automatically in the background. More...

#include <pqAutoSaveBehavior.h>

Inherits QObject.

Public Slots

static void saveState ()
 Saves the state. More...
 
static QDir getStateDirectory ()
 Return the directory where to write the state. More...
 
static bool autoSaveSettingEnabled ()
 Return true if the AutoSave settings is enabled. More...
 
static void setAutoSaveSetting (bool enable)
 Set the AutoSave Setting to "enable". More...
 
static pqApplicationCore::StateFileFormat getStateFormat ()
 Return the file format for the statefile, as defined in the settings. More...
 

Public Member Functions

 pqAutoSaveBehavior (QObject *parent=nullptr)
 
 ~pqAutoSaveBehavior () override
 

Detailed Description

: pqAutoSaveBehavior save states automatically in the background.

On every significant change, as a pipeline update or a rendering, it writes a new statefile and backup the previous one. The target directory can be defined in the settings. By default, the standard platform-dependent AppData directory is used. See pqCoreUtilities::getParaViewApplicationDataDirectory().

The file format can be chosen with the AutoSaveStateFormat setting.

The features can be (de)activated through the AutoSave setting.

Definition at line 29 of file pqAutoSaveBehavior.h.

Constructor & Destructor Documentation

◆ pqAutoSaveBehavior()

pqAutoSaveBehavior::pqAutoSaveBehavior ( QObject *  parent = nullptr)

◆ ~pqAutoSaveBehavior()

pqAutoSaveBehavior::~pqAutoSaveBehavior ( )
override

Member Function Documentation

◆ saveState

static void pqAutoSaveBehavior::saveState ( )
staticslot

Saves the state.

First make a copy of the previous state as a .bak file.

Uses format and directory from settings. Default to pvsm and pqCoreUtilities::getParaViewApplicationDataDirectory()

◆ getStateDirectory

static QDir pqAutoSaveBehavior::getStateDirectory ( )
staticslot

Return the directory where to write the state.

Uses user-defined directory (from settings) or standard one if empty. See pqCoreUtilities::getParaViewApplicationDataDirectory()

◆ autoSaveSettingEnabled

static bool pqAutoSaveBehavior::autoSaveSettingEnabled ( )
staticslot

Return true if the AutoSave settings is enabled.

◆ setAutoSaveSetting

static void pqAutoSaveBehavior::setAutoSaveSetting ( bool  enable)
staticslot

Set the AutoSave Setting to "enable".

◆ getStateFormat

static pqApplicationCore::StateFileFormat pqAutoSaveBehavior::getStateFormat ( )
staticslot

Return the file format for the statefile, as defined in the settings.

Default to StateFormat::PVSM.


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