@@ -69,6 +69,7 @@ class SeriesData : public AttributableData
6969 friend class openPMD ::SeriesImpl;
7070 friend class openPMD ::Iteration;
7171 friend class openPMD ::Series;
72+ friend class SeriesInternal ;
7273
7374public:
7475 explicit SeriesData () = default;
@@ -81,7 +82,7 @@ class SeriesData : public AttributableData
8182
8283 virtual ~SeriesData () = default ;
8384
84- Container< Iteration, uint64_t > iterations{};
85+ Iterations_t iterations{};
8586
8687OPENPMD_private :
8788 auxiliary::Option< WriteIterations > m_writeIterations;
@@ -99,6 +100,7 @@ OPENPMD_private :
99100 * one among both flags.
100101 */
101102 StepStatus m_stepStatus = StepStatus::NoStep;
103+ bool m_parseLazily = false ;
102104}; // SeriesData
103105
104106class SeriesInternal ;
@@ -312,8 +314,7 @@ class SeriesImpl : public AttributableImpl
312314 static constexpr char const * const BASEPATH = " /data/%T/" ;
313315
314316 struct ParsedInput ;
315- using iterations_t = decltype (internal::SeriesData::iterations);
316- using iterations_iterator = iterations_t ::iterator;
317+ using iterations_iterator = Iterations_t::iterator;
317318
318319 internal::SeriesData * m_series;
319320
@@ -337,6 +338,7 @@ class SeriesImpl : public AttributableImpl
337338 void flushMeshesPath ();
338339 void flushParticlesPath ();
339340 void readFileBased ( );
341+ void readOneIterationFileBased ( std::string const & filePath );
340342 /* *
341343 * Note on re-parsing of a Series:
342344 * If init == false, the parsing process will seek for new
@@ -347,7 +349,6 @@ class SeriesImpl : public AttributableImpl
347349 */
348350 void readGroupBased ( bool init = true );
349351 void readBase ();
350- void read ();
351352 std::string iterationFilename ( uint64_t i );
352353 void openIteration ( uint64_t index, Iteration iteration );
353354
@@ -393,13 +394,15 @@ class SeriesInternal : public SeriesData, public SeriesImpl
393394 std::string const & filepath,
394395 Access at,
395396 MPI_Comm comm,
396- std::string const & options = " {}" );
397+ std::string const & options = " {}" ,
398+ bool parseLazily = false );
397399#endif
398400
399401 SeriesInternal (
400402 std::string const & filepath,
401403 Access at,
402- std::string const & options = " {}" );
404+ std::string const & options = " {}" ,
405+ bool parseLazily = false );
403406 // @todo make AttributableImpl<>::linkHierarchy non-virtual
404407 virtual ~SeriesInternal ();
405408};
@@ -423,17 +426,22 @@ class Series : public SeriesImpl
423426 std::string const & filepath,
424427 Access at,
425428 MPI_Comm comm,
426- std::string const & options = " {}" );
429+ std::string const & options = " {}" ,
430+ bool parseLazily = false );
427431#endif
428432
433+ /*
434+ * @todo Think it's time for a SeriesBuilder.
435+ */
429436 Series (
430437 std::string const & filepath,
431438 Access at,
432- std::string const & options = " {}" );
439+ std::string const & options = " {}" ,
440+ bool parseLazily = false );
433441
434442 virtual ~Series () = default ;
435443
436- Container< Iteration, uint64_t > iterations;
444+ Iterations_t iterations;
437445
438446 /* *
439447 * @brief Entry point to the reading end of the streaming API.
0 commit comments