QHttpEngine 0.1.0
Simple and secure HTTP server for Qt applications
|
Locally accessible file. More...
#include <QHttpEngine/QLocalFile>
Public Member Functions | |
QLocalFile (QObject *parent=0) | |
Create a new local file. | |
bool | open () |
Attempt to open the file. | |
QLocalFile uses platform-specific functions to create a file containing information that will be accessible only to the local user. This is typically used for storing authentication tokens:
By default, the file is stored in the user's home directory and the name of the file is derived from the value of QCoreApplication::applicationName(). For example, if the application name was "test" and the user's home directory was /home/bob
, the absolute path would be /home/bob/.test
.
bool QLocalFile::open | ( | ) |
The file must be opened before data can be read or written. This method will return false if the underlying file could not be opened or if this class was unable to set the appropriate file permissions.