Home
Downloads
Documentation
Installation
User Guide
man-pages
API Documentation
README
Release Notes
Changes
License
Support
SourceForge Project
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
src
postProcessing
foamCalcFunctions
calcType
calcType.C
Go to the documentation of this file.
1
/*---------------------------------------------------------------------------*\
2
========= |
3
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4
\\ / O peration |
5
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
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
\*---------------------------------------------------------------------------*/
25
26
#include <
foamCalcFunctions/calcType.H
>
27
28
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
29
30
defineTypeNameAndDebug
(
calcType
, 0);
31
32
defineRunTimeSelectionTable
(
calcType
,
dictionary
);
33
34
35
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
36
37
Foam::calcType::calcType
()
38
{}
39
40
41
// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
42
43
Foam::calcType::~calcType
()
44
{}
45
46
47
// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * //
48
49
void
Foam::calcType::init
()
50
{
51
// Do nothing
52
}
53
54
55
void
Foam::calcType::preCalc
56
(
57
const
argList
&
args
,
58
const
Time
& runTime,
59
const
fvMesh
&
mesh
60
)
61
{
62
// Do nothing
63
}
64
65
66
void
Foam::calcType::calc
67
(
68
const
argList
& args,
69
const
Time
& runTime,
70
const
fvMesh
& mesh
71
)
72
{
73
// Do nothing
74
}
75
76
77
void
Foam::calcType::postCalc
78
(
79
const
argList
& args,
80
const
Time
& runTime,
81
const
fvMesh
& mesh
82
)
83
{
84
// Do nothing
85
}
86
87
88
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
89
90
void
Foam::calcType::tryInit
()
91
{
92
FatalIOError
.
throwExceptions
();
93
94
try
95
{
96
init();
97
}
98
catch
(
IOerror
& err)
99
{
100
Warning
<< err <<
endl
;
101
}
102
}
103
104
105
void
Foam::calcType::tryPreCalc
106
(
107
const
argList
& args,
108
const
Time
& runTime,
109
const
fvMesh
& mesh
110
)
111
{
112
FatalIOError
.
throwExceptions
();
113
114
try
115
{
116
preCalc(args, runTime, mesh);
117
}
118
catch
(
IOerror
& err)
119
{
120
Warning
<< err <<
endl
;
121
}
122
}
123
124
125
void
Foam::calcType::tryCalc
126
(
127
const
argList
& args,
128
const
Time
& runTime,
129
const
fvMesh
& mesh
130
)
131
{
132
FatalIOError
.
throwExceptions
();
133
134
try
135
{
136
calc
(args, runTime, mesh);
137
}
138
catch
(
IOerror
& err)
139
{
140
Warning
<< err <<
endl
;
141
}
142
}
143
144
145
void
Foam::calcType::tryPostCalc
146
(
147
const
argList
& args,
148
const
Time
& runTime,
149
const
fvMesh
& mesh
150
)
151
{
152
FatalIOError
.
throwExceptions
();
153
154
try
155
{
156
postCalc(args, runTime, mesh);
157
}
158
catch
(
IOerror
& err)
159
{
160
Warning
<< err <<
endl
;
161
}
162
}
163
164
165
// ************************ vim: set sw=4 sts=4 et: ************************ //