![]() |
Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
|
\inmodule QtQmlCompiler More...
#include <qqmlsa.h>
Classes | |
class | Bindings |
\inmodule QtQmlCompiler More... |
Public Member Functions | |
Binding () | |
Constructs a new Binding object. | |
Binding (const Binding &) | |
Creates a copy of other. | |
Binding (Binding &&) noexcept | |
Move-constructs a Binding instance. | |
Binding & | operator= (const Binding &) |
Assigns other to this Binding instance. | |
Binding & | operator= (Binding &&) noexcept |
Move-assigns other to this Binding instance. | |
~Binding () | |
Destroys the binding. | |
Element | groupType () const |
Returns the type of the property of this binding if it is a group property, otherwise returns an invalid Element. | |
Element | bindingScope () const |
Returns the Element scope in which the binding is defined. | |
BindingType | bindingType () const |
Returns the type of this binding. | |
QString | stringValue () const |
Returns the associated string literal if the content type of this binding is StringLiteral, otherwise returns an empty string. | |
QString | propertyName () const |
Returns the name of the property bound with this binding. | |
bool | isAttached () const |
Returns true if this type is attached to another one, false otherwise. | |
Element | attachedType () const |
Returns the attached type if the content type of this binding is AttachedProperty, otherwise returns an invalid Element. | |
QQmlSA::SourceLocation | sourceLocation () const |
Returns the location in the QML code where this binding is defined. | |
double | numberValue () const |
Returns the associated number if the content type of this binding is NumberLiteral, otherwise returns 0. | |
ScriptBindingKind | scriptKind () const |
Returns the kind of the associated script if the content type of this binding is Script, otherwise returns Invalid. | |
bool | hasObject () const |
Returns true if this binding has an objects, otherwise returns false . | |
Element | objectType () const |
Returns the type of the associated object if the content type of this binding is Object, otherwise returns an invalid Element. | |
bool | hasUndefinedScriptValue () const |
Returns whether this binding has script value type undefined like when it is assigned undefined . | |
bool | hasFunctionScriptValue () const |
Returns whether this binding has script value type function like when it is assigned a (lambda) method, an arrow function or a statement block. |
Static Public Member Functions | |
static bool | isLiteralBinding (BindingType) |
Returns true if bindingType is a literal type, and false otherwise. |
Friends | |
bool | operator== (const Binding &lhs, const Binding &rhs) |
Returns true if lhs and rhs are equal, and false otherwise. | |
bool | operator!= (const Binding &lhs, const Binding &rhs) |
Returns true if lhs and rhs are not equal, and false otherwise. |
\inmodule QtQmlCompiler
Represents a single QML property binding for a specific type.
QQmlSA::Binding::Binding | ( | ) |
Constructs a new Binding object.
Definition at line 247 of file qqmlsa.cpp.
QQmlSA::Binding::Binding | ( | const Binding & | other | ) |
Creates a copy of other.
Definition at line 254 of file qqmlsa.cpp.
|
noexcept |
Move-constructs a Binding
instance.
Definition at line 259 of file qqmlsa.cpp.
|
default |
Destroys the binding.
Element QQmlSA::Binding::attachedType | ( | ) | const |
Returns the attached type if the content type of this binding is AttachedProperty, otherwise returns an invalid Element.
Definition at line 384 of file qqmlsa.cpp.
Element QQmlSA::Binding::bindingScope | ( | ) | const |
Returns the Element scope in which the binding is defined.
Definition at line 342 of file qqmlsa.cpp.
QQmlSA::BindingType QQmlSA::Binding::bindingType | ( | ) | const |
Returns the type of this binding.
Definition at line 350 of file qqmlsa.cpp.
Element QQmlSA::Binding::groupType | ( | ) | const |
Returns the type of the property of this binding if it is a group property, otherwise returns an invalid Element.
Definition at line 334 of file qqmlsa.cpp.
bool QQmlSA::Binding::hasFunctionScriptValue | ( | ) | const |
Returns whether this binding has script value type function like when it is assigned a (lambda) method, an arrow function or a statement block.
If the content type of this binding is not \l{QQmlSA::BindingType::Script}, returns false
.
Definition at line 464 of file qqmlsa.cpp.
bool QQmlSA::Binding::hasObject | ( | ) | const |
Returns true
if this binding has an objects, otherwise returns false
.
Definition at line 432 of file qqmlsa.cpp.
bool QQmlSA::Binding::hasUndefinedScriptValue | ( | ) | const |
Returns whether this binding has script value type undefined like when it is assigned undefined
.
If the content type of this binding is not \l{QQmlSA::BindingType::Script}, returns false
.
Definition at line 451 of file qqmlsa.cpp.
bool QQmlSA::Binding::isAttached | ( | ) | const |
Returns true
if this type is attached to another one, false
otherwise.
Definition at line 375 of file qqmlsa.cpp.
|
static |
Returns true
if bindingType is a literal type, and false
otherwise.
Definition at line 475 of file qqmlsa.cpp.
double QQmlSA::Binding::numberValue | ( | ) | const |
Returns the associated number if the content type of this binding is NumberLiteral, otherwise returns 0.
Definition at line 415 of file qqmlsa.cpp.
QQmlSA::Element QQmlSA::Binding::objectType | ( | ) | const |
Returns the type of the associated object if the content type of this binding is Object, otherwise returns an invalid Element.
Definition at line 441 of file qqmlsa.cpp.
Move-assigns other to this Binding instance.
Definition at line 282 of file qqmlsa.cpp.
Assigns other to this Binding instance.
Definition at line 266 of file qqmlsa.cpp.
QString QQmlSA::Binding::propertyName | ( | ) | const |
Returns the name of the property bound with this binding.
Definition at line 367 of file qqmlsa.cpp.
QQmlSA::ScriptBindingKind QQmlSA::Binding::scriptKind | ( | ) | const |
Returns the kind of the associated script if the content type of this binding is Script, otherwise returns Invalid.
Definition at line 424 of file qqmlsa.cpp.
QQmlSA::SourceLocation QQmlSA::Binding::sourceLocation | ( | ) | const |
Returns the location in the QML code where this binding is defined.
Definition at line 405 of file qqmlsa.cpp.
QString QQmlSA::Binding::stringValue | ( | ) | const |
Returns the associated string literal if the content type of this binding is StringLiteral, otherwise returns an empty string.
Definition at line 359 of file qqmlsa.cpp.