ESyS-Particle  2.2
PythonIterIterator.h
Go to the documentation of this file.
1 
2 // //
3 // Copyright (c) 2003-2013 by The University of Queensland //
4 // Earth Systems Science Computational Centre (ESSCC) //
5 // http://www.uq.edu.au/esscc //
6 // //
7 // Primary Business: Brisbane, Queensland, Australia //
8 // Licensed under the Open Software License version 3.0 //
9 // http://www.opensource.org/licenses/osl-3.0.php //
10 // //
12 
13 
14 #ifndef ESYS_LSM_BPUPYTHONITERITERATOR_H
15 #define ESYS_LSM_BPUPYTHONITERITERATOR_H
16 
17 #include <boost/python.hpp>
18 
19 namespace esys
20 {
21  namespace lsm
22  {
23  namespace bpu
24  {
25  template <typename TmplExtractType>
27  {
28  public:
29  typedef TmplExtractType value_type;
30  PythonIterIterator(boost::python::object &iteratable);
31 
32  bool hasNext() const;
33 
34  value_type next();
35 
36  void update();
37 
38  private:
39  bool m_hasNext;
40  boost::python::object m_next;
41  boost::python::object m_iter;
42  };
43  }
44  }
45 }
46 
48 
49 #endif