#ifndef CELTX_NODE_ITERATOR_H_
#define CELTX_NODE_ITERATOR_H_

#define CELTX_NODEITERATOR_CID                    \
{ /* B3647396-3CF0-4C69-BAB2-5A2E647AE750 */  \
0xb3647396, 0x3cf0, 0x4c69,                   \
{ 0xba, 0xb2, 0x5a, 0x2e, 0x64, 0x7a, 0xe7, 0x50 } }

#define CELTX_NODEITERATOR_CONTRACTID "@celtx.com/dom/iterator;1"

#include "celtxINodeIterator.h"
#include "nsIDOMNode.h"
#include "nsIDOMRange.h"
#include "nsCOMPtr.h"

class celtxNodeIterator : public celtxINodeIterator {
public:
  NS_DECL_ISUPPORTS

  NS_DECL_CELTXINODEITERATOR

  celtxNodeIterator ();

protected:
  virtual ~celtxNodeIterator () {}

  nsCOMPtr<nsIDOMNode> mCurrentNode;
  nsCOMPtr<nsIDOMRange> mRange;
  nsCOMPtr<nsIDOMNode> mFirst;
  nsCOMPtr<nsIDOMNode> mLast;
  PRBool mContainsLast;
};

#endif // CELTX_NODE_ITERATOR_H_
