Reference documentation for deal.II version 9.4.0
\(\newcommand{\dealvcentcolon}{\mathrel{\mathop{:}}}\) \(\newcommand{\dealcoloneq}{\dealvcentcolon\mathrel{\mkern-1.2mu}=}\) \(\newcommand{\jump}[1]{\left[\!\left[ #1 \right]\!\right]}\) \(\newcommand{\average}[1]{\left\{\!\left\{ #1 \right\}\!\right\}}\)
data_out.h
Go to the documentation of this file.
1// ---------------------------------------------------------------------
2//
3// Copyright (C) 2017 - 2020 by the deal.II authors
4//
5// This file is part of the deal.II library.
6//
7// The deal.II library is free software; you can use it, redistribute
8// it, and/or modify it under the terms of the GNU Lesser General
9// Public License as published by the Free Software Foundation; either
10// version 2.1 of the License, or (at your option) any later version.
11// The full text of the license can be found in the file LICENSE.md at
12// the top level directory of deal.II.
13//
14// ---------------------------------------------------------------------
15#ifndef dealii_particles_data_out_h
16#define dealii_particles_data_out_h
17
18#include <deal.II/base/config.h>
19
21
23
24#include <string>
25#include <vector>
26
28
29namespace Particles
30{
31 template <int dim, int spacedim>
32 class ParticleHandler;
33
43 template <int dim, int spacedim = dim>
44 class DataOut : public ::DataOutInterface<0, spacedim>
45 {
46 public:
50 DataOut() = default;
51
55 ~DataOut() = default;
56
57
73 void
75 const std::vector<std::string> &data_component_names = {},
76 const std::vector<
79
80 protected:
85 virtual const std::vector<DataOutBase::Patch<0, spacedim>> &
86 get_patches() const override;
87
92 virtual std::vector<std::string>
93 get_dataset_names() const override;
94
95
102 virtual std::vector<
103 std::tuple<unsigned int,
104 unsigned int,
105 std::string,
107 get_nonscalar_data_ranges() const override;
108
109 private:
115 std::vector<DataOutBase::Patch<0, spacedim>> patches;
116
120 std::vector<std::string> dataset_names;
121
127 std::vector<DataComponentInterpretation::DataComponentInterpretation>
129 };
130
131} // namespace Particles
132
134
135#endif
virtual const std::vector< DataOutBase::Patch< 0, spacedim > > & get_patches() const override
Definition: data_out.cc:107
std::vector< std::string > dataset_names
Definition: data_out.h:120
virtual std::vector< std::tuple< unsigned int, unsigned int, std::string, DataComponentInterpretation::DataComponentInterpretation > > get_nonscalar_data_ranges() const override
Definition: data_out.cc:129
std::vector< DataOutBase::Patch< 0, spacedim > > patches
Definition: data_out.h:115
std::vector< DataComponentInterpretation::DataComponentInterpretation > data_component_interpretations
Definition: data_out.h:128
void build_patches(const Particles::ParticleHandler< dim, spacedim > &particles, const std::vector< std::string > &data_component_names={}, const std::vector< DataComponentInterpretation::DataComponentInterpretation > &data_component_interpretations={})
Definition: data_out.cc:28
virtual std::vector< std::string > get_dataset_names() const override
Definition: data_out.cc:116
#define DEAL_II_NAMESPACE_OPEN
Definition: config.h:442
#define DEAL_II_NAMESPACE_CLOSE
Definition: config.h:443