vtkSetWriter.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration | Website: https://openfoam.org
5  \\ / A nd | Copyright (C) 2011-2023 OpenFOAM Foundation
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
11  OpenFOAM is free software: you can redistribute it and/or modify it
12  under the terms of the GNU General Public License as published by
13  the Free Software Foundation, either version 3 of the License, or
14  (at your option) any later version.
15 
16  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
19  for more details.
20 
21  You should have received a copy of the GNU General Public License
22  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
23 
24 Class
25  Foam::vtkSetWriter
26 
27 Description
28 
29 SourceFiles
30  vtkSetWriter.C
31 
32 \*---------------------------------------------------------------------------*/
33 
34 #ifndef vtkSetWriter_H
35 #define vtkSetWriter_H
36 
37 #include "setWriter.H"
38 
39 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
40 
41 namespace Foam
42 {
43 
44 /*---------------------------------------------------------------------------*\
45  Class vtkSetWriter Declaration
46 \*---------------------------------------------------------------------------*/
47 
48 class vtkSetWriter
49 :
50  public setWriter
51 {
52 
53 public:
54 
55  //- Runtime type information
56  TypeName("vtk");
57 
58 
59  // Constructors
60 
61  //- Inherit constructors
63 
64  //- Construct and return a clone
65  virtual autoPtr<setWriter> clone() const
66  {
67  return autoPtr<setWriter>(new vtkSetWriter(*this));
68  }
69 
70 
71  //- Destructor
72  virtual ~vtkSetWriter();
73 
74 
75  // Member Functions
76 
77  //- Write a coordSet and associated data
78  virtual void write
79  (
80  const fileName& outputDir,
81  const fileName& setName,
82  const coordSet& set,
83  const wordList& valueSetNames
84  #define TypeValueSetsConstArg(Type, nullArg) \
85  , const UPtrList<const Field<Type>>& Type##ValueSets
88  ) const;
89 };
90 
91 
92 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
93 
94 } // End namespace Foam
95 
96 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
97 
98 #endif
99 
100 // ************************************************************************* //
Pre-declare SubField and related Field type.
Definition: Field.H:82
A templated 1D list of pointers to objects of type <T>, where the size of the array is known and used...
Definition: UPtrList.H:66
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: autoPtr.H:51
Holds list of sampling positions.
Definition: coordSet.H:51
A class for handling file names.
Definition: fileName.H:82
Base class for writing coordinate sets with data.
Definition: setWriter.H:64
setWriter(const IOstream::streamFormat writeFormat, const IOstream::compressionType writeCompression)
Construct given write options.
Definition: setWriter.C:249
virtual autoPtr< setWriter > clone() const
Construct and return a clone.
Definition: vtkSetWriter.H:64
virtual void write(const fileName &outputDir, const fileName &setName, const coordSet &set, const wordList &valueSetNames #define TypeValueSetsConstArg(Type, nullArg)) const
Write a coordSet and associated data.
Definition: vtkSetWriter.C:53
TypeName("vtk")
Runtime type information.
virtual ~vtkSetWriter()
Destructor.
Definition: vtkSetWriter.C:46
Namespace for OpenFOAM.
FOR_ALL_FIELD_TYPES(DefineContiguousFvWallLocationDataType)
#define TypeValueSetsConstArg(Type, nullArg)