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
OpenFOAM
primitives
Lists
wordReListMatcher.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 | 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
Class
25
Foam::wordReListMatcher
26
27
Description
28
A wrapper for matching a List of wordRe.
29
30
Note
31
The constructor should remain non-explicit. This allows automatic
32
conversion from UList<wordRe> to wordReListMatcher in search
33
functions.
34
35
SourceFiles
36
wordReListMatcherI.H
37
38
\*---------------------------------------------------------------------------*/
39
40
#ifndef wordReListMatcher_H
41
#define wordReListMatcher_H
42
43
#include "
wordReList.H
"
44
45
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46
47
namespace
Foam
48
{
49
50
/*---------------------------------------------------------------------------*\
51
Class wordReListMatcher Declaration
52
\*---------------------------------------------------------------------------*/
53
54
class
wordReListMatcher
55
{
56
// Private data
57
58
//- Reference to underlying list
59
const
UList<wordRe>
& reList_;
60
61
public
:
62
63
// Constructors
64
65
//- Construct from a List of wordRe
66
inline
wordReListMatcher
(
const
UList<wordRe>
&);
67
68
69
// Member Functions
70
71
// Access
72
73
inline
label
size
()
const
;
74
inline
bool
empty
()
const
;
75
76
//- Return underlying list of wordRe
77
inline
const
UList<wordRe>
&
operator()
()
const
;
78
79
80
// Searching
81
82
//- Return true if string matches any of the regular expressions
83
// Smart match as regular expression or as a string.
84
// Optionally specify a literal match only.
85
inline
bool
match
(
const
string
&,
bool
literalMatch=
false
)
const
;
86
87
};
88
89
90
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
91
92
}
// End namespace Foam
93
94
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
95
96
#include "
wordReListMatcherI.H
"
97
98
#endif
99
100
// ************************ vim: set sw=4 sts=4 et: ************************ //