1 /****************************************************************************
3 ** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies).
4 ** All rights reserved.
5 ** Contact: http://www.qt-project.org/
7 ** This file is part of the QtDeclarative module of the Qt Toolkit.
9 ** $QT_BEGIN_LICENSE:LGPL-ONLY$
10 ** GNU Lesser General Public License Usage
11 ** This file may be used under the terms of the GNU Lesser
12 ** General Public License version 2.1 as published by the Free Software
13 ** Foundation and appearing in the file LICENSE.LGPL included in the
14 ** packaging of this file. Please review the following information to
15 ** ensure the GNU Lesser General Public License version 2.1 requirements
16 ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
18 ** If you have questions regarding the use of this file, please contact
19 ** us via http://www.qt-project.org/.
22 ****************************************************************************/
24 #ifndef QJSVALUEITERATOR_P_H
25 #define QJSVALUEITERATOR_P_H
27 #include <private/qintrusivelist_p.h>
28 #include "qjsvalue_p.h"
30 #include <private/qv8_p.h>
36 class QJSValueIteratorPrivate
39 inline QJSValueIteratorPrivate(const QJSValuePrivate* value);
40 inline ~QJSValueIteratorPrivate();
42 inline bool hasNext() const;
45 inline QString name() const;
47 inline QScriptPassPointer<QJSValuePrivate> value() const;
49 inline bool isValid() const;
50 inline QV8Engine* engine() const;
52 inline void invalidate();
54 Q_DISABLE_COPY(QJSValueIteratorPrivate)
56 QIntrusiveListNode m_node;
57 QScriptSharedDataPointer<QJSValuePrivate> m_object;
58 v8::Persistent<v8::Array> m_names;
62 friend class QV8Engine;
68 #endif // QJSVALUEITERATOR_P_H