Aleph-w 3.0
A C++ Library for Data Structures and Algorithms
Loading...
Searching...
No Matches
Aleph::CA::VTK_Frame_Sink Class Reference

Path-pattern sink that writes VTK legacy frames. More...

#include <ca-vtk.H>

Collaboration diagram for Aleph::CA::VTK_Frame_Sink:
[legend]

Public Member Functions

 VTK_Frame_Sink (std::filesystem::path path_pattern, VTK_Write_Options opts={}, const std::size_t zero_pad=6)
 Build a VTK frame sink.
 
template<typename Lattice >
void accept (const std::size_t step, const Lattice &frame)
 Write one VTK frame.
 
void flush ()
 VTK frames are written eagerly; this is a no-op.
 

Private Attributes

std::filesystem::path pattern_
 
VTK_Write_Options opts_ {}
 
std::size_t zero_pad_ = 6
 

Detailed Description

Path-pattern sink that writes VTK legacy frames.

Definition at line 173 of file ca-vtk.H.

Constructor & Destructor Documentation

◆ VTK_Frame_Sink()

Aleph::CA::VTK_Frame_Sink::VTK_Frame_Sink ( std::filesystem::path  path_pattern,
VTK_Write_Options  opts = {},
const std::size_t  zero_pad = 6 
)
inlineexplicit

Build a VTK frame sink.

Parameters
[in]path_patternoutput path pattern.
[in]optswriter options.
[in]zero_padminimum width for {step}.

Definition at line 185 of file ca-vtk.H.

Member Function Documentation

◆ accept()

template<typename Lattice >
void Aleph::CA::VTK_Frame_Sink::accept ( const std::size_t  step,
const Lattice &  frame 
)
inline

Write one VTK frame.

Template Parameters
Latticerank-2 or rank-3 lattice type.
Parameters
[in]stepsimulation step.
[in]frameframe to write.

Definition at line 197 of file ca-vtk.H.

References ah_runtime_error_if, Aleph::blossom_maximum_cardinality_matching(), Aleph::CA::format_step_path(), opts_, out, pattern_, Aleph::CA::write_vtk_legacy(), and zero_pad_.

◆ flush()

void Aleph::CA::VTK_Frame_Sink::flush ( )
inline

VTK frames are written eagerly; this is a no-op.

Definition at line 208 of file ca-vtk.H.

Member Data Documentation

◆ opts_

VTK_Write_Options Aleph::CA::VTK_Frame_Sink::opts_ {}
private

Definition at line 176 of file ca-vtk.H.

Referenced by accept().

◆ pattern_

std::filesystem::path Aleph::CA::VTK_Frame_Sink::pattern_
private

Definition at line 175 of file ca-vtk.H.

Referenced by accept().

◆ zero_pad_

std::size_t Aleph::CA::VTK_Frame_Sink::zero_pad_ = 6
private

Definition at line 177 of file ca-vtk.H.

Referenced by accept().


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