www.mooseframework.org
CSV.h
Go to the documentation of this file.
1 /****************************************************************/
2 /* DO NOT MODIFY THIS HEADER */
3 /* MOOSE - Multiphysics Object Oriented Simulation Environment */
4 /* */
5 /* (c) 2010 Battelle Energy Alliance, LLC */
6 /* ALL RIGHTS RESERVED */
7 /* */
8 /* Prepared by Battelle Energy Alliance, LLC */
9 /* Under Contract No. DE-AC07-05ID14517 */
10 /* With the U. S. Department of Energy */
11 /* */
12 /* See COPYRIGHT for full restrictions */
13 /****************************************************************/
14 
15 #ifndef CSV_H
16 #define CSV_H
17 
18 // MOOSE includes
19 #include "TableOutput.h"
20 
21 // Forward declarations
22 class CSV;
23 
24 template <>
26 
32 class CSV : public TableOutput
33 {
34 public:
44 
45 protected:
49  virtual void output(const ExecFlagType & type) override;
50 
55  virtual std::string filename() override;
56 
61  void initialSetup() override;
62 
66  virtual void outputScalarVariables() override;
67 
71  virtual void outputPostprocessors() override;
72 
76  virtual void outputVectorPostprocessors() override;
77 
78 private:
80  bool _align;
81 
83  unsigned int _precision;
84 
86  std::string _delimiter;
87 
90 
93 
95  const bool _sort_columns;
96 
99 };
100 
101 #endif /* CSV_H */
unsigned int _precision
Decimal digits per number in the CSV file.
Definition: CSV.h:83
virtual void output(const ExecFlagType &type) override
Output the table to a *.csv file.
Definition: CSV.C:100
bool _write_all_table
Flag for writting scalar and/or postprocessor data.
Definition: CSV.h:89
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
virtual std::string filename() override
The filename for the output file.
Definition: CSV.C:73
bool _write_vector_table
Flag for writting vector postprocessor data.
Definition: CSV.h:92
virtual void outputPostprocessors() override
Sets the write flag and calls TableOutput::outputPostprocessors()
Definition: CSV.C:86
bool _align
Flag for aligning data in .csv file.
Definition: CSV.h:80
Based class for adding basic filename support to output base class.
Definition: CSV.h:32
bool _recovering
Flag indicating MOOSE is recovering via –recover command-line option.
Definition: CSV.h:98
std::string _delimiter
The delimiter used when writing the CSV file.
Definition: CSV.h:86
virtual void outputVectorPostprocessors() override
Sets the write flag and calls TableOutput::outputVectorPostprocessors()
Definition: CSV.C:93
virtual void outputScalarVariables() override
Sets the write flag and calls TableOutput::outputScalarVariables()
Definition: CSV.C:79
MatType type
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseObject.h:53
const bool _sort_columns
Flag for sorting column names.
Definition: CSV.h:95
Base class for scalar variables and postprocessors output objects.
Definition: TableOutput.h:39
ExecFlagType
Execution flags - when is the object executed/evaluated.
Definition: MooseTypes.h:90
CSV(const InputParameters &parameters)
Class constructor.
Definition: CSV.C:44
InputParameters validParams< CSV >()
Definition: CSV.C:22
void initialSetup() override
Setup the CSV output If restarting and the append_restart flag is false, then the output data is clea...
Definition: CSV.C:57