Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Toggle main menu visibility
Loading...
Searching...
No Matches
qqmlexpression.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
QQMLEXPRESSION_H
6
#
define
QQMLEXPRESSION_H
7
8
#
include
<
QtQml
/
qqmlerror
.
h
>
9
#
include
<
QtQml
/
qqmlscriptstring
.
h
>
10
11
#
include
<
QtCore
/
qobject
.
h
>
12
#
include
<
QtCore
/
qvariant
.
h
>
13
14
QT_BEGIN_NAMESPACE
15
16
17
class
QString;
18
class
QQmlEngine;
19
class
QQmlContext;
20
class
QQmlExpressionPrivate
;
21
class
QQmlContextData;
22
class
Q_QML_EXPORT
QQmlExpression
:
public
QObject
23
{
24
Q_OBJECT
25
public
:
26
QQmlExpression();
27
QQmlExpression(QQmlContext *, QObject *,
const
QString &, QObject * =
nullptr
);
28
explicit
QQmlExpression(
const
QQmlScriptString &, QQmlContext * =
nullptr
, QObject * =
nullptr
, QObject * =
nullptr
);
29
~QQmlExpression() override;
30
31
QQmlEngine *engine()
const
;
32
QQmlContext *context()
const
;
33
34
QString expression()
const
;
35
void
setExpression(
const
QString &);
36
37
bool
notifyOnValueChanged()
const
;
38
void
setNotifyOnValueChanged(
bool
);
39
40
QString sourceFile()
const
;
41
int
lineNumber()
const
;
42
int
columnNumber()
const
;
43
void
setSourceLocation(
const
QString &fileName,
int
line,
int
column = 0);
44
45
QObject *scopeObject()
const
;
46
47
bool
hasError()
const
;
48
void
clearError();
49
QQmlError error()
const
;
50
51
QVariant evaluate(
bool
*valueIsUndefined =
nullptr
);
52
53
Q_SIGNALS:
54
void
valueChanged();
55
56
private
:
57
QQmlExpression(QQmlExpressionPrivate &dd, QObject *parent);
58
59
Q_DISABLE_COPY(QQmlExpression)
60
Q_DECLARE_PRIVATE(QQmlExpression)
61
friend
class
QQmlDebugger;
62
friend
class
QQmlContext;
63
};
64
65
QT_END_NAMESPACE
66
67
#
endif
// QQMLEXPRESSION_H
QQmlExpressionPrivate
Definition
qqmlexpression_p.h:31
QQmlExpression
The QQmlExpression class evaluates JavaScript in a QML context.
Definition
qqmlexpression.h:23
QQmlWatchProxy
Definition
qqmlwatcher.cpp:22
QQmlWatchProxy::QQmlWatchProxy
QQmlWatchProxy(int id, QQmlExpression *exp, int debugId, QQmlWatcher *parent=nullptr)
Definition
qqmlwatcher.cpp:50
QQmlWatcher
Definition
qqmlwatcher.h:33
QQmlWatcher::removeWatch
bool removeWatch(int id)
Definition
qqmlwatcher.cpp:137
QQmlWatcher::addWatch
bool addWatch(int id, quint32 objectId)
Definition
qqmlwatcher.cpp:96
QQmlWatcher::addWatch
bool addWatch(int id, quint32 objectId, const QByteArray &property)
Definition
qqmlwatcher.cpp:108
QT_BEGIN_NAMESPACE
Combined button and popup list for selecting options.
Definition
qsequentialanimationgroup.cpp:47
qtdeclarative
src
qml
qml
qqmlexpression.h
Generated on
for Qt by
1.18.0