openPMD-api
Public Types | Public Member Functions | Public Attributes | List of all members
openPMD::internal::SeriesData Class Reference

Data members for Series. More...

#include <Series.hpp>

Inheritance diagram for openPMD::internal::SeriesData:
Inheritance graph
[legend]
Collaboration diagram for openPMD::internal::SeriesData:
Collaboration graph
[legend]

Public Types

using IterationIndex_t = Iteration::IterationIndex_t
 
using IterationsContainer_t = Container< Iteration, IterationIndex_t >
 
- Public Types inherited from openPMD::internal::AttributableData
using A_MAP = std::map< std::string, Attribute >
 

Public Member Functions

 SeriesData (SeriesData const &)=delete
 
 SeriesData (SeriesData &&)=delete
 
SeriesDataoperator= (SeriesData const &)=delete
 
SeriesDataoperator= (SeriesData &&)=delete
 
void close ()
 
- Public Member Functions inherited from openPMD::internal::AttributableData
 AttributableData (AttributableData const &)=delete
 
 AttributableData (AttributableData &&)=delete
 
AttributableDataoperator= (AttributableData const &)=delete
 
AttributableDataoperator= (AttributableData &&)=delete
 

Public Attributes

IterationsContainer_t iterations {}
 
std::optional< WriteIterationsm_writeIterations
 For each instance of Series, there is only one instance of WriteIterations, stored in this Option. More...
 
std::set< IterationIndex_t > m_currentlyActiveIterations
 For writing: Remember which iterations have been written in the currently active output step. More...
 
std::optional< std::string > m_overrideFilebasedFilename
 Needed if reading a single iteration of a file-based series. More...
 
std::string m_name
 Name of the iteration without filename suffix. More...
 
std::string m_filenamePrefix
 Filename leading up to the expansion pattern. More...
 
std::string m_filenamePostfix
 Filename after the expansion pattern without filename extension.
 
std::string m_filenameExtension
 Filename extension as specified by the user. More...
 
int m_filenamePadding = -1
 The padding in file-based iteration encoding. More...
 
IterationEncoding m_iterationEncoding {}
 The iteration encoding used in this series.
 
Format m_format
 Detected IO format (backend).
 
StepStatus m_stepStatus = StepStatus::NoStep
 Whether a step is currently active for this iteration. More...
 
bool m_parseLazily = false
 True if a user opts into lazy parsing.
 
bool m_lastFlushSuccessful = false
 This is to avoid that the destructor tries flushing again if an error happened. More...
 
std::optional< ParsePreference > m_parsePreference
 Remember the preference that the backend specified for parsing. More...
 
- Public Attributes inherited from openPMD::internal::AttributableData
Writable m_writable
 The Writable associated with this Attributable. More...
 

Detailed Description

Data members for Series.

Pinned at one memory location.

(Not movable or copyable)

Member Data Documentation

◆ m_currentlyActiveIterations

std::set<IterationIndex_t> openPMD::internal::SeriesData::m_currentlyActiveIterations

For writing: Remember which iterations have been written in the currently active output step.

Use this later when writing the snapshot attribute.

◆ m_filenameExtension

std::string openPMD::internal::SeriesData::m_filenameExtension

Filename extension as specified by the user.

(Not necessarily the backend's default suffix)

◆ m_filenamePadding

int openPMD::internal::SeriesData::m_filenamePadding = -1

The padding in file-based iteration encoding.

0 if no padding is given (T pattern). -1 if no expansion pattern has been parsed.

◆ m_filenamePrefix

std::string openPMD::internal::SeriesData::m_filenamePrefix

Filename leading up to the expansion pattern.

Only used for file-based iteration encoding.

◆ m_lastFlushSuccessful

bool openPMD::internal::SeriesData::m_lastFlushSuccessful = false

This is to avoid that the destructor tries flushing again if an error happened.

Otherwise, this would lead to confusing error messages. Initialized as false, set to true after successful construction. If flushing results in an error, set this back to false. The destructor will only attempt flushing again if this is true.

◆ m_name

std::string openPMD::internal::SeriesData::m_name

Name of the iteration without filename suffix.

In case of file-based iteration encoding, with expansion pattern. E.g.: simData.bp -> simData simData_%06T.h5 -> simData_%06T

◆ m_overrideFilebasedFilename

std::optional<std::string> openPMD::internal::SeriesData::m_overrideFilebasedFilename

Needed if reading a single iteration of a file-based series.

Users may specify the concrete filename of one iteration instead of the file-based expansion pattern. In that case, the filename must not be constructed from prefix, infix and suffix as usual in file-based iteration encoding. Instead, the user-specified filename should be used directly. Store that filename in the following Option to indicate this situation.

◆ m_parsePreference

std::optional<ParsePreference> openPMD::internal::SeriesData::m_parsePreference

Remember the preference that the backend specified for parsing.

Not used in file-based iteration encoding, empty then. In linear read mode, parsing only starts after calling Series::readIterations(), empty before that point.

◆ m_stepStatus

StepStatus openPMD::internal::SeriesData::m_stepStatus = StepStatus::NoStep

Whether a step is currently active for this iteration.

Used for group-based iteration layout, see SeriesData.hpp for iteration-based layout. Access via stepStatus() method to automatically select the correct one among both flags.

◆ m_writeIterations

std::optional<WriteIterations> openPMD::internal::SeriesData::m_writeIterations

For each instance of Series, there is only one instance of WriteIterations, stored in this Option.

This ensures that Series::writeIteration() always returns the same instance.


The documentation for this class was generated from the following files: