C++QEDCore  v2 Milestone 10
a framework for simulating open quantum dynamics – core
trajectory::AdaptiveIO< A > Class Template Reference

Corresponds to evolved::EvolvedIO, adding the capability of state serialization involving a SerializationMetadata instant. More...

#include <Trajectory.h>

+ Inheritance diagram for trajectory::AdaptiveIO< A >:
+ Collaboration diagram for trajectory::AdaptiveIO< A >:

Public Member Functions

 AdaptiveIO (Ptr)
 
cpputils::iarchivereadState (cpputils::iarchive &iar)
 Read in the EvolvedIO from a cpputils::iarchive. More...
 
cpputils::oarchivewriteState (cpputils::oarchive &oar) const
 Write the EvolvedIO to a cpputils::oarchive.
 
double getTime () const
 Returns the time of the underlying EvolvedIO.
 

Protected Member Functions

const Ptr getEvolvedIO () const
 note: not the same const-correctness as in Adaptive
 

Protected Attributes

SerializationMetadata meta_
 

Detailed Description

template<typename A>
class trajectory::AdaptiveIO< A >

Corresponds to evolved::EvolvedIO, adding the capability of state serialization involving a SerializationMetadata instant.

This class exists for the sake of Python I/O

Definition at line 248 of file Trajectory.h.

Member Function Documentation

template<typename A>
cpputils::iarchive& trajectory::AdaptiveIO< A >::readState ( cpputils::iarchive iar)

Read in the EvolvedIO from a cpputils::iarchive.

Two conformity checks are performed for to the array we try to read in:

  • whether the rank matches (throws RankMismatchException if not)
  • whether the dimensions match (throws DimensionsMismatchException if not) The dimensions check can be circumvented by setting the trajectoryID to SerializationMetadata::ArrayOnly in the EvolvedIO's metadata. This is done for example in the python I/O interface, because when reading in a state in python we generally have no idea about the dimensions.

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