STLdoc
STLdocumentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
regex_constants.h
Go to the documentation of this file.
1 // class template regex -*- C++ -*-
2 
3 // Copyright (C) 2010-2013 Free Software Foundation, Inc.
4 //
5 // This file is part of the GNU ISO C++ Library. This library is free
6 // software; you can redistribute it and/or modify it under the
7 // terms of the GNU General Public License as published by the
8 // Free Software Foundation; either version 3, or (at your option)
9 // any later version.
10 
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 // GNU General Public License for more details.
15 
16 // Under Section 7 of GPL version 3, you are granted additional
17 // permissions described in the GCC Runtime Library Exception, version
18 // 3.1, as published by the Free Software Foundation.
19 
20 // You should have received a copy of the GNU General Public License and
21 // a copy of the GCC Runtime Library Exception along with this program;
22 // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
23 // <http://www.gnu.org/licenses/>.
24 
33 namespace std _GLIBCXX_VISIBILITY(default)
34 {
46 namespace regex_constants
47 {
48 _GLIBCXX_BEGIN_NAMESPACE_VERSION
49 
54  enum __syntax_option
55  {
56  _S_icase,
57  _S_nosubs,
58  _S_optimize,
59  _S_collate,
60  _S_ECMAScript,
61  _S_basic,
62  _S_extended,
63  _S_awk,
64  _S_grep,
65  _S_egrep,
66  _S_syntax_last
67  };
68 
80  typedef unsigned int syntax_option_type;
81 
86  constexpr syntax_option_type icase = 1 << _S_icase;
87 
93  constexpr syntax_option_type nosubs = 1 << _S_nosubs;
94 
101  constexpr syntax_option_type optimize = 1 << _S_optimize;
102 
107  constexpr syntax_option_type collate = 1 << _S_collate;
108 
117  constexpr syntax_option_type ECMAScript = 1 << _S_ECMAScript;
118 
126  constexpr syntax_option_type basic = 1 << _S_basic;
127 
134  constexpr syntax_option_type extended = 1 << _S_extended;
135 
144  constexpr syntax_option_type awk = 1 << _S_awk;
145 
152  constexpr syntax_option_type grep = 1 << _S_grep;
153 
160  constexpr syntax_option_type egrep = 1 << _S_egrep;
161 
163 
174 
175  enum __match_flag
176  {
177  _S_not_bol,
178  _S_not_eol,
179  _S_not_bow,
180  _S_not_eow,
181  _S_any,
182  _S_not_null,
183  _S_continuous,
184  _S_prev_avail,
185  _S_sed,
186  _S_no_copy,
187  _S_first_only,
188  _S_match_flag_last
189  };
190 
198  typedef std::bitset<_S_match_flag_last> match_flag_type;
199 
203  constexpr match_flag_type match_default = 0;
204 
210  constexpr match_flag_type match_not_bol = 1 << _S_not_bol;
211 
217  constexpr match_flag_type match_not_eol = 1 << _S_not_eol;
218 
223  constexpr match_flag_type match_not_bow = 1 << _S_not_bow;
224 
229  constexpr match_flag_type match_not_eow = 1 << _S_not_eow;
230 
235  constexpr match_flag_type match_any = 1 << _S_any;
236 
240  constexpr match_flag_type match_not_null = 1 << _S_not_null;
241 
245  constexpr match_flag_type match_continuous = 1 << _S_continuous;
246 
252  constexpr match_flag_type match_prev_avail = 1 << _S_prev_avail;
253 
280  constexpr match_flag_type format_default = 0;
281 
288  constexpr match_flag_type format_sed = 1 << _S_sed;
289 
295  constexpr match_flag_type format_no_copy = 1 << _S_no_copy;
296 
301  constexpr match_flag_type format_first_only = 1 << _S_first_only;
302 
304 
305 _GLIBCXX_END_NAMESPACE_VERSION
306 } // namespace regex_constants
307 
308 /* @} */ // group regex
309 } // namespace std
310 
namespace std _GLIBCXX_VISIBILITY(default)
Definition: auto_ptr.h:36