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
qqmljsusercontextproperties_p.h
Go to the documentation of this file.
1
// Copyright (C) 2025 The Qt Company Ltd.
2
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
3
// Qt-Security score:significant
4
5
#
ifndef
QQMLJSUSERCONTEXTPROPERTIES_P_H
6
#
define
QQMLJSUSERCONTEXTPROPERTIES_P_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
#
include
<
QtQmlToolingSettings
/
private
/
qqmltoolingsettings_p
.
h
>
19
#
include
<
qtqmlcompilerexports
.
h
>
20
21
QT_BEGIN_NAMESPACE
22
23
namespace
QQmlJS
{
24
25
class
Q_QMLCOMPILER_EXPORT
UserContextProperties
26
{
27
public
:
28
static
constexpr
inline
QLatin1StringView
s_unqualifiedAccessDisabledKey
=
29
QLatin1String
(
"disableUnqualifiedAccess"
);
30
static
constexpr
inline
QLatin1StringView
s_onUsageWarnedKey
=
QLatin1String
(
"warnOnUsage"
);
31
static
constexpr
inline
QLatin1StringView
s_disableHeuristic
=
32
QLatin1String
(
"disableHeuristic"
);
33
34
UserContextProperties
() =
default
;
35
UserContextProperties
(
const
QQmlToolingSettings
&
settings
);
36
37
bool
isUnqualifiedAccessDisabled
(
const
QString
&
name
)
const
38
{
39
return
m_unqualifiedAccessDisabled
.
contains
(
name
);
40
}
41
QList
<
QString
>
unqualifiedAccessDisabled
()
const
{
return
m_unqualifiedAccessDisabled
; }
42
43
bool
isOnUsageWarned
(
const
QString
&
name
)
const
{
return
m_onUsageWarned
.
contains
(
name
); }
44
QList
<
QString
>
onUsageWarned
()
const
{
return
m_onUsageWarned
; }
45
46
bool
isHeuristicDisabled
()
const
{
return
m_disableHeuristic
; }
47
48
private
:
49
void
setUnqualifiedAccessDisabled
(
const
QList
<
QString
> &
unqualifiedAccessDisabled
)
50
{
51
m_unqualifiedAccessDisabled
=
unqualifiedAccessDisabled
;
52
}
53
void
setOnUsagedWarned
(
const
QList
<
QString
> &
onUsageWarned
) {
m_onUsageWarned
=
onUsageWarned
; }
54
void
setIsHeuristicDisabled
(
bool
newDisableHeuristic
)
55
{
56
m_disableHeuristic
=
newDisableHeuristic
;
57
}
58
59
QList
<
QString
>
m_unqualifiedAccessDisabled
= {};
60
QList
<
QString
>
m_onUsageWarned
= {};
61
bool
m_disableHeuristic
=
false
;
62
};
63
64
}
// namespace QQmlJS
65
66
QT_END_NAMESPACE
67
68
#
endif
// QQMLJSUSERCONTEXTPROPERTIES_P_H
QQmlJS::UserContextProperties
Definition
qqmljsusercontextproperties_p.h:26
QPlatformGraphicsBufferHelper
\inmodule QtGui
QQmlJS
Definition
qv4bytecodegenerator_p.h:26
qtdeclarative
src
qmlcompiler
qqmljsusercontextproperties_p.h
Generated on
for Qt by
1.14.0