cellSetOptionI.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-2015 OpenFOAM Foundation
9 -------------------------------------------------------------------------------
10 License
11  This file is part of OpenFOAM.
12 
13  OpenFOAM is free software: you can redistribute it and/or modify it
14  under the terms of the GNU General Public License as published by
15  the Free Software Foundation, either version 3 of the License, or
16  (at your option) any later version.
17 
18  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
19  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
20  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21  for more details.
22 
23  You should have received a copy of the GNU General Public License
24  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
25 
26 \*---------------------------------------------------------------------------*/
27 
28 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
29 
30 inline Foam::scalar Foam::fv::cellSetOption::timeStart() const
31 {
32  return timeStart_;
33 }
34 
35 
36 inline Foam::scalar Foam::fv::cellSetOption::duration() const
37 {
38  return duration_;
39 }
40 
41 
42 inline bool Foam::fv::cellSetOption::inTimeLimits(const scalar time) const
43 {
44  return
45  (
46  (timeStart_ < 0)
47  ||
48  (
49  (mesh_.time().value() >= timeStart_)
50  && (mesh_.time().value() <= (timeStart_ + duration_))
51  )
52  );
53 }
54 
55 
58 {
59  return selectionMode_;
60 }
61 
62 
64 {
65  return cellSetName_;
66 }
67 
68 
69 inline Foam::scalar Foam::fv::cellSetOption::V() const
70 {
71  return V_;
72 }
73 
74 
76 {
77  return cells_;
78 }
79 
80 
81 inline Foam::scalar& Foam::fv::cellSetOption::timeStart()
82 {
83  return timeStart_;
84 }
85 
86 
87 inline Foam::scalar& Foam::fv::cellSetOption::duration()
88 {
89  return duration_;
90 }
91 
92 
93 // ************************************************************************* //
Foam::fv::cellSetOption::duration
scalar duration() const
Return const access to the duration.
Definition: cellSetOptionI.H:36
Foam::word
A class for handling words, derived from Foam::string.
Definition: word.H:62
Foam::fv::cellSetOption::V
scalar V() const
Return const access to the total cell volume.
Definition: cellSetOptionI.H:69
Foam::fv::cellSetOption::cellSetName
const word & cellSetName() const
Return const access to the name of cell set for "cellSet".
Definition: cellSetOptionI.H:63
Foam::fv::cellSetOption::cells
const labelList & cells() const
Return const access to the cell set.
Definition: cellSetOptionI.H:75
Foam::fv::cellSetOption::selectionMode
const selectionModeType & selectionMode() const
Return const access to the cell selection mode.
Definition: cellSetOptionI.H:57
Foam::fv::cellSetOption::selectionModeType
selectionModeType
Enumeration for selection mode types.
Definition: cellSetOption.H:172
Foam::fv::cellSetOption::timeStart
scalar timeStart() const
Return const access to the time start.
Definition: cellSetOptionI.H:30
Foam::List< label >
Foam::fv::cellSetOption::inTimeLimits
bool inTimeLimits(const scalar time) const
Return true if within time limits.
Definition: cellSetOptionI.H:42
Foam::fv::cellSetOption::timeStart_
scalar timeStart_
Start time of fvOption.
Definition: cellSetOption.H:189