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
QQmlJS::Dom::MockObject Class Referencefinal

#include <qqmldommock_p.h>

+ Inheritance diagram for QQmlJS::Dom::MockObject:
+ Collaboration diagram for QQmlJS::Dom::MockObject:

Public Member Functions

DomType kind () const override
 
 MockObject (const Path &pathFromOwner=Path(), QMap< QString, MockObject > subObjects={}, QMap< QString, QCborValue > subValues={})
 
MockObject copy () const
 
std::pair< QString, MockObjectasStringPair () const
 
bool iterateDirectSubpaths (const DomItem &self, DirectVisitor) const override
 
- Public Member Functions inherited from QQmlJS::Dom::CommentableDomElement
 CommentableDomElement (const Path &pathFromOwner=Path())
 
 CommentableDomElement (const CommentableDomElement &o)
 
CommentableDomElementoperator= (const CommentableDomElement &o)=default
 
RegionCommentscomments ()
 
const RegionCommentscomments () const
 
- Public Member Functions inherited from QQmlJS::Dom::DomElement
 DomElement (const Path &pathFromOwner=Path())
 
 DomElement (const DomElement &o)=default
 
Path pathFromOwner (const DomItem &self) const override
 
Path pathFromOwner () const
 
Path canonicalPath (const DomItem &self) const override
 
DomItem containingObject (const DomItem &self) const override
 
virtual void updatePathFromOwner (const Path &newPath)
 
- Public Member Functions inherited from QQmlJS::Dom::DomBase
virtual ~DomBase ()=default
 
DomBasedomBase ()
 
const DomBasedomBase () const
 
virtual DomKind domKind () const
 
bool iterateDirectSubpathsConst (const DomItem &self, DirectVisitor) const
 
virtual void dump (const DomItem &, const Sink &sink, int indent, FilterT filter) const
 
virtual quintptr id () const
 
QString typeName () const
 
virtual QList< QStringfields (const DomItem &self) const
 
virtual DomItem field (const DomItem &self, QStringView name) const
 
virtual index_type indexes (const DomItem &self) const
 
virtual DomItem index (const DomItem &self, index_type index) const
 
virtual QSet< QString > const keys (const DomItem &self) const
 
virtual DomItem key (const DomItem &self, const QString &name) const
 
virtual QString canonicalFilePath (const DomItem &self) const
 
virtual void writeOut (const DomItem &self, OutWriter &lw) const
 
virtual QCborValue value () const
 

Public Attributes

QMap< QString, MockObjectsubObjects
 
QMap< QString, QCborValuesubValues
 

Static Public Attributes

static constexpr DomType kindValue = DomType::MockObject
 

Additional Inherited Members

- Public Types inherited from QQmlJS::Dom::DomBase
using FilterT = function_ref<bool(const DomItem &, const PathEls::PathComponent &, const DomItem &)>
 
- Protected Member Functions inherited from QQmlJS::Dom::DomElement
DomElementoperator= (const DomElement &)=default
 

Detailed Description

Definition at line 40 of file qqmldommock_p.h.

Constructor & Destructor Documentation

◆ MockObject()

QQmlJS::Dom::MockObject::MockObject ( const Path & pathFromOwner = Path(),
QMap< QString, MockObject > subObjects = {},
QMap< QString, QCborValue > subValues = {} )
inline

Definition at line 46 of file qqmldommock_p.h.

Member Function Documentation

◆ asStringPair()

std::pair< QString, MockObject > QQmlJS::Dom::MockObject::asStringPair ( ) const

Definition at line 30 of file qqmldommock.cpp.

References QQmlJS::Dom::DomElement::pathFromOwner().

+ Here is the call graph for this function:

◆ copy()

MockObject QQmlJS::Dom::MockObject::copy ( ) const

Definition at line 17 of file qqmldommock.cpp.

References QQmlJS::Dom::MockObject, QQmlJS::Dom::DomElement::pathFromOwner(), subObjects, and subValues.

+ Here is the call graph for this function:

◆ iterateDirectSubpaths()

bool QQmlJS::Dom::MockObject::iterateDirectSubpaths ( const DomItem & self,
DirectVisitor visitor ) const
overridevirtual

Reimplemented from QQmlJS::Dom::CommentableDomElement.

Definition at line 35 of file qqmldommock.cpp.

References QMap< Key, T >::begin(), QMap< Key, T >::end(), QQmlJS::Dom::CommentableDomElement::iterateDirectSubpaths(), subObjects, and subValues.

+ Here is the call graph for this function:

◆ kind()

DomType QQmlJS::Dom::MockObject::kind ( ) const
inlineoverridevirtual

Implements QQmlJS::Dom::DomBase.

Definition at line 44 of file qqmldommock_p.h.

References kindValue.

Member Data Documentation

◆ kindValue

constexpr DomType QQmlJS::Dom::MockObject::kindValue = DomType::MockObject
staticconstexpr

Definition at line 43 of file qqmldommock_p.h.

Referenced by kind().

◆ subObjects

QMap<QString, MockObject> QQmlJS::Dom::MockObject::subObjects

Definition at line 57 of file qqmldommock_p.h.

Referenced by copy(), and iterateDirectSubpaths().

◆ subValues

QMap<QString, QCborValue> QQmlJS::Dom::MockObject::subValues

Definition at line 58 of file qqmldommock_p.h.

Referenced by copy(), and iterateDirectSubpaths().


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