1 // Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // under the terms of "Eclipse Public License v1.0"
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
18 @warning : This file contains Rose Model ID comments - please do not delete
21 #ifndef __THTTPHDRFIELDITER_H__
22 #define __THTTPHDRFIELDITER_H__
26 #include <stringpool.h>
28 // Forward declarations
32 //##ModelId=3A914DFD005C
33 class THTTPHdrFieldIter
35 Iterator class to iterate the fields within a RHTTPHeaders.
41 /** Construct an iterator for the fields of the supplied header collection.
42 @param aHeaders The header collection whose fields we want to iterate
44 //##ModelId=3A914DFD0087
45 THTTPHdrFieldIter(const CHeaders* aHeaders);
48 //##ModelId=3A914DFD0086
49 IMPORT_C ~THTTPHdrFieldIter();
51 /** Reset iterator to point at the first field in the header collection
53 //##ModelId=3A914DFD0085
54 IMPORT_C void First();
56 /** Check if the iterator is at the end of the collection. If so,
57 further calls to operator() will return NULL.
58 @return True if the iterator has reached the end of the header
61 //##ModelId=3A914DFD0084
62 IMPORT_C TBool AtEnd() const;
64 /** Advance the iterator to the next field.
65 @return True if the iterator still points at a valid part
68 //##ModelId=3A914DFD007E
69 IMPORT_C void operator++();
71 /** Obtain the name of the header field currently pointed at by
73 @return The field name; or <empty string> if the iterator has
74 gone off the end of the header collection
76 //##ModelId=3A914DFD007D
77 IMPORT_C RStringTokenF operator()();
81 /** Check the iterator state for invalidity following deletions in the collection
83 //##ModelId=3BA613240002
84 void CheckInvalidation();
86 /** The headers whose fields we are iterating.
88 //##ModelId=3A914DFD007A
89 const CHeaders* iHeaders;
90 /** The index of the field in the header that is currently pointed
93 //##ModelId=3A914DFD0072
97 inline THTTPHdrFieldIter::THTTPHdrFieldIter(const CHeaders* aHeaders)
104 #endif // __THTTPHDRFIELDITER_H__