Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qv4compilationunitmapper_p.h
Go to the documentation of this file.
1// Copyright (C) 2016 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3// Qt-Security score:significant
4
5#ifndef QV4COMPILATIONUNITMAPPER_H
6#define QV4COMPILATIONUNITMAPPER_H
7
8//
9// W A R N I N G
10// -------------
11//
12// This file is not part of the Qt API. It exists purely as an
13// implementation detail. This header file may change from version to
14// version without notice, or even be removed.
15//
16// We mean it.
17//
18
19#include <private/qv4global_p.h>
20#include <QFile>
21
22QT_BEGIN_NAMESPACE
23
24namespace QV4 {
25
26namespace CompiledData {
27struct Unit;
28}
29
31{
32public:
34 const QString &cacheFilePath, const QDateTime &sourceTimeStamp, QString *errorString);
35 static void invalidate(const QString &cacheFilePath);
36
37private:
38 CompiledData::Unit *open(
39 const QString &cacheFilePath, const QDateTime &sourceTimeStamp, QString *errorString);
40 void close();
41
42#if defined(Q_OS_UNIX)
43 size_t length = 0;
44#endif
45 void *dataPtr = nullptr;
46};
47
48}
49
50QT_END_NAMESPACE
51
52#endif // QV4COMPILATIONUNITMAPPER_H
static void invalidate(const QString &cacheFilePath)
CompiledData::Unit * get(const QString &cacheFilePath, const QDateTime &sourceTimeStamp, QString *errorString)
CompilationUnitMapper get(const QString &file)
void set(const QString &file, const CompilationUnitMapper &staticUnit)
void remove(const QString &file)
Definition qjsvalue.h:23