Correct typos in doxygen comments
[platform/framework/native/appfw.git] / inc / FBaseColIEnumeratorT.h
1 //
2 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
3 //
4 // Licensed under the Apache License, Version 2.0 (the License);
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16
17 /**
18  * @file                FBaseColIEnumeratorT.h
19  * @brief               This is the header file for the %IEnumeratorT interface.
20  *
21  * This header file contains the declarations of the %IEnumeratorT interface.
22  *
23  */
24 #ifndef _FBASE_COL_IENUMERATOR_T_H_
25 #define _FBASE_COL_IENUMERATOR_T_H_
26
27 #include <FBaseTypes.h>
28
29
30 namespace Tizen { namespace Base { namespace Collection
31 {
32
33 /**
34  * @interface IEnumeratorT
35  * @brief       This interface supports simple iteration over a template-based collection.
36  *
37  * @since 2.0
38  *
39  * @remarks
40  * An enumerator remains valid as long as the collection remains unchanged.
41  * If changes are made to the collection, such as adding, modifying, or
42  * deleting elements, the enumerator is irrecoverably invalidated. The next call to GetCurrent(), MoveNext(), or Reset() fails and returns
43  * E_INVALID_OPERATION.
44  *
45  * The %IEnumeratorT interface supports simple iteration over a template-based collection.
46  * One can only access the elements in a collection through %IEnumeratorT. The elements cannot be modified through this interface.
47  *
48  */
49 template< class Type >
50 class IEnumeratorT
51 {
52 public:
53         /**
54          * This polymorphic destructor should be overridden if required. @n
55          * This way, the destructors of the derived classes are called when the destructor of this interface is called.
56          *
57          * @since 2.0
58          */
59         virtual ~IEnumeratorT(void) {}
60
61         /**
62          * Gets the current object in the collection.
63          *
64          * @since 2.0
65          *
66          * @return              An error code
67          * @param[out]  obj A pointer to the current object
68          * @exception   E_SUCCESS                       The method is successful.
69          * @exception   E_INVALID_OPERATION     The current state of the instance prohibits the execution of the specified operation. @n
70          *                                                                      The enumerator is currently positioned before the first element or
71          *                                                                      after the last element or the collection is modified after the enumerator is created.
72          */
73         virtual result GetCurrent(Type& obj) const = 0;
74
75         /**
76          * Moves %IEnumeratorT to the next element of the collection. @n
77          * After the enumerator is first created or reset using the Reset() method,
78          * the first call to this method positions the enumerator to the first element in the collection.
79          *
80          * @since 2.0
81          *
82          * @return              An error code
83          * @exception   E_SUCCESS                       The method is successful.
84          * @exception   E_OUT_OF_RANGE          The enumerator has passed the end of the collection.
85          * @exception   E_INVALID_OPERATION     The current state of the instance prohibits the execution of the specified operation, or
86          *                                                                      the collection is modified after the enumerator is created.
87          * @see                 Reset()
88          */
89         virtual result MoveNext(void) = 0;
90
91         /**
92          * Positions the enumerator before the first element in the collection.
93          *
94          * @since 2.0
95          *
96          * @return              An error code
97          * @exception   E_SUCCESS                       The method is successful.
98          * @exception   E_INVALID_OPERATION     The current state of the instance prohibits the execution of the specified operation, or
99          *                                                                      the collection is modified after the enumerator is created.
100          */
101         virtual result Reset(void) = 0;
102
103 }; // IEnumeratorT
104
105 }}} // Tizen::Base::Collection
106
107 #endif // _FBASE_COL_IENUMERATOR_T_H_