VMware GemFire Native C++ Reference  9.1
SelectResultsIterator.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 #ifndef GEODE_SELECTRESULTSITERATOR_H_
4 #define GEODE_SELECTRESULTSITERATOR_H_
5 
6 /*
7  * Licensed to the Apache Software Foundation (ASF) under one or more
8  * contributor license agreements. See the NOTICE file distributed with
9  * this work for additional information regarding copyright ownership.
10  * The ASF licenses this file to You under the Apache License, Version 2.0
11  * (the "License"); you may not use this file except in compliance with
12  * the License. You may obtain a copy of the License at
13  *
14  * http://www.apache.org/licenses/LICENSE-2.0
15  *
16  * Unless required by applicable law or agreed to in writing, software
17  * distributed under the License is distributed on an "AS IS" BASIS,
18  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19  * See the License for the specific language governing permissions and
20  * limitations under the License.
21  */
22 
27 #include "geode_globals.hpp"
28 #include "geode_types.hpp"
29 #include "ExceptionTypes.hpp"
30 #include "Serializable.hpp"
31 
32 #include "SelectResults.hpp"
33 #include "CacheableBuiltins.hpp"
34 
35 namespace apache {
36 namespace geode {
37 namespace client {
38 
39 class ResultSetImpl;
40 class StructSetImpl;
41 
48  public:
54  bool hasNext() const;
55 
62  const SerializablePtr next();
63 
69  bool moveNext();
70 
77  const SerializablePtr current() const;
78 
82  void reset();
83 
84  private:
89  SelectResultsPtr srp);
90 
91  CacheableVectorPtr m_vectorSR;
92  int32_t m_nextIndex;
93  // this is to ensure that a reference of SelectResults is kept alive
94  // if an iterator object is present
95  SelectResultsPtr m_srp;
96 
97  friend class ResultSetImpl;
98  friend class StructSetImpl;
99 };
100 } // namespace client
101 } // namespace geode
102 } // namespace apache
103 
104 #endif // GEODE_SELECTRESULTSITERATOR_H_
A SelectResultsIterator is obtained from a ResultSet or StructSet and is used to iterate over the ite...
Definition: SelectResultsIterator.hpp:47
Each enum represents a predefined RegionAttributes in a Cache.
Definition: Assert.hpp:31
#define CPPCACHE_EXPORT
Defines a Geode CPPCACHE export.
Definition: geode_base.hpp:58
Contains generic template definitions for Cacheable types and instantiations for built-in types...
Defines a reference counted shared pointer.
Definition: SharedPtr.hpp:52
This abstract base class is the base class of all user objects that have the shared capability of ref...
Definition: SharedBase.hpp:40
This namespace contains all the Geode C++ API classes, enumerations and globals.

Pivotal GemFire C++ Cache API Documentation