dummyTransform.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration |
5  \\ / A nd | www.openfoam.com
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8  Copyright (C) 2011-2016 OpenFOAM Foundation
9  Copyright (C) 2020 OpenCFD Ltd.
10 -------------------------------------------------------------------------------
11 License
12  This file is part of OpenFOAM.
13 
14  OpenFOAM is free software: you can redistribute it and/or modify it
15  under the terms of the GNU General Public License as published by
16  the Free Software Foundation, either version 3 of the License, or
17  (at your option) any later version.
18 
19  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22  for more details.
23 
24  You should have received a copy of the GNU General Public License
25  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26 
27 InClass
28  Foam::dummyTransform
29 
30 Description
31  Dummy transform to be used with syncTools.
32 
33 \*---------------------------------------------------------------------------*/
34 
35 #ifndef dummyTransform_H
36 #define dummyTransform_H
37 
38 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
39 
40 namespace Foam
41 {
42 
43 /*---------------------------------------------------------------------------*\
44  Class dummyTransform Declaration
45 \*---------------------------------------------------------------------------*/
46 
48 {
49 public:
50  template<class T>
51  void operator()
52  (
53  const vectorTensorTransform& vt,
54  const bool forward,
55  List<T>& fld
56  ) const
57  {}
58 
59  template<class T>
60  void operator()(const coupledPolyPatch& cpp, Field<T>& fld) const
61  {}
62 
63  template<class T, template<class> class Container>
64  void operator()(const coupledPolyPatch& cpp, Container<T>& map) const
65  {}
66 };
67 
68 
69 template<class T>
70 class pTraits<List<T>>
71 :
72  public List<T>
73 {
74 public:
75  typedef label cmptType;
76 
77  explicit pTraits(Istream& is)
78  :
79  List<T>(is)
80  {}
81 };
82 
83 template<class T>
84 class pTraits<UList<T>>
85 :
86  public UList<T>
87 {
88 public:
89  typedef label cmptType;
90 
91  explicit pTraits(Istream& is)
92  :
93  UList<T>(is)
94  {}
95 };
96 
97 template<class T>
98 class pTraits<Field<T>>
99 :
100  public Field<T>
101 {
102 public:
103  typedef label cmptType;
104 
105  explicit pTraits(Istream& is)
106  :
107  Field<T>(is)
108  {}
109 };
110 
111 template<>
112 class pTraits<face>
113 :
114  public face
115 {
116 public:
117  typedef label cmptType;
118 
119  explicit pTraits(Istream& is)
120  :
121  face(is)
122  {}
123 };
124 
125 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
126 
127 } // End namespace Foam
128 
129 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
130 
131 #endif
132 
133 // ************************************************************************* //
Foam::dummyTransform::operator()
void operator()(const coupledPolyPatch &cpp, Container< T > &map) const
Definition: dummyTransform.H:64
Foam::pTraits< face >::cmptType
label cmptType
Definition: dummyTransform.H:117
Foam::coupledPolyPatch
The coupledPolyPatch is an abstract base class for patches that couple regions of the computational d...
Definition: coupledPolyPatch.H:53
Foam::dummyTransform
Definition: dummyTransform.H:47
Foam::dummyTransform::operator()
void operator()(const coupledPolyPatch &cpp, Field< T > &fld) const
Definition: dummyTransform.H:60
Foam::pTraits< Field< T > >::cmptType
label cmptType
Definition: dummyTransform.H:103
Foam::Field< T >
Foam::Istream
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
Definition: Istream.H:61
Foam::pTraits< face >::pTraits
pTraits(Istream &is)
Definition: dummyTransform.H:119
Foam::pTraits< UList< T > >::cmptType
label cmptType
Definition: dummyTransform.H:89
Foam::T
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
Definition: FieldFieldFunctions.C:58
fld
gmvFile<< "tracers "<< particles.size()<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().x()<< ' ';}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().y()<< ' ';}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().z()<< ' ';}gmvFile<< nl;for(const word &name :lagrangianScalarNames){ IOField< scalar > fld(IOobject(name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
Definition: gmvOutputLagrangian.H:23
Foam
Namespace for OpenFOAM.
Definition: atmBoundaryLayer.C:33
Foam::pTraits< UList< T > >::pTraits
pTraits(Istream &is)
Definition: dummyTransform.H:91
Foam::pTraits< List< T > >::cmptType
label cmptType
Definition: dummyTransform.H:75
Foam::List
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
Definition: HashTable.H:102
Foam::pTraits
Traits class for primitives.
Definition: pTraits.H:54
Foam::vectorTensorTransform
Vector-tensor class used to perform translations and rotations in 3D space.
Definition: vectorTensorTransform.H:63
Foam::UList
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
Definition: HashTable.H:103
Foam::pTraits< Field< T > >::pTraits
pTraits(Istream &is)
Definition: dummyTransform.H:105
Foam::pTraits< List< T > >::pTraits
pTraits(Istream &is)
Definition: dummyTransform.H:77
Foam::face
A face is a list of labels corresponding to mesh vertices.
Definition: face.H:72