Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
QV4::CompiledData::Binding Struct Reference

#include <qv4compileddata_p.h>

+ Inheritance diagram for QV4::CompiledData::Binding:
+ Collaboration diagram for QV4::CompiledData::Binding:

Public Types

enum  Type : unsigned int {
  Type_Invalid , Type_Boolean , Type_Number , Type_String ,
  Type_Null , Type_Translation , Type_TranslationById , Type_Script ,
  Type_Object , Type_AttachedProperty , Type_GroupProperty
}
 
enum  Flag : unsigned int {
  IsSignalHandlerExpression = 0x1 , IsSignalHandlerObject = 0x2 , IsOnAssignment = 0x4 , InitializerForReadOnlyDeclaration = 0x8 ,
  IsResolvedEnum = 0x10 , IsListItem = 0x20 , IsBindingToAlias = 0x40 , IsDeferredBinding = 0x80 ,
  IsCustomParserBinding = 0x100 , IsFunctionExpression = 0x200 , IsPropertyObserver = 0x400
}
 
using FlagsField = quint32_le_bitfield_member< 0, 16 >
 
using TypeField = quint32_le_bitfield_member< 16, 16 >
 

Public Member Functions

 Q_DECLARE_FLAGS (Flags, Flag)
 
void clearFlags ()
 
void setFlag (Flag flag)
 
bool hasFlag (Flag flag) const
 
Flags flags () const
 
void setType (Type type)
 
Type type () const
 
bool hasSignalHandlerBindingFlag () const
 
bool isValueBinding () const
 
bool isValueBindingNoAlias () const
 
bool isValueBindingToAlias () const
 
bool isSignalHandler () const
 
bool isAttachedProperty () const
 
bool isGroupProperty () const
 
bool isFunctionExpression () const
 
bool isTranslationBinding () const
 
bool evaluatesToString () const
 
bool valueAsBoolean () const
 

Static Public Member Functions

static QString escapedString (const QString &string)
 

Public Attributes

quint32_le propertyNameIndex
 
quint32_le_bitfield_union< FlagsField, TypeFieldflagsAndType
 
union { 
 
   bool   b 
 
   quint32_le   constantValueIndex 
 
   quint32_le   compiledScriptIndex 
 
   quint32_le   objectIndex 
 
   quint32_le   translationDataIndex 
 
   quint32   nullMarker 
 
value 
 
quint32_le stringIndex
 
Location location
 
Location valueLocation
 

Detailed Description

Definition at line 524 of file qv4compileddata_p.h.

Member Typedef Documentation

◆ FlagsField

◆ TypeField

Member Enumeration Documentation

◆ Flag

enum QV4::CompiledData::Binding::Flag : unsigned int
Enumerator
IsSignalHandlerExpression 
IsSignalHandlerObject 
IsOnAssignment 
InitializerForReadOnlyDeclaration 
IsResolvedEnum 
IsListItem 
IsBindingToAlias 
IsDeferredBinding 
IsCustomParserBinding 
IsFunctionExpression 
IsPropertyObserver 

Definition at line 542 of file qv4compileddata_p.h.

◆ Type

enum QV4::CompiledData::Binding::Type : unsigned int
Enumerator
Type_Invalid 
Type_Boolean 
Type_Number 
Type_String 
Type_Null 
Type_Translation 
Type_TranslationById 
Type_Script 
Type_Object 
Type_AttachedProperty 
Type_GroupProperty 

Definition at line 528 of file qv4compileddata_p.h.

Member Function Documentation

◆ clearFlags()

void QV4::CompiledData::Binding::clearFlags ( )
inline

Definition at line 561 of file qv4compileddata_p.h.

References flagsAndType.

Referenced by QmlIR::IRBuilder::appendBinding(), QmlIR::IRBuilder::appendBinding(), and QmlIR::IRBuilder::resolveQualifiedId().

+ Here is the caller graph for this function:

◆ escapedString()

static QString QV4::CompiledData::Binding::escapedString ( const QString string)
inlinestatic

Definition at line 640 of file qv4compileddata_p.h.

References i.

Referenced by QV4::CompiledData::CompilationUnit::bindingValueAsScriptString().

+ Here is the caller graph for this function:

◆ evaluatesToString()

bool QV4::CompiledData::Binding::evaluatesToString ( ) const
inline

Definition at line 687 of file qv4compileddata_p.h.

References isTranslationBinding(), type(), and Type_String.

+ Here is the call graph for this function:

◆ flags()

Flags QV4::CompiledData::Binding::flags ( ) const
inline

Definition at line 564 of file qv4compileddata_p.h.

References flagsAndType.

Referenced by hasSignalHandlerBindingFlag().

+ Here is the caller graph for this function:

◆ hasFlag()

bool QV4::CompiledData::Binding::hasFlag ( Flag  flag) const
inline

Definition at line 563 of file qv4compileddata_p.h.

References flagsAndType.

Referenced by QmlIR::Object::appendBinding(), QQmlData::deferData(), isFunctionExpression(), isValueBindingNoAlias(), and isValueBindingToAlias().

+ Here is the caller graph for this function:

◆ hasSignalHandlerBindingFlag()

bool QV4::CompiledData::Binding::hasSignalHandlerBindingFlag ( ) const
inline

Definition at line 582 of file qv4compileddata_p.h.

References flags(), IsPropertyObserver, IsSignalHandlerExpression, and IsSignalHandlerObject.

Referenced by isSignalHandler(), and isValueBinding().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isAttachedProperty()

bool QV4::CompiledData::Binding::isAttachedProperty ( ) const
inline

Definition at line 615 of file qv4compileddata_p.h.

References isGroupProperty(), isSignalHandler(), isValueBinding(), Q_ASSERT, type(), and Type_AttachedProperty.

Referenced by QmlIR::QmlUnitGenerator::generate(), isGroupProperty(), isSignalHandler(), and QmlIR::IRBuilder::resolveQualifiedId().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isFunctionExpression()

bool QV4::CompiledData::Binding::isFunctionExpression ( ) const
inline

Definition at line 637 of file qv4compileddata_p.h.

References hasFlag(), and IsFunctionExpression.

+ Here is the call graph for this function:

◆ isGroupProperty()

bool QV4::CompiledData::Binding::isGroupProperty ( ) const
inline

Definition at line 626 of file qv4compileddata_p.h.

References isAttachedProperty(), isSignalHandler(), isValueBinding(), Q_ASSERT, type(), and Type_GroupProperty.

Referenced by QmlIR::QmlUnitGenerator::generate(), isAttachedProperty(), isSignalHandler(), and QmlIR::IRBuilder::resolveQualifiedId().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isSignalHandler()

bool QV4::CompiledData::Binding::isSignalHandler ( ) const
inline

Definition at line 604 of file qv4compileddata_p.h.

References hasSignalHandlerBindingFlag(), isAttachedProperty(), isGroupProperty(), isValueBinding(), and Q_ASSERT.

Referenced by QQuickPropertyChangesPrivate::decodeBinding(), QmlIR::QmlUnitGenerator::generate(), isAttachedProperty(), and isGroupProperty().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isTranslationBinding()

bool QV4::CompiledData::Binding::isTranslationBinding ( ) const
inline

Definition at line 682 of file qv4compileddata_p.h.

References type(), Type_Translation, and Type_TranslationById.

Referenced by QQuickPropertyChangesPrivate::decodeBinding(), evaluatesToString(), and ListLayout::getRoleOrCreate().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isValueBinding()

bool QV4::CompiledData::Binding::isValueBinding ( ) const
inline

Definition at line 590 of file qv4compileddata_p.h.

References hasSignalHandlerBindingFlag(), type(), Type_AttachedProperty, and Type_GroupProperty.

Referenced by QQmlAliasAnnotator::annotateBindingsToAliases(), QmlIR::Object::appendBinding(), isAttachedProperty(), isGroupProperty(), isSignalHandler(), isValueBindingNoAlias(), and isValueBindingToAlias().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isValueBindingNoAlias()

bool QV4::CompiledData::Binding::isValueBindingNoAlias ( ) const
inline

Definition at line 601 of file qv4compileddata_p.h.

References hasFlag(), IsBindingToAlias, and isValueBinding().

Referenced by QmlIR::QmlUnitGenerator::generate().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isValueBindingToAlias()

bool QV4::CompiledData::Binding::isValueBindingToAlias ( ) const
inline

Definition at line 602 of file qv4compileddata_p.h.

References hasFlag(), IsBindingToAlias, and isValueBinding().

Referenced by QmlIR::QmlUnitGenerator::generate().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ Q_DECLARE_FLAGS()

QV4::CompiledData::Binding::Q_DECLARE_FLAGS ( Flags  ,
Flag   
)

◆ setFlag()

void QV4::CompiledData::Binding::setFlag ( Flag  flag)
inline

Definition at line 562 of file qv4compileddata_p.h.

References flagsAndType.

Referenced by QQmlAliasAnnotator::annotateBindingsToAliases(), QmlIR::IRBuilder::appendBinding(), QmlIR::IRBuilder::resolveQualifiedId(), and QmlIR::IRBuilder::setBindingValue().

+ Here is the caller graph for this function:

◆ setType()

void QV4::CompiledData::Binding::setType ( Type  type)
inline

Definition at line 566 of file qv4compileddata_p.h.

References flagsAndType, and type().

Referenced by QmlIR::IRBuilder::appendBinding(), QmlIR::IRBuilder::resolveQualifiedId(), QmlIR::IRBuilder::setBindingValue(), and QmlIR::IRBuilder::tryGeneratingTranslationBinding().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ type()

◆ valueAsBoolean()

bool QV4::CompiledData::Binding::valueAsBoolean ( ) const
inline

Definition at line 689 of file qv4compileddata_p.h.

References type(), and Type_Boolean.

Referenced by QQuickPropertyChangesPrivate::decodeBinding(), and QQmlBindPrivate::decodeBinding().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ b

bool QV4::CompiledData::Binding::b

◆ compiledScriptIndex

◆ constantValueIndex

quint32_le QV4::CompiledData::Binding::constantValueIndex

◆ flagsAndType

quint32_le_bitfield_union<FlagsField, TypeField> QV4::CompiledData::Binding::flagsAndType

Definition at line 559 of file qv4compileddata_p.h.

Referenced by clearFlags(), flags(), hasFlag(), setFlag(), setType(), and type().

◆ location

◆ nullMarker

quint32 QV4::CompiledData::Binding::nullMarker

Definition at line 575 of file qv4compileddata_p.h.

Referenced by QmlIR::IRBuilder::setBindingValue().

◆ objectIndex

◆ propertyNameIndex

◆ stringIndex

◆ translationDataIndex

◆ [union]

◆ valueLocation


The documentation for this struct was generated from the following file: