WARNING: USE THIS SOFTWARE AT YOUR OWN RISK! THIS IS EXPERIMENTAL SOFTWARE NOT INTENDED FOR PRODUCTION USE! Zuble is currently an early stage prototype. As such Zuble is minimally tested and inherently unstable. It is provided for experimental, development, and demonstration purposes only. Zuble QML Types   |  Zuble C++ Classes   |  Zuble Overview
Zuble  0.1
Zuble Framework C++/QML extension API
Public Member Functions | Static Public Member Functions | Protected Attributes | Properties | Private Types | Friends | List of all members
Zbl::ZxResultItems Class Reference

This class provides access to the QXmlResultItems class from Javascript programs. It accumulates the results of an XQuery as an array of QXmlItem objects. More...

#include <ZxResultItems.h>

Inheritance diagram for Zbl::ZxResultItems:
Inheritance graph
[legend]
Collaboration diagram for Zbl::ZxResultItems:
Collaboration graph
[legend]

Public Member Functions

 ZxResultItems (ZxQuery *zQuery, QObject *parent=0)
 
Q_INVOKABLE QObject * getItem (int index)
 returns the specified ZxItem object in the result sequence by index More...
 
int getCount ()
 returns the specified ZxItem object from the result model by specifying it's ID. The XML node must have an attribute value of type xs::ID that exactly matches the value passed. More...
 

Static Public Member Functions

static void registerType ()
 Registers ZxResultItems as a QML type. TBD: should we do this? More...
 

Protected Attributes

qItemList m_items
 A list of QXmlItem objects resulting from an XQuery evaluation. More...
 
ZxQuerym_zQuery
 The ZxQuery object that produced this object. More...
 

Properties

int count
 obtain the number of items in the list More...
 

Private Types

typedef QList< QXmlItem * > qItemList
 

Friends

class ZxQuery
 

Detailed Description

This class provides access to the QXmlResultItems class from Javascript programs. It accumulates the results of an XQuery as an array of QXmlItem objects.

Definition at line 45 of file ZxResultItems.h.

Member Typedef Documentation

◆ qItemList

typedef QList<QXmlItem*> Zbl::ZxResultItems::qItemList
private

Definition at line 49 of file ZxResultItems.h.

Constructor & Destructor Documentation

◆ ZxResultItems()

Zbl::ZxResultItems::ZxResultItems ( ZxQuery zQuery,
QObject *  parent = 0 
)
explicit

Definition at line 35 of file ZxResultItems.cpp.

Member Function Documentation

◆ getCount()

int Zbl::ZxResultItems::getCount ( )

returns the specified ZxItem object from the result model by specifying it's ID. The XML node must have an attribute value of type xs::ID that exactly matches the value passed.

Parameters
idValuethe id value for which a node will be returned
Returns
a ZxItem object or NULL no items were present in the result sequence. returns items containing an identity attribute mapped by that attibute's value. Return the number of items in the list

Definition at line 49 of file ZxResultItems.cpp.

◆ getItem()

QObject * Zbl::ZxResultItems::getItem ( int  index)

returns the specified ZxItem object in the result sequence by index

Definition at line 58 of file ZxResultItems.cpp.

◆ registerType()

void Zbl::ZxResultItems::registerType ( )
static

Registers ZxResultItems as a QML type. TBD: should we do this?

Definition at line 42 of file ZxResultItems.cpp.

Referenced by Zbl::Zblcore::registerTypes().

Friends And Related Function Documentation

◆ ZxQuery

friend class ZxQuery
friend

Definition at line 47 of file ZxResultItems.h.

Member Data Documentation

◆ m_items

qItemList Zbl::ZxResultItems::m_items
protected

A list of QXmlItem objects resulting from an XQuery evaluation.

Definition at line 114 of file ZxResultItems.h.

Referenced by Zbl::ZxQuery::evaluateToItems(), getCount(), and getItem().

◆ m_zQuery

ZxQuery* Zbl::ZxResultItems::m_zQuery
protected

The ZxQuery object that produced this object.

Definition at line 120 of file ZxResultItems.h.

Referenced by getItem().

Property Documentation

◆ count

int Zbl::ZxResultItems::count
read

obtain the number of items in the list

Definition at line 60 of file ZxResultItems.h.


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