42 #ifndef QABSTRACTXMLNODEMODEL_H 43 #define QABSTRACTXMLNODEMODEL_H 45 #include <QtXmlPatterns/QXmlName> 46 #include <QtCore/QSharedData> 47 #include <QtCore/QScopedPointer> 65 template<
typename T>
class QVector;
74 class XsdValidatedXmlNodeModel;
75 template<
typename TResult,
typename TSource,
typename TMapper,
typename Context>
class ItemMappingIterator;
149 ProcessingInstruction = 32,
162 AxisChild = 1 | ForwardAxis,
163 AxisDescendant = 2 | ForwardAxis,
164 AxisAttribute = 4 | ForwardAxis,
165 AxisSelf = 8 | ForwardAxis,
166 AxisDescendantOrSelf = 16 | ForwardAxis,
167 AxisFollowingSibling = 32 | ForwardAxis,
168 AxisNamespace = 64 | ForwardAxis,
169 AxisFollowing = 128 | ReverseAxis,
170 AxisParent = 256 | ReverseAxis,
171 AxisAncestor = 512 | ReverseAxis,
172 AxisPrecedingSibling = 1024 | ReverseAxis,
173 AxisPreceding = 2048 | ReverseAxis,
174 AxisAncestorOrSelf = 4096 | ReverseAxis,
177 AxisChildOrTop = 32768 | ForwardAxis,
178 AxisAttributeOrTop = 65536 | ForwardAxis
183 return m_storage.data;
188 return m_storage.pointer();
193 return m_storage.model;
198 return m_storage.additionalData;
203 return !m_storage.model;
213 inline QUrl documentUri()
const;
214 inline QUrl baseUri()
const;
221 inline QString stringValue()
const;
259 inline operator int()
const;
317 InheritNamespaces = 0x1,
318 PreserveNamespaces = 0x2
324 const NodeCopySettings &)
const;
359 const QExplicitlySharedDataPointer<QPatternist::DynamicContext> &)
const;
369 class QXmlItemPrivate;
374 class VariableLoader;
375 class IteratorBridge;
376 class ToQXmlItemMapper;
394 bool isAtomicValue()
const;
400 friend class QPatternist::IteratorBridge;
402 friend class QPatternist::ToQXmlItemMapper;
403 friend class QPatternist::ToItemMapper;
406 inline bool internalIsAtomicValue()
const;
The QVariant class acts like a union for the most common Qt data types.
QFlags< NodeCopySetting > NodeCopySettings
static QXmlNodeModelIndex create(const qint64 data, const QAbstractXmlNodeModel *const nm, const qint64 addData)
QXmlNodeModelIndex createIndex(qint64 data, qint64 additionalData) const
Creates a QXmlNodeModelIndex containing data and additionalData.
QXmlNodeModelIndex(const QPatternist::NodeIndexStorage &storage)
The QXmlNodeModelIndex class identifies a node in an XML node model subclassed from QAbstractXmlNodeM...
#define QT_END_NAMESPACE
This macro expands to.
bool isNull() const
Returns true if this QXmlNodeModelIndex is a default constructed value, otherwise false...
void * internalPointer() const
Returns the first data value as a void* pointer.
The QXmlItem class contains either an XML node or an atomic value.
bool qIsForwardIteratorEnd(const QXmlNodeModelIndex &item)
#define Q_DISABLE_COPY(Class)
Disables the use of copy constructors and assignment operators for the given Class.
const QPatternist::AtomicValue * m_atomicValue
The QUrl class provides a convenient interface for working with URLs.
The QString class provides a Unicode character string.
QPatternist::NodeIndexStorage m_node
The QVector class is a template class that provides a dynamic array.
const QAbstractXmlNodeModel * model
QXmlNodeModelIndex createIndex(void *pointer, qint64 additionalData=0) const
Creates a node index with pointer and additionalData as its internal data.
QScopedPointer< QAbstractXmlNodeModelPrivate > d_ptr
#define QT_BEGIN_NAMESPACE
This macro expands to.
qint64 data() const
Returns the first data value.
uint qHash(const QPatternist::TargetNode &node)
Base class for all classes representing atomic values.
QIntegerForSizeof< void * >::Signed qptrdiff
The QAbstractXmlNodeModel class is an abstract base class for modeling non-XML data to look like XML ...
DocumentOrder
Identifies the specific node comparison operator that should be used.
QPatternist::NodeIndexStorage m_storage
The QAbstractXmlForwardIterator class is a base class for forward iterators.
The namespace for the internal API of QtXmlPatterns.
The QSourceLocation class identifies a location in a resource by URI, line, and column.
QAbstractXmlForwardIterator< QXmlItem > Iterator
A QAbstractXmlForwardIterator over QXmlItem.
The Item is the most basic of all visual items in QML.
const QAbstractXmlNodeModel * model() const
Returns the QAbstractXmlNodeModel that this node index refers to.
QExplicitlySharedDataPointer< QAbstractXmlForwardIterator< Item > > ItemIteratorPtr
Proxies another QAbstractXmlForwardIterator, and for each item, returns the Sequence returned from a ...
QList< QXmlNodeModelIndex > List
Typedef for QList<QXmlNodeModelIndex>.
QExplicitlySharedDataPointer< ItemType > ItemTypePtr
QXmlNodeModelIndex(const QXmlNodeModelIndex &other)
Standard copy constructor.
The QXmlName class represents the name of an XML node, in an efficient, namespace-aware way...
The QAbstractXmlReceiver class provides a callback interface for transforming the output of a QXmlQue...
QList< Ptr > List
A list of smart pointers to instances of QAbstractXmlNodeModel.
Represents an item in the XPath 2.0 Data Model.
#define Q_XMLPATTERNS_EXPORT
A delegate class that wraps around a QAbstractXmlNodeModel and provides additional validation specifi...
The QSharedData class is a base class for shared data objects.
NodeKind
Identifies a kind of node.
QXmlNodeModelIndex createIndex(qint64 data) const
Creates a node index with data as its internal data.
QXmlNodeModelIndex()
Default constructor.
static QXmlNodeModelIndex create(const qint64 d, const QAbstractXmlNodeModel *const nm)
SimpleAxis
Four axes that each contain one node only.
QExplicitlySharedDataPointer< QAbstractXmlForwardIterator< QXmlNodeModelIndex > > mapToSequence(const QXmlNodeModelIndex &ni, const QExplicitlySharedDataPointer< QPatternist::DynamicContext > &) const
Axis
Identify the axes emanating from a node.
static bool isIgnorableInDeepEqual(const QXmlNodeModelIndex &n)
Proxies another QAbstractXmlForwardIterator, and for each item, returns the Item returned from a mapp...
The QFlags class provides a type-safe way of storing OR-combinations of enum values.
bool operator!=(const NodeIndexStorage &other) const
qint64 additionalData() const
Returns the second data value.
Q_DECLARE_TYPEINFO(QXmlNodeModelIndex, Q_MOVABLE_TYPE)
bool operator==(QBool b1, bool b2)
QVector< QXmlName > QXmlNameVector
QAbstractXmlForwardIterator< QXmlNodeModelIndex > Iterator
QExplicitlySharedDataPointer< QAbstractXmlNodeModel > Ptr
A QExplicitlySharedDataPointer {smart pointer} to an instance of QAbstractXmlNodeModel.
static bool isNull(const QVariant::Private *d)
bool isNull() const
Returns true if this QXmlItem is neither a node nor an atomic value.
The QList class is a template class that provides lists.
The Text item allows you to add formatted text to a scene.