Class TApplicationStatePersister
TApplicationStatePersister class.
TApplicationStatePersister provides a file-based persistent storage for application state. Application state, when serialized, is stored in a file named 'global.cache' under the 'runtime' directory of the application. Cache will be exploited if it is enabled.
Method Summary |
protected
string
|
|
void
|
Initializes module.
|
mixed
|
Loads application state from persistent storage.
|
void
|
Saves application state in persistent storage.
|
Methods Inherited From TComponent |
TComponent::addParsedObject(), TComponent::attachEventHandler(), TComponent::canGetProperty(), TComponent::canSetProperty(), TComponent::createdOnTemplate(), TComponent::detachEventHandler(), TComponent::evaluateExpression(), TComponent::evaluateStatements(), TComponent::getEventHandlers(), TComponent::getSubProperty(), TComponent::hasEvent(), TComponent::hasEventHandler(), TComponent::hasProperty(), TComponent::raiseEvent(), TComponent::setSubProperty(), TComponent::__get(), TComponent::__set()
|
Constant Summary |
string
|
CACHE_NAME |
Name of the value stored in cache
|
Method Details |
getStateFilePath
protected string getStateFilePath |
() |
Output |
string
| the file path storing the application state |
Exception |
|
init
Initializes module.
Input |
TXmlElement | $config | module configuration (may be null) |
Output |
Exception |
|
load
Loads application state from persistent storage.
Output |
mixed
| application state |
Exception |
|
save
public void save |
(mixed $state ) |
Saves application state in persistent storage.
Input |
mixed | $state | application state |
Output |
Exception |
|
Constant Details |
CACHE_NAME
Name of the value stored in cache
Type:
string
Value:
'prado:appstate'
|
|