Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
QMetaPropertyBuilder Class Reference

\inmodule QtCore More...

#include <qmetaobjectbuilder_p.h>

+ Collaboration diagram for QMetaPropertyBuilder:

Public Member Functions

 QMetaPropertyBuilder ()
 
int index () const
 Returns the index of this property within its QMetaObjectBuilder.
 
QByteArray name () const
 Returns the name associated with this property.
 
QByteArray type () const
 Returns the type associated with this property.
 
bool hasNotifySignal () const
 Returns true if this property has a notify signal; false otherwise.
 
QMetaMethodBuilder notifySignal () const
 Returns the notify signal associated with this property.
 
void setNotifySignal (const QMetaMethodBuilder &value)
 Sets the notify signal associated with this property to value.
 
void removeNotifySignal ()
 Removes the notify signal from this property.
 
bool isReadable () const
 Returns true if this property is readable; otherwise returns false.
 
bool isWritable () const
 Returns true if this property is writable; otherwise returns false.
 
bool isResettable () const
 Returns true if this property can be reset to a default value; otherwise returns false.
 
bool isDesignable () const
 Returns true if this property is designable; otherwise returns false.
 
bool isScriptable () const
 Returns true if the property is scriptable; otherwise returns false.
 
bool isStored () const
 Returns true if the property is stored; otherwise returns false.
 
bool isEditable () const
 
bool isUser () const
 Returns true if this property is designated as the USER property, i.e., the one that the user can edit or that is significant in some other way.
 
bool hasStdCppSet () const
 Returns true if the property has a C++ setter function that follows Qt's standard "name" / "setName" pattern.
 
bool isEnumOrFlag () const
 Returns true if the property is an enumerator or flag type; otherwise returns false.
 
bool isConstant () const
 Returns true if the property is constant; otherwise returns false.
 
bool isFinal () const
 Returns true if the property is final; otherwise returns false.
 
bool isAlias () const
 Returns true if the property is an alias.
 
bool isBindable () const
 Returns true if the property is bindable The default value is false.
 
void setReadable (bool value)
 Sets this property to readable if value is true.
 
void setWritable (bool value)
 Sets this property to writable if value is true.
 
void setResettable (bool value)
 Sets this property to resettable if value is true.
 
void setDesignable (bool value)
 Sets this property to designable if value is true.
 
void setScriptable (bool value)
 Sets this property to scriptable if value is true.
 
void setStored (bool value)
 Sets this property to storable if value is true.
 
void setUser (bool value)
 Sets the USER flag on this property to value.
 
void setStdCppSet (bool value)
 Sets the C++ setter flag on this property to value, which is true if the property has a C++ setter function that follows Qt's standard "name" / "setName" pattern.
 
void setEnumOrFlag (bool value)
 Sets this property to be of an enumerator or flag type if value is true.
 
void setConstant (bool value)
 Sets the CONSTANT flag on this property to value.
 
void setFinal (bool value)
 Sets the FINAL flag on this property to value.
 
void setAlias (bool value)
 Sets the ALIAS flag on this property to value.
 
void setBindable (bool value)
 Sets theBINDABLE flag on this property to value.
 
int revision () const
 Returns the revision of this property.
 
void setRevision (int revision)
 Sets the revision of this property.
 

Friends

class QMetaObjectBuilder
 

Detailed Description

\inmodule QtCore

The QMetaPropertyBuilder class enables modifications to a property definition on a meta object builder.

Definition at line 190 of file qmetaobjectbuilder_p.h.

Constructor & Destructor Documentation

◆ QMetaPropertyBuilder()

QMetaPropertyBuilder::QMetaPropertyBuilder ( )
inline

Definition at line 193 of file qmetaobjectbuilder_p.h.

Member Function Documentation

◆ hasNotifySignal()

bool QMetaPropertyBuilder::hasNotifySignal ( ) const

Returns true if this property has a notify signal; false otherwise.

See also
notifySignal(), setNotifySignal(), removeNotifySignal()

Definition at line 1823 of file qmetaobjectbuilder.cpp.

References d.

◆ hasStdCppSet()

bool QMetaPropertyBuilder::hasStdCppSet ( ) const

Returns true if the property has a C++ setter function that follows Qt's standard "name" / "setName" pattern.

Designer and uic query hasStdCppSet() in order to avoid expensive QObject::setProperty() calls. All properties in Qt [should] follow this pattern. The default value is false.

See also
setStdCppSet()

Definition at line 1991 of file qmetaobjectbuilder.cpp.

References d, and StdCppSet.

◆ index()

int QMetaPropertyBuilder::index ( ) const
inline

Returns the index of this property within its QMetaObjectBuilder.

Definition at line 195 of file qmetaobjectbuilder_p.h.

◆ isAlias()

bool QMetaPropertyBuilder::isAlias ( ) const

Returns true if the property is an alias.

The default value is false

Definition at line 2045 of file qmetaobjectbuilder.cpp.

References Alias, and d.

◆ isBindable()

bool QMetaPropertyBuilder::isBindable ( ) const

Returns true if the property is bindable The default value is false.

Definition at line 2058 of file qmetaobjectbuilder.cpp.

References Bindable, and d.

◆ isConstant()

bool QMetaPropertyBuilder::isConstant ( ) const

Returns true if the property is constant; otherwise returns false.

The default value is false.

Definition at line 2019 of file qmetaobjectbuilder.cpp.

References Constant, and d.

◆ isDesignable()

bool QMetaPropertyBuilder::isDesignable ( ) const

Returns true if this property is designable; otherwise returns false.

This default value is false.

See also
setDesignable(), isScriptable(), isStored()

Definition at line 1926 of file qmetaobjectbuilder.cpp.

References d, and Designable.

◆ isEditable()

bool QMetaPropertyBuilder::isEditable ( ) const

◆ isEnumOrFlag()

bool QMetaPropertyBuilder::isEnumOrFlag ( ) const

Returns true if the property is an enumerator or flag type; otherwise returns false.

This default value is false.

See also
setEnumOrFlag()

Definition at line 2006 of file qmetaobjectbuilder.cpp.

References d, and EnumOrFlag.

◆ isFinal()

bool QMetaPropertyBuilder::isFinal ( ) const

Returns true if the property is final; otherwise returns false.

The default value is false.

Definition at line 2032 of file qmetaobjectbuilder.cpp.

References d, and Final.

◆ isReadable()

bool QMetaPropertyBuilder::isReadable ( ) const

Returns true if this property is readable; otherwise returns false.

The default value is true.

See also
setReadable(), isWritable()

Definition at line 1881 of file qmetaobjectbuilder.cpp.

References d, and Readable.

◆ isResettable()

bool QMetaPropertyBuilder::isResettable ( ) const

Returns true if this property can be reset to a default value; otherwise returns false.

The default value is false.

See also
setResettable()

Definition at line 1911 of file qmetaobjectbuilder.cpp.

References d, and Resettable.

◆ isScriptable()

bool QMetaPropertyBuilder::isScriptable ( ) const

Returns true if the property is scriptable; otherwise returns false.

This default value is true.

See also
setScriptable(), isDesignable(), isStored()

Definition at line 1941 of file qmetaobjectbuilder.cpp.

References d, and Scriptable.

◆ isStored()

bool QMetaPropertyBuilder::isStored ( ) const

Returns true if the property is stored; otherwise returns false.

This default value is false.

See also
setStored(), isDesignable(), isScriptable()

Definition at line 1956 of file qmetaobjectbuilder.cpp.

References d, and Stored.

◆ isUser()

bool QMetaPropertyBuilder::isUser ( ) const

Returns true if this property is designated as the USER property, i.e., the one that the user can edit or that is significant in some other way.

Otherwise it returns false. This default value is false.

See also
setUser(), isDesignable(), isScriptable()

Definition at line 1973 of file qmetaobjectbuilder.cpp.

References d, and User.

◆ isWritable()

bool QMetaPropertyBuilder::isWritable ( ) const

Returns true if this property is writable; otherwise returns false.

The default value is true.

See also
setWritable(), isReadable()

Definition at line 1896 of file qmetaobjectbuilder.cpp.

References d, and Writable.

◆ name()

QByteArray QMetaPropertyBuilder::name ( ) const

Returns the name associated with this property.

See also
type()

Definition at line 1795 of file qmetaobjectbuilder.cpp.

References d, and QByteArray().

Referenced by QQmlOpenMetaObject::name(), and QQmlOpenMetaObjectType::propertyName().

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

◆ notifySignal()

QMetaMethodBuilder QMetaPropertyBuilder::notifySignal ( ) const

Returns the notify signal associated with this property.

See also
hasNotifySignal(), setNotifySignal(), removeNotifySignal()

Definition at line 1837 of file qmetaobjectbuilder.cpp.

References d.

◆ removeNotifySignal()

void QMetaPropertyBuilder::removeNotifySignal ( )

Removes the notify signal from this property.

See also
hasNotifySignal(), notifySignal(), setNotifySignal()

Definition at line 1868 of file qmetaobjectbuilder.cpp.

References d.

◆ revision()

int QMetaPropertyBuilder::revision ( ) const

Returns the revision of this property.

See also
setRevision()

Definition at line 2225 of file qmetaobjectbuilder.cpp.

References d.

Referenced by setRevision().

+ Here is the caller graph for this function:

◆ setAlias()

void QMetaPropertyBuilder::setAlias ( bool value)

Sets the ALIAS flag on this property to value.

Definition at line 2204 of file qmetaobjectbuilder.cpp.

References Alias, and d.

◆ setBindable()

void QMetaPropertyBuilder::setBindable ( bool value)

Sets theBINDABLE flag on this property to value.

Definition at line 2214 of file qmetaobjectbuilder.cpp.

References Bindable, and d.

◆ setConstant()

void QMetaPropertyBuilder::setConstant ( bool value)

Sets the CONSTANT flag on this property to value.

See also
isConstant()

Definition at line 2182 of file qmetaobjectbuilder.cpp.

References Constant, and d.

◆ setDesignable()

void QMetaPropertyBuilder::setDesignable ( bool value)

Sets this property to designable if value is true.

See also
isDesignable(), setScriptable(), setStored()

Definition at line 2107 of file qmetaobjectbuilder.cpp.

References d, and Designable.

◆ setEnumOrFlag()

void QMetaPropertyBuilder::setEnumOrFlag ( bool value)

Sets this property to be of an enumerator or flag type if value is true.

See also
isEnumOrFlag()

Definition at line 2170 of file qmetaobjectbuilder.cpp.

References d, and EnumOrFlag.

◆ setFinal()

void QMetaPropertyBuilder::setFinal ( bool value)

Sets the FINAL flag on this property to value.

See also
isFinal()

Definition at line 2194 of file qmetaobjectbuilder.cpp.

References d, and Final.

◆ setNotifySignal()

void QMetaPropertyBuilder::setNotifySignal ( const QMetaMethodBuilder & value)

Sets the notify signal associated with this property to value.

See also
hasNotifySignal(), notifySignal(), removeNotifySignal()

Definition at line 1851 of file qmetaobjectbuilder.cpp.

References d.

◆ setReadable()

void QMetaPropertyBuilder::setReadable ( bool value)

Sets this property to readable if value is true.

See also
isReadable(), setWritable()

Definition at line 2071 of file qmetaobjectbuilder.cpp.

References d, and Readable.

Referenced by QQmlPropertyCache::toMetaObjectBuilder().

+ Here is the caller graph for this function:

◆ setResettable()

void QMetaPropertyBuilder::setResettable ( bool value)

Sets this property to resettable if value is true.

See also
isResettable()

Definition at line 2095 of file qmetaobjectbuilder.cpp.

References d, and Resettable.

◆ setRevision()

void QMetaPropertyBuilder::setRevision ( int revision)

Sets the revision of this property.

See also
revision()

Definition at line 2238 of file qmetaobjectbuilder.cpp.

References d, and revision().

+ Here is the call graph for this function:

◆ setScriptable()

void QMetaPropertyBuilder::setScriptable ( bool value)

Sets this property to scriptable if value is true.

See also
isScriptable(), setDesignable(), setStored()

Definition at line 2119 of file qmetaobjectbuilder.cpp.

References d, and Scriptable.

◆ setStdCppSet()

void QMetaPropertyBuilder::setStdCppSet ( bool value)

Sets the C++ setter flag on this property to value, which is true if the property has a C++ setter function that follows Qt's standard "name" / "setName" pattern.

See also
hasStdCppSet()

Definition at line 2157 of file qmetaobjectbuilder.cpp.

References d, and StdCppSet.

◆ setStored()

void QMetaPropertyBuilder::setStored ( bool value)

Sets this property to storable if value is true.

See also
isStored(), setDesignable(), setScriptable()

Definition at line 2131 of file qmetaobjectbuilder.cpp.

References d, and Stored.

◆ setUser()

void QMetaPropertyBuilder::setUser ( bool value)

Sets the USER flag on this property to value.

See also
isUser(), setDesignable(), setScriptable()

Definition at line 2143 of file qmetaobjectbuilder.cpp.

References d, and User.

◆ setWritable()

void QMetaPropertyBuilder::setWritable ( bool value)

Sets this property to writable if value is true.

See also
isWritable(), setReadable()

Definition at line 2083 of file qmetaobjectbuilder.cpp.

References d, and Writable.

Referenced by QQmlAdaptorModelEngineData::addProperty(), QQmlDMObjectDataMetaObject::createProperty(), and QQmlDelegateModelItemMetaType::initializeMetaObject().

+ Here is the caller graph for this function:

◆ type()

QByteArray QMetaPropertyBuilder::type ( ) const

Returns the type associated with this property.

See also
name()

Definition at line 1809 of file qmetaobjectbuilder.cpp.

References d, and QByteArray().

+ Here is the call graph for this function:

Friends And Related Symbol Documentation

◆ QMetaObjectBuilder

friend class QMetaObjectBuilder
friend

Definition at line 241 of file qmetaobjectbuilder_p.h.


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