42 #ifndef QTEMPORARYFILE_H 43 #define QTEMPORARYFILE_H 45 #include <QtCore/qiodevice.h> 46 #include <QtCore/qfile.h> 49 #error qtemporaryfile.h must be included before any header file that defines open 58 #ifndef QT_NO_TEMPORARYFILE 78 bool autoRemove()
const;
79 void setAutoRemove(
bool b);
89 {
QFile file(fileName);
return createLocalFile(file); }
95 bool open(OpenMode flags);
102 #endif // QT_NO_TEMPORARYFILE 108 #endif // QTEMPORARYFILE_H QString fileName() const
Returns the name set by setFileName() or to the QFile constructors.
#define QT_END_NAMESPACE
This macro expands to.
bool open(OpenMode flags)
Opens the file using OpenMode mode, returning true if successful; otherwise false.
static QTemporaryFile * createLocalFile(const QString &fileName)
This is an overloaded member function, provided for convenience. It differs from the above function o...
The QTemporaryFile class is an I/O device that operates on temporary files.
virtual QAbstractFileEngine * fileEngine() const
Returns the QIOEngine for this QFile object.
bool open()
A QTemporaryFile will always be opened in QIODevice::ReadWrite mode, this allows easy access to the d...
#define Q_DISABLE_COPY(Class)
Disables the use of copy constructors and assignment operators for the given Class.
The QString class provides a Unicode character string.
The QObject class is the base class of all Qt objects.
#define QT_BEGIN_NAMESPACE
This macro expands to.
The QAbstractFileEngine class provides an abstraction for accessing the filesystem.
The QFile class provides an interface for reading from and writing to files.
#define Q_DECLARE_PRIVATE(Class)