Imported Upstream version 1.64.0
[platform/upstream/boost.git] / libs / regex / doc / html / boost_regex / background_information / examples.html
1 <html>
2 <head>
3 <meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
4 <title>Test and Example Programs</title>
5 <link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
6 <meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
7 <link rel="home" href="../../index.html" title="Boost.Regex 5.1.3">
8 <link rel="up" href="../background_information.html" title="Background Information">
9 <link rel="prev" href="thread_safety.html" title="Thread Safety">
10 <link rel="next" href="futher.html" title="References and Further Information">
11 </head>
12 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
13 <table cellpadding="2" width="100%"><tr>
14 <td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
15 <td align="center"><a href="../../../../../../index.html">Home</a></td>
16 <td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
17 <td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
18 <td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
19 <td align="center"><a href="../../../../../../more/index.htm">More</a></td>
20 </tr></table>
21 <hr>
22 <div class="spirit-nav">
23 <a accesskey="p" href="thread_safety.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../background_information.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="futher.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
24 </div>
25 <div class="section">
26 <div class="titlepage"><div><div><h3 class="title">
27 <a name="boost_regex.background_information.examples"></a><a class="link" href="examples.html" title="Test and Example Programs">Test and
28       Example Programs</a>
29 </h3></div></div></div>
30 <h5>
31 <a name="boost_regex.background_information.examples.h0"></a>
32         <span class="phrase"><a name="boost_regex.background_information.examples.test_programs"></a></span><a class="link" href="examples.html#boost_regex.background_information.examples.test_programs">Test
33         Programs</a>
34       </h5>
35 <p>
36         <span class="bold"><strong>regress:</strong></span>
37       </p>
38 <p>
39         A regression test application that gives the matching/searching algorithms
40         a full workout. The presence of this program is your guarantee that the library
41         will behave as claimed - at least as far as those items tested are concerned
42         - if anyone spots anything that isn't being tested I'd be glad to hear about
43         it.
44       </p>
45 <p>
46         Files:
47       </p>
48 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
49 <li class="listitem">
50             <a href="../../../../test/regress/main.cpp" target="_top">main.cpp</a>
51           </li>
52 <li class="listitem">
53             <a href="../../../../test/regress/basic_tests.cpp" target="_top">basic_tests.cpp</a>
54           </li>
55 <li class="listitem">
56             <a href="../../../../test/regress/test_alt.cpp" target="_top">test_alt.cpp</a>
57           </li>
58 <li class="listitem">
59             <a href="../../../../test/regress/test_anchors.cpp" target="_top">test_anchors.cpp</a>
60           </li>
61 <li class="listitem">
62             <a href="../../../../test/regress/test_asserts.cpp" target="_top">test_asserts.cpp</a>
63           </li>
64 <li class="listitem">
65             <a href="../../../../test/regress/test_backrefs.cpp" target="_top">test_backrefs.cpp</a>
66           </li>
67 <li class="listitem">
68             <a href="../../../../test/regress/test_deprecated.cpp" target="_top">test_deprecated.cpp</a>
69           </li>
70 <li class="listitem">
71             <a href="../../../../test/regress/test_emacs.cpp" target="_top">test_emacs.cpp</a>
72           </li>
73 <li class="listitem">
74             <a href="../../../../test/regress/test_escapes.cpp" target="_top">test_escapes.cpp</a>
75           </li>
76 <li class="listitem">
77             <a href="../../../../test/regress/test_grep.cpp" target="_top">test_grep.cpp</a>
78           </li>
79 <li class="listitem">
80             <a href="../../../../test/regress/test_icu.cpp" target="_top">test_icu.cpp</a>
81           </li>
82 <li class="listitem">
83             <a href="../../../../test/regress/test_locale.cpp" target="_top">test_locale.cpp</a>
84           </li>
85 <li class="listitem">
86             <a href="../../../../test/regress/test_mfc.cpp" target="_top">test_mfc.cpp</a>
87           </li>
88 <li class="listitem">
89             <a href="../../../../test/regress/test_non_greedy_repeats.cpp" target="_top">test_non_greedy_repeats.cpp</a>
90           </li>
91 <li class="listitem">
92             <a href="../../../../test/regress/test_operators.cpp" target="_top">test_operators.cpp</a>
93           </li>
94 <li class="listitem">
95             <a href="../../../../test/regress/test_overloads.cpp" target="_top">test_overloads.cpp</a>
96           </li>
97 <li class="listitem">
98             <a href="../../../../test/regress/test_perl_ex.cpp" target="_top">test_perl_ex.cpp</a>
99           </li>
100 <li class="listitem">
101             <a href="../../../../test/regress/test_replace.cpp" target="_top">test_replace.cpp</a>
102           </li>
103 <li class="listitem">
104             <a href="../../../../test/regress/test_sets.cpp" target="_top">test_sets.cpp</a>
105           </li>
106 <li class="listitem">
107             <a href="../../../../test/regress/test_simple_repeats.cpp" target="_top">test_simple_repeats.cpp</a>
108           </li>
109 <li class="listitem">
110             <a href="../../../../test/regress/test_tricky_cases.cpp" target="_top">test_tricky_cases.cpp</a>
111           </li>
112 <li class="listitem">
113             <a href="../../../../test/regress/test_unicode.cpp" target="_top">test_unicode.cpp</a>
114           </li>
115 </ul></div>
116 <p>
117         <span class="bold"><strong>bad_expression_test:</strong></span>
118       </p>
119 <p>
120         Verifies that "bad" regular expressions don't cause the matcher
121         to go into infinite loops, but to throw an exception instead.
122       </p>
123 <p>
124         Files: <a href="../../../../test/pathology/bad_expression_test.cpp" target="_top">bad_expression_test.cpp</a>.
125       </p>
126 <p>
127         <span class="bold"><strong>recursion_test:</strong></span>
128       </p>
129 <p>
130         Verifies that the matcher can't overrun the stack (no matter what the expression).
131       </p>
132 <p>
133         Files: <a href="../../../../test/pathology/recursion_test.cpp" target="_top">recursion_test.cpp</a>.
134       </p>
135 <p>
136         <span class="bold"><strong>concepts:</strong></span>
137       </p>
138 <p>
139         Verifies that the library meets all documented concepts (a compile only test).
140       </p>
141 <p>
142         Files: <a href="../../../../test/concepts/concept_check.cpp" target="_top">concept_check.cpp</a>.
143       </p>
144 <p>
145         <span class="bold"><strong>captures_test:</strong></span>
146       </p>
147 <p>
148         Test code for captures.
149       </p>
150 <p>
151         Files: <a href="../../../../test/captures/captures_test.cpp" target="_top">captures_test.cpp</a>.
152       </p>
153 <h5>
154 <a name="boost_regex.background_information.examples.h1"></a>
155         <span class="phrase"><a name="boost_regex.background_information.examples.example_programs"></a></span><a class="link" href="examples.html#boost_regex.background_information.examples.example_programs">Example
156         programs</a>
157       </h5>
158 <p>
159         <span class="bold"><strong>grep</strong></span>
160       </p>
161 <p>
162         A simple grep implementation, run with the -h command line option to find
163         out its usage.
164       </p>
165 <p>
166         Files: <a href="../../../../example/grep/grep.cpp" target="_top">grep.cpp</a>
167       </p>
168 <p>
169         <span class="bold"><strong>timer.exe</strong></span>
170       </p>
171 <p>
172         A simple interactive expression matching application, the results of all
173         matches are timed, allowing the programmer to optimize their regular expressions
174         where performance is critical.
175       </p>
176 <p>
177         Files: <a href="../../../../example/timer/regex_timer.cpp" target="_top">regex_timer.cpp</a>.
178       </p>
179 <h5>
180 <a name="boost_regex.background_information.examples.h2"></a>
181         <span class="phrase"><a name="boost_regex.background_information.examples.code_snippets"></a></span><a class="link" href="examples.html#boost_regex.background_information.examples.code_snippets">Code
182         snippets</a>
183       </h5>
184 <p>
185         The snippets examples contain the code examples used in the documentation:
186       </p>
187 <p>
188         <a href="../../../../example/snippets/captures_example.cpp" target="_top">captures_example.cpp</a>:
189         Demonstrates the use of captures.
190       </p>
191 <p>
192         <a href="../../../../example/snippets/credit_card_example.cpp" target="_top">credit_card_example.cpp</a>:
193         Credit card number formatting code.
194       </p>
195 <p>
196         <a href="../../../../example/snippets/partial_regex_grep.cpp" target="_top">partial_regex_grep.cpp</a>:
197         Search example using partial matches.
198       </p>
199 <p>
200         <a href="../../../../example/snippets/partial_regex_match.cpp" target="_top">partial_regex_match.cpp</a>:
201         regex_match example using partial matches.
202       </p>
203 <p>
204         <a href="../../../../example/snippets/regex_iterator_example.cpp" target="_top">regex_iterator_example.cpp</a>:
205         Iterating through a series of matches.
206       </p>
207 <p>
208         <a href="../../../../example/snippets/regex_match_example.cpp" target="_top">regex_match_example.cpp</a>:
209         ftp based regex_match example.
210       </p>
211 <p>
212         <a href="../../../../example/snippets/regex_merge_example.cpp" target="_top">regex_merge_example.cpp</a>:
213         regex_merge example: converts a C++ file to syntax highlighted HTML.
214       </p>
215 <p>
216         <a href="../../../../example/snippets/regex_replace_example.cpp" target="_top">regex_replace_example.cpp</a>:
217         regex_replace example: converts a C++ file to syntax highlighted HTML
218       </p>
219 <p>
220         <a href="../../../../example/snippets/regex_search_example.cpp" target="_top">regex_search_example.cpp</a>:
221         regex_search example: searches a cpp file for class definitions.
222       </p>
223 <p>
224         <a href="../../../../example/snippets/regex_token_iterator_eg_1.cpp" target="_top">regex_token_iterator_eg_1.cpp</a>:
225         split a string into a series of tokens.
226       </p>
227 <p>
228         <a href="../../../../example/snippets/regex_token_iterator_eg_2.cpp" target="_top">regex_token_iterator_eg_2.cpp</a>:
229         enumerate the linked URL's in a HTML file.
230       </p>
231 <p>
232         The following are deprecated:
233       </p>
234 <p>
235         <a href="../../../../example/snippets/regex_grep_example_1.cpp" target="_top">regex_grep_example_1.cpp</a>:
236         regex_grep example 1: searches a cpp file for class definitions.
237       </p>
238 <p>
239         <a href="../../../../example/snippets/regex_grep_example_2.cpp" target="_top">regex_grep_example_2.cpp</a>:
240         regex_grep example 2: searches a cpp file for class definitions, using a
241         global callback function.
242       </p>
243 <p>
244         <a href="../../../../example/snippets/regex_grep_example_3.cpp" target="_top">regex_grep_example_3.cpp</a>:
245         regex_grep example 2: searches a cpp file for class definitions, using a
246         bound member function callback.
247       </p>
248 <p>
249         <a href="../../../../example/snippets/regex_grep_example_4.cpp" target="_top">regex_grep_example_4.cpp</a>:
250         regex_grep example 2: searches a cpp file for class definitions, using a
251         C++ Builder closure as a callback.
252       </p>
253 <p>
254         <a href="../../../../example/snippets/regex_split_example_1.cpp" target="_top">regex_split_example_1.cpp</a>:
255         regex_split example: split a string into tokens.
256       </p>
257 <p>
258         <a href="../../../../example/snippets/regex_split_example_2.cpp" target="_top">regex_split_example_2.cpp</a>
259         : regex_split example: spit out linked URL's.
260       </p>
261 </div>
262 <table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
263 <td align="left"></td>
264 <td align="right"><div class="copyright-footer">Copyright &#169; 1998-2013 John Maddock<p>
265         Distributed under the Boost Software License, Version 1.0. (See accompanying
266         file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
267       </p>
268 </div></td>
269 </tr></table>
270 <hr>
271 <div class="spirit-nav">
272 <a accesskey="p" href="thread_safety.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../background_information.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="futher.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
273 </div>
274 </body>
275 </html>