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
QQmlPropertyCache Class Referencefinal

#include <qqmlpropertycache_p.h>

Inheritance diagram for QQmlPropertyCache:
Collaboration diagram for QQmlPropertyCache:

Classes

struct  ConstPtr

Public Types

enum  OverrideResult { NoOverride , InvalidOverride , ValidOverride }
using Ptr = QQmlRefPointer<QQmlPropertyCache>

Public Member Functions

 QQmlPropertyCache ()=default
 ~QQmlPropertyCache ()
void update (const QMetaObject *)
void invalidate (const QMetaObject *)
QQmlPropertyCache::Ptr copy () const
QQmlPropertyCache::Ptr copyAndAppend (const QMetaObject *, QTypeRevision typeVersion, QQmlPropertyData::Flags propertyFlags=QQmlPropertyData::Flags(), QQmlPropertyData::Flags methodFlags=QQmlPropertyData::Flags(), QQmlPropertyData::Flags signalFlags=QQmlPropertyData::Flags()) const
QQmlPropertyCache::Ptr copyAndReserve (int propertyCount, int methodCount, int signalCount, int enumCount) const
OverrideResult appendAlias (const QString &, QQmlPropertyData::Flags flags, int coreIndex, QMetaType propType, QTypeRevision version, int notifyIndex, int encodedTargetIndex)
void appendSignal (const QString &, QQmlPropertyData::Flags, int coreIndex, const QMetaType *types=nullptr, const QList< QByteArray > &names=QList< QByteArray >())
void appendMethod (const QString &, QQmlPropertyData::Flags flags, int coreIndex, QMetaType returnType, const QList< QByteArray > &names, const QVector< QMetaType > &parameterTypes)
void appendEnum (const QString &, const QVector< QQmlEnumValue > &)
const QMetaObjectmetaObject () const
const QMetaObjectcreateMetaObject () const
const QMetaObjectfirstCppMetaObject () const
template<typename K>
const QQmlPropertyDataproperty (const K &key, QObject *object, const QQmlRefPointer< QQmlContextData > &context) const
const QQmlPropertyDataproperty (int) const
const QQmlPropertyDatamaybeUnresolvedProperty (int) const
const QQmlPropertyDatamethod (int) const
const QQmlPropertyDatasignal (int index) const
QQmlEnumDataqmlEnum (int) const
int methodIndexToSignalIndex (int) const
QString defaultPropertyName () const
const QQmlPropertyDatadefaultProperty () const
const QQmlPropertyCache::ConstPtrparent () const
void setParent (QQmlPropertyCache::ConstPtr newParent)
const QQmlPropertyDataoverrideData (const QQmlPropertyData *) const
bool isAllowedInRevision (const QQmlPropertyData *) const
int originalClone (int index) const
QList< QByteArraysignalParameterNames (int index) const
const char * className () const
int propertyCount () const
int ownPropertyCount () const
int propertyOffset () const
int methodCount () const
int ownMethodCount () const
int methodOffset () const
int signalCount () const
int ownSignalCount () const
int signalOffset () const
int qmlEnumCount () const
void toMetaObjectBuilder (QMetaObjectBuilder &) const
bool callJSFactoryMethod (QObject *object, void **args) const
QByteArray checksum (QHash< quintptr, QByteArray > *checksums, bool *ok) const
QTypeRevision allowedRevision (int index) const
void setAllowedRevision (int index, QTypeRevision allowed)
Public Member Functions inherited from QQmlRefCounted< QQmlPropertyCache >
void release () const
Public Member Functions inherited from QQmlRefCount
 QQmlRefCount ()
void addref () const
int count () const

Static Public Member Functions

static Ptr createStandalone (const QMetaObject *, QTypeRevision metaObjectRevision=QTypeRevision::zero())
 Creates a standalone QQmlPropertyCache of metaObject.
static const QQmlPropertyDataproperty (QObject *, QStringView, const QQmlRefPointer< QQmlContextData > &, QQmlPropertyData *)
static const QQmlPropertyDataproperty (QObject *, const QLatin1String &, const QQmlRefPointer< QQmlContextData > &, QQmlPropertyData *)
static const QQmlPropertyDataproperty (QObject *, const QV4::String *, const QQmlRefPointer< QQmlContextData > &, QQmlPropertyData *)
static int originalClone (const QObject *, int index)
static QString signalParameterStringForJS (const QList< QByteArray > &parameterNameList, QString *errorString=nullptr)
static bool determineMetaObjectSizes (const QMetaObject &mo, int *fieldCount, int *stringCount)
static bool addToHash (QCryptographicHash &hash, const QMetaObject &mo)

Friends

class QQmlEnginePrivate
class QQmlCompiler
template<typename T>
class QQmlPropertyCacheCreator
template<typename T>
class QQmlPropertyCacheAliasCreator
template<typename T>
class QQmlComponentAndAliasResolver
class QQmlMetaObject

Additional Inherited Members

Protected Member Functions inherited from QQmlRefCounted< QQmlPropertyCache >
 ~QQmlRefCounted ()

Detailed Description

Definition at line 119 of file qqmlpropertycache_p.h.

Member Typedef Documentation

◆ Ptr

Member Enumeration Documentation

◆ OverrideResult

Enumerator
NoOverride 
InvalidOverride 
ValidOverride 

Definition at line 155 of file qqmlpropertycache_p.h.

Constructor & Destructor Documentation

◆ QQmlPropertyCache()

QQmlPropertyCache::QQmlPropertyCache ( )
default

◆ ~QQmlPropertyCache()

QQmlPropertyCache::~QQmlPropertyCache ( )

Definition at line 160 of file qqmlpropertycache.cpp.

Member Function Documentation

◆ addToHash()

bool QQmlPropertyCache::addToHash ( QCryptographicHash & hash,
const QMetaObject & mo )
static

Definition at line 1202 of file qqmlpropertycache.cpp.

◆ allowedRevision()

QTypeRevision QQmlPropertyCache::allowedRevision ( int index) const
inline

Definition at line 235 of file qqmlpropertycache_p.h.

◆ appendAlias()

QQmlPropertyCache::OverrideResult QQmlPropertyCache::appendAlias ( const QString & name,
QQmlPropertyData::Flags flags,
int coreIndex,
QMetaType propType,
QTypeRevision version,
int notifyIndex,
int encodedTargetIndex )

Definition at line 209 of file qqmlpropertycache.cpp.

◆ appendEnum()

void QQmlPropertyCache::appendEnum ( const QString & name,
const QVector< QQmlEnumValue > & values )

Definition at line 301 of file qqmlpropertycache.cpp.

◆ appendMethod()

void QQmlPropertyCache::appendMethod ( const QString & name,
QQmlPropertyData::Flags flags,
int coreIndex,
QMetaType returnType,
const QList< QByteArray > & names,
const QVector< QMetaType > & parameterTypes )

Definition at line 270 of file qqmlpropertycache.cpp.

◆ appendSignal()

void QQmlPropertyCache::appendSignal ( const QString & name,
QQmlPropertyData::Flags flags,
int coreIndex,
const QMetaType * types = nullptr,
const QList< QByteArray > & names = QList<QByteArray>() )

Definition at line 225 of file qqmlpropertycache.cpp.

◆ callJSFactoryMethod()

bool QQmlPropertyCache::callJSFactoryMethod ( QObject * object,
void ** args ) const
inline

Definition at line 489 of file qqmlpropertycache_p.h.

◆ checksum()

QByteArray QQmlPropertyCache::checksum ( QHash< quintptr, QByteArray > * checksums,
bool * ok ) const

Definition at line 1218 of file qqmlpropertycache.cpp.

◆ className()

const char * QQmlPropertyCache::className ( ) const

Definition at line 909 of file qqmlpropertycache.cpp.

◆ copy()

QQmlPropertyCache::Ptr QQmlPropertyCache::copy ( ) const

Definition at line 191 of file qqmlpropertycache.cpp.

◆ copyAndAppend()

QQmlPropertyCache::Ptr QQmlPropertyCache::copyAndAppend ( const QMetaObject * metaObject,
QTypeRevision typeVersion,
QQmlPropertyData::Flags propertyFlags = QQmlPropertyData::Flags(),
QQmlPropertyData::Flags methodFlags = QQmlPropertyData::Flags(),
QQmlPropertyData::Flags signalFlags = QQmlPropertyData::Flags() ) const

Definition at line 347 of file qqmlpropertycache.cpp.

◆ copyAndReserve()

QQmlPropertyCache::Ptr QQmlPropertyCache::copyAndReserve ( int propertyCount,
int methodCount,
int signalCount,
int enumCount ) const

Definition at line 196 of file qqmlpropertycache.cpp.

◆ createMetaObject()

const QMetaObject * QQmlPropertyCache::createMetaObject ( ) const

Definition at line 310 of file qqmlpropertycache.cpp.

◆ createStandalone()

QQmlPropertyCache::Ptr QQmlPropertyCache::createStandalone ( const QMetaObject * metaObject,
QTypeRevision metaObjectRevision = QTypeRevision::zero() )
static

Creates a standalone QQmlPropertyCache of metaObject.

It is separate from the usual QQmlPropertyCache hierarchy. It's parent is not equal to any other QQmlPropertyCache created from QObject::staticMetaObject, for example.

Definition at line 131 of file qqmlpropertycache.cpp.

◆ defaultProperty()

const QQmlPropertyData * QQmlPropertyCache::defaultProperty ( ) const

Definition at line 335 of file qqmlpropertycache.cpp.

◆ defaultPropertyName()

QString QQmlPropertyCache::defaultPropertyName ( ) const
inline

Definition at line 411 of file qqmlpropertycache_p.h.

◆ determineMetaObjectSizes()

bool QQmlPropertyCache::determineMetaObjectSizes ( const QMetaObject & mo,
int * fieldCount,
int * stringCount )
static

Definition at line 1184 of file qqmlpropertycache.cpp.

◆ firstCppMetaObject()

const QMetaObject * QQmlPropertyCache::firstCppMetaObject ( ) const
inline

Definition at line 344 of file qqmlpropertycache_p.h.

◆ invalidate()

void QQmlPropertyCache::invalidate ( const QMetaObject * metaObject)

invalidates and updates the PropertyCache if the QMetaObject has changed. This function is used in the tooling to update dynamic properties.

Definition at line 585 of file qqmlpropertycache.cpp.

◆ isAllowedInRevision()

bool QQmlPropertyCache::isAllowedInRevision ( const QQmlPropertyData * data) const
inline

Definition at line 433 of file qqmlpropertycache_p.h.

◆ maybeUnresolvedProperty()

const QQmlPropertyData * QQmlPropertyCache::maybeUnresolvedProperty ( int index) const

Definition at line 322 of file qqmlpropertycache.cpp.

◆ metaObject()

const QMetaObject * QQmlPropertyCache::metaObject ( ) const
inline

Definition at line 337 of file qqmlpropertycache_p.h.

◆ method()

const QQmlPropertyData * QQmlPropertyCache::method ( int index) const
inline

Definition at line 363 of file qqmlpropertycache_p.h.

◆ methodCount()

int QQmlPropertyCache::methodCount ( ) const
inline

Definition at line 464 of file qqmlpropertycache_p.h.

◆ methodIndexToSignalIndex()

int QQmlPropertyCache::methodIndexToSignalIndex ( int index) const
inline

Definition at line 399 of file qqmlpropertycache_p.h.

◆ methodOffset()

int QQmlPropertyCache::methodOffset ( ) const
inline

Definition at line 469 of file qqmlpropertycache_p.h.

◆ originalClone() [1/2]

int QQmlPropertyCache::originalClone ( const QObject * object,
int index )
static

Definition at line 758 of file qqmlpropertycache.cpp.

◆ originalClone() [2/2]

int QQmlPropertyCache::originalClone ( int index) const

Definition at line 751 of file qqmlpropertycache.cpp.

◆ overrideData()

const QQmlPropertyData * QQmlPropertyCache::overrideData ( const QQmlPropertyData * data) const
inline

Definition at line 422 of file qqmlpropertycache_p.h.

◆ ownMethodCount()

int QQmlPropertyCache::ownMethodCount ( ) const
inline

Definition at line 219 of file qqmlpropertycache_p.h.

◆ ownPropertyCount()

int QQmlPropertyCache::ownPropertyCount ( ) const
inline

Definition at line 216 of file qqmlpropertycache_p.h.

◆ ownSignalCount()

int QQmlPropertyCache::ownSignalCount ( ) const
inline

Definition at line 222 of file qqmlpropertycache_p.h.

◆ parent()

const QQmlPropertyCache::ConstPtr & QQmlPropertyCache::parent ( ) const
inline

Definition at line 416 of file qqmlpropertycache_p.h.

◆ property() [1/5]

template<typename K>
const QQmlPropertyData * QQmlPropertyCache::property ( const K & key,
QObject * object,
const QQmlRefPointer< QQmlContextData > & context ) const
inline

Definition at line 172 of file qqmlpropertycache_p.h.

◆ property() [2/5]

const QQmlPropertyData * QQmlPropertyCache::property ( int index) const
inline

Definition at line 352 of file qqmlpropertycache_p.h.

◆ property() [3/5]

const QQmlPropertyData * QQmlPropertyCache::property ( QObject * obj,
const QLatin1String & name,
const QQmlRefPointer< QQmlContextData > & context,
QQmlPropertyData * local )
static

Definition at line 893 of file qqmlpropertycache.cpp.

◆ property() [4/5]

const QQmlPropertyData * QQmlPropertyCache::property ( QObject * obj,
const QV4::String * name,
const QQmlRefPointer< QQmlContextData > & context,
QQmlPropertyData * local )
static

Definition at line 879 of file qqmlpropertycache.cpp.

◆ property() [5/5]

const QQmlPropertyData * QQmlPropertyCache::property ( QObject * obj,
QStringView name,
const QQmlRefPointer< QQmlContextData > & context,
QQmlPropertyData * local )
static

Definition at line 886 of file qqmlpropertycache.cpp.

◆ propertyCount()

int QQmlPropertyCache::propertyCount ( ) const
inline

Definition at line 454 of file qqmlpropertycache_p.h.

◆ propertyOffset()

int QQmlPropertyCache::propertyOffset ( ) const
inline

Definition at line 459 of file qqmlpropertycache_p.h.

◆ qmlEnum()

QQmlEnumData * QQmlPropertyCache::qmlEnum ( int index) const
inline

Definition at line 391 of file qqmlpropertycache_p.h.

◆ qmlEnumCount()

int QQmlPropertyCache::qmlEnumCount ( ) const
inline

Definition at line 484 of file qqmlpropertycache_p.h.

◆ setAllowedRevision()

void QQmlPropertyCache::setAllowedRevision ( int index,
QTypeRevision allowed )
inline

Definition at line 236 of file qqmlpropertycache_p.h.

◆ setParent()

void QQmlPropertyCache::setParent ( QQmlPropertyCache::ConstPtr newParent)

Definition at line 340 of file qqmlpropertycache.cpp.

◆ signal()

const QQmlPropertyData * QQmlPropertyCache::signal ( int index) const
inline

index MUST be in the signal index range (see QObjectPrivate::signalIndex()). This is different from QMetaMethod::methodIndex().

Definition at line 378 of file qqmlpropertycache_p.h.

◆ signalCount()

int QQmlPropertyCache::signalCount ( ) const
inline

Definition at line 474 of file qqmlpropertycache_p.h.

◆ signalOffset()

int QQmlPropertyCache::signalOffset ( ) const
inline

Definition at line 479 of file qqmlpropertycache_p.h.

◆ signalParameterNames()

QList< QByteArray > QQmlPropertyCache::signalParameterNames ( int index) const

index MUST be in the signal index range (see QObjectPrivate::signalIndex()). This is different from QMetaMethod::methodIndex().

Definition at line 1259 of file qqmlpropertycache.cpp.

◆ signalParameterStringForJS()

QString QQmlPropertyCache::signalParameterStringForJS ( const QList< QByteArray > & parameterNameList,
QString * errorString = nullptr )
static

Definition at line 720 of file qqmlpropertycache.cpp.

◆ toMetaObjectBuilder()

void QQmlPropertyCache::toMetaObjectBuilder ( QMetaObjectBuilder & builder) const

Definition at line 917 of file qqmlpropertycache.cpp.

◆ update()

void QQmlPropertyCache::update ( const QMetaObject * metaObject)

Definition at line 558 of file qqmlpropertycache.cpp.

◆ QQmlCompiler

friend class QQmlCompiler
friend

Definition at line 240 of file qqmlpropertycache_p.h.

◆ QQmlComponentAndAliasResolver

template<typename T>
friend class QQmlComponentAndAliasResolver
friend

Definition at line 243 of file qqmlpropertycache_p.h.

◆ QQmlEnginePrivate

friend class QQmlEnginePrivate
friend

Definition at line 239 of file qqmlpropertycache_p.h.

◆ QQmlMetaObject

friend class QQmlMetaObject
friend

Definition at line 244 of file qqmlpropertycache_p.h.

◆ QQmlPropertyCacheAliasCreator

template<typename T>
friend class QQmlPropertyCacheAliasCreator
friend

Definition at line 242 of file qqmlpropertycache_p.h.

◆ QQmlPropertyCacheCreator

template<typename T>
friend class QQmlPropertyCacheCreator
friend

Definition at line 241 of file qqmlpropertycache_p.h.


The documentation for this class was generated from the following files: