00001 /* 00002 * ============================================================================== 00003 * Name : xmlengnodelist.h 00004 * Part of : XmlEngine / DOM XPath C++ Wrapper 00005 * Interface : Domain, XML Engine DOM API 00006 * Description : Node list inline functions 00007 * Version : %version: 2 % 00008 * 00009 * Copyright © 2006-2006 Nokia. All rights reserved. 00010 * This material, including documentation and any related 00011 * computer programs, is protected by copyright controlled by 00012 * Nokia. All rights are reserved. Copying, including 00013 * reproducing, storing, adapting or translating, any 00014 * or all of this material requires the prior written consent of 00015 * Nokia. This material also contains confidential 00016 * information which may not be disclosed to others without the 00017 * prior written consent of Nokia. 00018 * ============================================================================== 00019 */ 00020 00021 #ifndef XMLENGINE_NODELIST_H_INCLUDED 00022 #define XMLENGINE_NODELIST_H_INCLUDED 00023 00024 #include "xmlengnode.h" 00025 #include "xmlengnodelist_impl.h" 00026 00027 00028 00039 template<class T> 00040 class RXmlEngNodeList 00041 { 00042 public: 00049 inline TInt Count() const; 00050 00057 inline TBool HasNext() const; 00058 00065 inline T Next(); 00066 00072 inline void Close(); 00073 00074 private: 00075 friend class TXmlEngNode; 00076 friend class TXmlEngElement; 00077 00078 /* 00079 * Opens node. 00080 * 00081 * @since S60 v3.2 00082 * @param aHead node pointer to the node from which the searching 00083 of list elements is started 00084 * @param aType type of list elements 00085 * @param aName name of list elements 00086 * @param aNs namespace of list elements 00087 * 00088 * @note If aType is NULL, aName and aNs are ignored 00089 */ 00090 void OpenL( 00091 void* aHead, 00092 TXmlEngNode::TXmlEngDOMNodeType aType, 00093 const TDesC8& aName = KNullDesC8, 00094 const TDesC8& aNs = KNullDesC8); 00095 00104 void Open( 00105 void* aHead, 00106 TXmlEngNode::TXmlEngDOMNodeType aType); 00107 00109 RXmlEngNodeListImpl iList; 00110 }; 00111 00121 template<> 00122 class RXmlEngNodeList<TXmlEngNode>: public RXmlEngNodeListImpl {}; 00123 00124 00125 00126 #include "xmlengnodelist.inl" 00127 00128 #endif /* XMLENGINE_NODELIST_H_INCLUDED */