1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 2011-2011 OpenCFD Ltd.
7 -------------------------------------------------------------------------------
9 This file is part of OpenFOAM.
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.
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
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/>.
30 \*---------------------------------------------------------------------------*/
32 #ifndef tableReaders_H
33 #define tableReaders_H
35 #include "tableReader.H"
36 #include "fieldTypes.H"
38 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
40 // Only used internally
41 #define makeTypeTableReadersTypeName(typeTableReader, dataType) \
43 defineNamedTemplateTypeNameAndDebug(typeTableReader< dataType >, 0)
45 // Sometimes used externally
46 #define makeTableReadersTypeName(typeTableReader) \
48 makeTypeTableReadersTypeName(typeTableReader, scalar); \
49 makeTypeTableReadersTypeName(typeTableReader, vector); \
50 makeTypeTableReadersTypeName(typeTableReader, sphericalTensor); \
51 makeTypeTableReadersTypeName(typeTableReader, symmTensor); \
52 makeTypeTableReadersTypeName(typeTableReader, tensor)
54 // Define type info for single dataType template instantiation (eg, vector)
55 #define makeTableReaderType(typeTableReader, dataType) \
57 defineNamedTemplateTypeNameAndDebug(typeTableReader< dataType >, 0); \
58 addTemplatedToRunTimeSelectionTable \
60 tableReader, typeTableReader, dataType, dictionary \
64 // Define type info for scalar, vector etc. instantiations
65 #define makeTableReaders(typeTableReader) \
67 makeTableReaderType(typeTableReader, scalar); \
68 makeTableReaderType(typeTableReader, vector); \
69 makeTableReaderType(typeTableReader, sphericalTensor); \
70 makeTableReaderType(typeTableReader, symmTensor); \
71 makeTableReaderType(typeTableReader, tensor)
74 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
78 // ************************************************************************* //