summaryrefslogtreecommitdiffstats
path: root/src/declarative/qml/qmldom.h
diff options
context:
space:
mode:
authorKai Koehne <kai.koehne@nokia.com>2009-07-15 01:09:31 (GMT)
committerKai Koehne <kai.koehne@nokia.com>2009-07-15 02:02:32 (GMT)
commit68e47e91af6edca3c714cc3258b65dd88c0ee1e4 (patch)
tree914ff8bba8e702673a40e55411a47b74522e8016 /src/declarative/qml/qmldom.h
parentfa0159762ce65c99907dbcb68d1c10e1a126468f (diff)
downloadQt-68e47e91af6edca3c714cc3258b65dd88c0ee1e4.zip
Qt-68e47e91af6edca3c714cc3258b65dd88c0ee1e4.tar.gz
Qt-68e47e91af6edca3c714cc3258b65dd88c0ee1e4.tar.bz2
Expose qml import statements in QmlDom
Diffstat (limited to 'src/declarative/qml/qmldom.h')
-rw-r--r--src/declarative/qml/qmldom.h25
1 files changed, 24 insertions, 1 deletions
diff --git a/src/declarative/qml/qmldom.h b/src/declarative/qml/qmldom.h
index ef9fe25..456202a 100644
--- a/src/declarative/qml/qmldom.h
+++ b/src/declarative/qml/qmldom.h
@@ -59,9 +59,11 @@ class QmlDomList;
class QmlDomValue;
class QmlEngine;
class QmlDomComponent;
+class QmlDomImport;
class QIODevice;
class QmlDomDocumentPrivate;
+
class Q_DECLARATIVE_EXPORT QmlDomDocument
{
public:
@@ -71,7 +73,7 @@ public:
QmlDomDocument &operator=(const QmlDomDocument &);
int version() const;
- QList<QUrl> imports() const;
+ QList<QmlDomImport> imports() const;
QList<QmlError> errors() const;
bool load(QmlEngine *, const QByteArray &, const QUrl & = QUrl());
@@ -304,6 +306,27 @@ private:
QSharedDataPointer<QmlDomValuePrivate> d;
};
+class QmlDomImportPrivate;
+class Q_DECLARATIVE_EXPORT QmlDomImport
+{
+public:
+ enum Type { Library, File };
+
+ QmlDomImport();
+ QmlDomImport(const QmlDomImport &);
+ ~QmlDomImport();
+ QmlDomImport &operator=(const QmlDomImport &);
+
+ Type type() const;
+ QString uri() const;
+ QString version() const;
+ QString qualifier() const;
+
+private:
+ friend class QmlDomDocument;
+ QSharedDataPointer<QmlDomImportPrivate> d;
+};
+
QT_END_NAMESPACE
QT_END_HEADER