mirror of
https://github.com/boostorg/regex.git
synced 2025-07-05 00:26:30 +02:00
Fixed broken links, added copyright declarations, renamed some long file names
[SVN r18525]
This commit is contained in:
@ -1,3 +1,5 @@
|
|||||||
|
# copyright John Maddock 2003
|
||||||
|
|
||||||
subproject libs/regex/build ;
|
subproject libs/regex/build ;
|
||||||
|
|
||||||
SOURCES = c_regex_traits c_regex_traits_common cpp_regex_traits
|
SOURCES = c_regex_traits c_regex_traits_common cpp_regex_traits
|
||||||
@ -143,3 +145,4 @@ stage bin-stage : <lib>boost_regex <dll>boost_regex
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -26,7 +26,7 @@
|
|||||||
<br>
|
<br>
|
||||||
<hr>
|
<hr>
|
||||||
<h3>Synopsis</h3>
|
<h3>Synopsis</h3>
|
||||||
<p>#include <<a href="../../boost/regex/pattern_except.hpp">boost/pattern_except.hpp</a>></p>
|
<p>#include <<a href="../../../boost/regex/pattern_except.hpp">boost/pattern_except.hpp</a>></p>
|
||||||
<p>The class <code>bad_expression</code> defines the type of objects thrown as
|
<p>The class <code>bad_expression</code> defines the type of objects thrown as
|
||||||
exceptions to report errors during the conversion from a string representing a
|
exceptions to report errors during the conversion from a string representing a
|
||||||
regular expression to a finite state machine. </p>
|
regular expression to a finite state machine. </p>
|
||||||
|
@ -35,7 +35,7 @@ border="0">
|
|||||||
<h3>Synopsis</h3>
|
<h3>Synopsis</h3>
|
||||||
|
|
||||||
<pre>
|
<pre>
|
||||||
#include <<a href="../../boost/regex.hpp">boost/regex.hpp</a>>
|
#include <<a href="../../../boost/regex.hpp">boost/regex.hpp</a>>
|
||||||
</pre>
|
</pre>
|
||||||
|
|
||||||
<p>The template class <em>basic_regex</em> encapsulates regular
|
<p>The template class <em>basic_regex</em> encapsulates regular
|
||||||
|
@ -38,7 +38,7 @@ border="0">
|
|||||||
john_maddock@compuserve.com</a>, the home page for this library is
|
john_maddock@compuserve.com</a>, the home page for this library is
|
||||||
at <a href="http://ourworld.compuserve.com/homepages/john_maddock/regexpp.htm">
|
at <a href="http://ourworld.compuserve.com/homepages/john_maddock/regexpp.htm">
|
||||||
http://ourworld.compuserve.com/homepages/john_maddock/regexpp.htm</a>,
|
http://ourworld.compuserve.com/homepages/john_maddock/regexpp.htm</a>,
|
||||||
and the official boost version can be obtained from <a href="../libraries.htm">www.boost.org/libraries.htm</a>.</p>
|
and the official boost version can be obtained from <a href="../../libraries.htm">www.boost.org/libraries.htm</a>.</p>
|
||||||
|
|
||||||
<p>I am indebted to Robert Sedgewick's "Algorithms in C++" for
|
<p>I am indebted to Robert Sedgewick's "Algorithms in C++" for
|
||||||
forcing me to think about algorithms and their performance, and to
|
forcing me to think about algorithms and their performance, and to
|
||||||
|
@ -34,7 +34,7 @@ border="0">
|
|||||||
|
|
||||||
|
|
||||||
<hr>
|
<hr>
|
||||||
<p>Format strings are used by the algorithm <a href="template_class_ref.htm#reg_merge">regex_merge</a> and by <a
|
<p>Format strings are used by the algorithm <a href="regex_replace.html">regex_replace</a> and by <a
|
||||||
href="match_results.html">match_results::format</a>, and are used
|
href="match_results.html">match_results::format</a>, and are used
|
||||||
to transform one string into another.</p>
|
to transform one string into another.</p>
|
||||||
|
|
||||||
|
@ -23,12 +23,6 @@
|
|||||||
</TABLE>
|
</TABLE>
|
||||||
</P>
|
</P>
|
||||||
<HR>
|
<HR>
|
||||||
<p></p>
|
|
||||||
<P><EM>[ </EM><STRONG><I>Important</I></STRONG><EM>: If you are upgrading from the
|
|
||||||
2.x version of this library then you will find a number of changes to the
|
|
||||||
documented header names and library interfaces, existing code should still
|
|
||||||
compile unchanged however - see </EM><A href="appendix.htm#upgrade"><FONT color="#0000ff">
|
|
||||||
<EM>Note for Upgraders</EM></FONT></A><EM>. ]</EM></P>
|
|
||||||
<P>When you extract the library from its zip file, you must preserve its internal
|
<P>When you extract the library from its zip file, you must preserve its internal
|
||||||
directory structure (for example by using the -d option when extracting). If
|
directory structure (for example by using the -d option when extracting). If
|
||||||
you didn't do that when extracting, then you'd better stop reading this, delete
|
you didn't do that when extracting, then you'd better stop reading this, delete
|
||||||
@ -37,7 +31,7 @@
|
|||||||
<P>This library should not need configuring before use; most popular
|
<P>This library should not need configuring before use; most popular
|
||||||
compilers/standard libraries/platforms are already supported "as is". If you do
|
compilers/standard libraries/platforms are already supported "as is". If you do
|
||||||
experience configuration problems, or just want to test the configuration with
|
experience configuration problems, or just want to test the configuration with
|
||||||
your compiler, then the process is the same as for all of boost; see the <A href="../config/config.htm">
|
your compiler, then the process is the same as for all of boost; see the <A href="../../config/config.htm">
|
||||||
configuration library documentation</A>.</P>
|
configuration library documentation</A>.</P>
|
||||||
<P>The library will encase all code inside namespace boost.
|
<P>The library will encase all code inside namespace boost.
|
||||||
</P>
|
</P>
|
||||||
@ -187,7 +181,7 @@
|
|||||||
<P>LDFLAGS: additional linker options.</P>
|
<P>LDFLAGS: additional linker options.</P>
|
||||||
<P>LIBS: additional library files.</P>
|
<P>LIBS: additional library files.</P>
|
||||||
<P>For the more adventurous there is a configure script in
|
<P>For the more adventurous there is a configure script in
|
||||||
<boost>/libs/config; see the <A href="../config/config.htm">config library
|
<boost>/libs/config; see the <A href="../../config/config.htm">config library
|
||||||
documentation</A>.</P>
|
documentation</A>.</P>
|
||||||
<P><B><A name="sun"></A>Sun Workshop 6.1</B></P>
|
<P><B><A name="sun"></A>Sun Workshop 6.1</B></P>
|
||||||
<P>There is a makefile for the sun (6.1) compiler (C++ version 3.12). From the
|
<P>There is a makefile for the sun (6.1) compiler (C++ version 3.12). From the
|
||||||
@ -214,14 +208,14 @@
|
|||||||
<P>will build v9 variants of the regex library named libboost_regex_v9.a etc.</P>
|
<P>will build v9 variants of the regex library named libboost_regex_v9.a etc.</P>
|
||||||
<P><B><A name="other"></A>Other compilers:</B>
|
<P><B><A name="other"></A>Other compilers:</B>
|
||||||
</P>
|
</P>
|
||||||
<P>There is a generic makefile (<A href="build/generic.mak">generic.mak</A>
|
<P>There is a generic makefile (<A href="../build/generic.mak">generic.mak</A>
|
||||||
) provided in <boost-root>/libs/regex/build - see that makefile for
|
) provided in <boost-root>/libs/regex/build - see that makefile for
|
||||||
details of environment variables that need to be set before use.
|
details of environment variables that need to be set before use.
|
||||||
<P>
|
<P>
|
||||||
Alternatively you can using the <A href="../../tools/build/index.html">Jam based
|
Alternatively you can using the <A href="../../../tools/build/index.html">Jam based
|
||||||
build system</A>: cd into <boost>/libs/regex/build and run:<PRE>bjam -sTOOLS=mytoolset</PRE>
|
build system</A>: cd into <boost>/libs/regex/build and run:<PRE>bjam -sTOOLS=mytoolset</PRE>
|
||||||
<P>
|
<P>
|
||||||
If you need to configure the library for your platform, then refer to the <A href="../config/config.htm">
|
If you need to configure the library for your platform, then refer to the <A href="../../config/config.htm">
|
||||||
config library documentation</A>
|
config library documentation</A>
|
||||||
.
|
.
|
||||||
<P>
|
<P>
|
||||||
|
@ -44,7 +44,7 @@ border="0">
|
|||||||
|
|
||||||
<h3><a name="synopsis"></a>Synopsis</h3>
|
<h3><a name="synopsis"></a>Synopsis</h3>
|
||||||
|
|
||||||
<p>#include <<a href="../../boost/regex.hpp">boost/regex.hpp</a>></p>
|
<p>#include <<a href="../../../boost/regex.hpp">boost/regex.hpp</a>></p>
|
||||||
|
|
||||||
<p>Regular expressions are different from many simple
|
<p>Regular expressions are different from many simple
|
||||||
pattern-matching algorithms in that as well as finding an overall
|
pattern-matching algorithms in that as well as finding an overall
|
||||||
@ -59,7 +59,7 @@ sub_match</a></i> .</p>
|
|||||||
|
|
||||||
<p>Template class match_results denotes a collection of character
|
<p>Template class match_results denotes a collection of character
|
||||||
sequences representing the result of a regular expression match.
|
sequences representing the result of a regular expression match.
|
||||||
Objects of type match_results are passed to the algorithms <a href="regex_match.html">regex_match</a> and <a href="regex_search">
|
Objects of type match_results are passed to the algorithms <a href="regex_match.html">regex_match</a> and <a href="regex_search.html">
|
||||||
regex_search</a>, and are returned by the iterator <a href="regex_iterator.html">regex_iterator</a> . Storage for the
|
regex_search</a>, and are returned by the iterator <a href="regex_iterator.html">regex_iterator</a> . Storage for the
|
||||||
collection is allocated and freed as necessary by the member
|
collection is allocated and freed as necessary by the member
|
||||||
functions of class match_results.</p>
|
functions of class match_results.</p>
|
||||||
|
@ -470,7 +470,7 @@ determine what gets matched, and how the format string should be
|
|||||||
treated. If <i>copy</i> is true then all unmatched sections of
|
treated. If <i>copy</i> is true then all unmatched sections of
|
||||||
input are copied unchanged to output, if the flag <em>
|
input are copied unchanged to output, if the flag <em>
|
||||||
format_first_only</em> is set then only the first occurance of the
|
format_first_only</em> is set then only the first occurance of the
|
||||||
pattern found is replaced. Returns the new string. See <a href="format_synatx.html">also format string syntax</a>, <a href="match_flag_type.html">match flags</a> and <a href="match_flag_type.html">format flags</a>.</td>
|
pattern found is replaced. Returns the new string. See <a href="format_syntax.html">also format string syntax</a>, <a href="match_flag_type.html">match flags</a> and <a href="match_flag_type.html">format flags</a>.</td>
|
||||||
<td valign="top" width="7%"> </td>
|
<td valign="top" width="7%"> </td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
@ -487,7 +487,7 @@ determine what gets matched, and how the format string should be
|
|||||||
treated. If <i>copy</i> is true then all unmatched sections of
|
treated. If <i>copy</i> is true then all unmatched sections of
|
||||||
input are copied unchanged to output, if the flag <em>
|
input are copied unchanged to output, if the flag <em>
|
||||||
format_first_only</em> is set then only the first occurance of the
|
format_first_only</em> is set then only the first occurance of the
|
||||||
pattern found is replaced. Returns the new string. See <a href="format_synatx.html">also format string syntax</a>, <a href="match_flag_type.html">match flags</a> and <a href="match_flag_type.html">format flags</a>.</td>
|
pattern found is replaced. Returns the new string. See <a href="format_syntax.html">also format string syntax</a>, <a href="match_flag_type.html">match flags</a> and <a href="match_flag_type.html">format flags</a>.</td>
|
||||||
<td valign="top" width="7%"> </td>
|
<td valign="top" width="7%"> </td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
|
@ -42,7 +42,7 @@ version of boost.regex and will not be further updated:</p>
|
|||||||
<h3>Algorithm regex_format</h3>
|
<h3>Algorithm regex_format</h3>
|
||||||
|
|
||||||
<pre>
|
<pre>
|
||||||
#include <<a href="../../boost/regex.hpp">boost/regex.hpp</a>>
|
#include <<a href="../../../boost/regex.hpp">boost/regex.hpp</a>>
|
||||||
</pre>
|
</pre>
|
||||||
|
|
||||||
<p>The algorithm regex_format takes the results of a match and
|
<p>The algorithm regex_format takes the results of a match and
|
||||||
|
@ -31,7 +31,7 @@
|
|||||||
and will not be updated in future.</p>
|
and will not be updated in future.</p>
|
||||||
<hr>
|
<hr>
|
||||||
<pre>
|
<pre>
|
||||||
#include <<a href="../../boost/regex.hpp">boost/regex.hpp</a>>
|
#include <<a href="../../../boost/regex.hpp">boost/regex.hpp</a>>
|
||||||
</pre>
|
</pre>
|
||||||
<p>regex_grep allows you to search through a bidirectional-iterator range and
|
<p>regex_grep allows you to search through a bidirectional-iterator range and
|
||||||
locate all the (non-overlapping) matches with a given regular expression. The
|
locate all the (non-overlapping) matches with a given regular expression. The
|
||||||
|
@ -30,7 +30,7 @@
|
|||||||
Examples</a></dt>
|
Examples</a></dt>
|
||||||
</dl>
|
</dl>
|
||||||
<H3><A name="synopsis"></A>Synopsis</H3>
|
<H3><A name="synopsis"></A>Synopsis</H3>
|
||||||
<PRE><A name=query_match></A>#include <<A href="../../boost/regex.hpp">boost/regex.hpp</A>> </PRE>
|
<PRE><A name=query_match></A>#include <<A href="../../../boost/regex.hpp">boost/regex.hpp</A>> </PRE>
|
||||||
<P>The algorithm regex _match determines whether a given regular expression
|
<P>The algorithm regex _match determines whether a given regular expression
|
||||||
matches a given sequence denoted by a pair of bidirectional-iterators, the
|
matches a given sequence denoted by a pair of bidirectional-iterators, the
|
||||||
algorithm is defined as follows, <STRONG>note that the result is true only if the
|
algorithm is defined as follows, <STRONG>note that the result is true only if the
|
||||||
|
@ -32,8 +32,8 @@
|
|||||||
all the matches to the regular expression: for each match it then calls <A href="match_results.html">
|
all the matches to the regular expression: for each match it then calls <A href="match_results.html">
|
||||||
match_results::format</A> to format the string and sends the result to the
|
match_results::format</A> to format the string and sends the result to the
|
||||||
output iterator. Sections of text that do not match are copied to the output
|
output iterator. Sections of text that do not match are copied to the output
|
||||||
unchanged only if the <EM>flags</EM> parameter does not have the flag <A href="match_flags.html">
|
unchanged only if the <EM>flags</EM> parameter does not have the flag <A href="match_flag_type.html">
|
||||||
format_no_copy</A> set. If the flag <A href="match_flags.html">format_first_only</A>
|
format_no_copy</A> set. If the flag <A href="match_flag_type.html">format_first_only</A>
|
||||||
is set then only the first occurrence is replaced rather than all
|
is set then only the first occurrence is replaced rather than all
|
||||||
occurrences. <PRE>template <class OutputIterator, class BidirectionalIterator, class traits,
|
occurrences. <PRE>template <class OutputIterator, class BidirectionalIterator, class traits,
|
||||||
class Allocator, class charT>
|
class Allocator, class charT>
|
||||||
|
@ -27,7 +27,7 @@
|
|||||||
<dt><A href="#synopsis">Synopsis</A> <dt><a href="#description">Description</a> <dt><A href="#examples">
|
<dt><A href="#synopsis">Synopsis</A> <dt><a href="#description">Description</a> <dt><A href="#examples">
|
||||||
Examples</A></dt></dl>
|
Examples</A></dt></dl>
|
||||||
<H3><A name="synopsis"></A>Synopsis</H3>
|
<H3><A name="synopsis"></A>Synopsis</H3>
|
||||||
<PRE>#include <<A href="../../boost/regex.hpp">boost/regex.hpp</A>> </PRE>
|
<PRE>#include <<A href="../../../boost/regex.hpp">boost/regex.hpp</A>> </PRE>
|
||||||
<P></P>
|
<P></P>
|
||||||
<P>The algorithm regex_search will search a range denoted by a pair of
|
<P>The algorithm regex_search will search a range denoted by a pair of
|
||||||
bidirectional-iterators for a given regular expression. The algorithm uses
|
bidirectional-iterators for a given regular expression. The algorithm uses
|
||||||
|
@ -24,14 +24,14 @@
|
|||||||
</P>
|
</P>
|
||||||
<HR>
|
<HR>
|
||||||
<H3>Synopsis</H3>
|
<H3>Synopsis</H3>
|
||||||
<P>#include <<A href="../../boost/regex.hpp">boost/regex.hpp</A>>
|
<P>#include <<A href="../../../boost/regex.hpp">boost/regex.hpp</A>>
|
||||||
</P>
|
</P>
|
||||||
<P>Regular expressions are different from many simple pattern-matching algorithms
|
<P>Regular expressions are different from many simple pattern-matching algorithms
|
||||||
in that as well as finding an overall match they can also produce
|
in that as well as finding an overall match they can also produce
|
||||||
sub-expression matches: each sub-expression being delimited in the pattern by a
|
sub-expression matches: each sub-expression being delimited in the pattern by a
|
||||||
pair of parenthesis (...). There has to be some method for reporting
|
pair of parenthesis (...). There has to be some method for reporting
|
||||||
sub-expression matches back to the user: this is achieved this by defining a
|
sub-expression matches back to the user: this is achieved this by defining a
|
||||||
class <I><A href="match_results.htm">match_results</A></I> that acts as an
|
class <I><A href="match_results.html">match_results</A></I> that acts as an
|
||||||
indexed collection of sub-expression matches, each sub-expression match being
|
indexed collection of sub-expression matches, each sub-expression match being
|
||||||
contained in an object of type <I>sub_match</I>
|
contained in an object of type <I>sub_match</I>
|
||||||
.
|
.
|
||||||
|
@ -90,10 +90,10 @@
|
|||||||
</H3>
|
</H3>
|
||||||
<P>Parentheses serve two purposes, to group items together into a sub-expression,
|
<P>Parentheses serve two purposes, to group items together into a sub-expression,
|
||||||
and to mark what generated the match. For example the expression "(ab)*" would
|
and to mark what generated the match. For example the expression "(ab)*" would
|
||||||
match all of the string "ababab". The matching algorithms <A href="template_class_ref.htm#query_match">
|
match all of the string "ababab". The matching algorithms <A href="regex_match.html">
|
||||||
regex_match</A> and <A href="template_class_ref.htm#reg_search">regex_search</A>
|
regex_match</A> and <A href="regex_search.html">regex_search</A>
|
||||||
each take an instance of <A href="template_class_ref.htm#reg_match">match_results</A>
|
each take an instance of <A href="match_results.html">match_results</A>
|
||||||
that reports what caused the match, on exit from these functions the <A href="template_class_ref.htm#reg_match">
|
that reports what caused the match, on exit from these functions the <A href="match_results.html">
|
||||||
match_results</A> contains information both on what the whole expression
|
match_results</A> contains information both on what the whole expression
|
||||||
matched and on what each sub-expression matched. In the example above
|
matched and on what each sub-expression matched. In the example above
|
||||||
match_results[1] would contain a pair of iterators denoting the final "ab" of
|
match_results[1] would contain a pair of iterators denoting the final "ab" of
|
||||||
|
@ -26,7 +26,7 @@
|
|||||||
<br>
|
<br>
|
||||||
<hr>
|
<hr>
|
||||||
<h3>Synopsis</h3>
|
<h3>Synopsis</h3>
|
||||||
<p>#include <<a href="../../boost/regex/pattern_except.hpp">boost/pattern_except.hpp</a>></p>
|
<p>#include <<a href="../../../boost/regex/pattern_except.hpp">boost/pattern_except.hpp</a>></p>
|
||||||
<p>The class <code>bad_expression</code> defines the type of objects thrown as
|
<p>The class <code>bad_expression</code> defines the type of objects thrown as
|
||||||
exceptions to report errors during the conversion from a string representing a
|
exceptions to report errors during the conversion from a string representing a
|
||||||
regular expression to a finite state machine. </p>
|
regular expression to a finite state machine. </p>
|
||||||
|
@ -35,7 +35,7 @@ border="0">
|
|||||||
<h3>Synopsis</h3>
|
<h3>Synopsis</h3>
|
||||||
|
|
||||||
<pre>
|
<pre>
|
||||||
#include <<a href="../../boost/regex.hpp">boost/regex.hpp</a>>
|
#include <<a href="../../../boost/regex.hpp">boost/regex.hpp</a>>
|
||||||
</pre>
|
</pre>
|
||||||
|
|
||||||
<p>The template class <em>basic_regex</em> encapsulates regular
|
<p>The template class <em>basic_regex</em> encapsulates regular
|
||||||
|
@ -38,7 +38,7 @@ border="0">
|
|||||||
john_maddock@compuserve.com</a>, the home page for this library is
|
john_maddock@compuserve.com</a>, the home page for this library is
|
||||||
at <a href="http://ourworld.compuserve.com/homepages/john_maddock/regexpp.htm">
|
at <a href="http://ourworld.compuserve.com/homepages/john_maddock/regexpp.htm">
|
||||||
http://ourworld.compuserve.com/homepages/john_maddock/regexpp.htm</a>,
|
http://ourworld.compuserve.com/homepages/john_maddock/regexpp.htm</a>,
|
||||||
and the official boost version can be obtained from <a href="../libraries.htm">www.boost.org/libraries.htm</a>.</p>
|
and the official boost version can be obtained from <a href="../../libraries.htm">www.boost.org/libraries.htm</a>.</p>
|
||||||
|
|
||||||
<p>I am indebted to Robert Sedgewick's "Algorithms in C++" for
|
<p>I am indebted to Robert Sedgewick's "Algorithms in C++" for
|
||||||
forcing me to think about algorithms and their performance, and to
|
forcing me to think about algorithms and their performance, and to
|
||||||
|
@ -34,7 +34,7 @@ border="0">
|
|||||||
|
|
||||||
|
|
||||||
<hr>
|
<hr>
|
||||||
<p>Format strings are used by the algorithm <a href="template_class_ref.htm#reg_merge">regex_merge</a> and by <a
|
<p>Format strings are used by the algorithm <a href="regex_replace.html">regex_replace</a> and by <a
|
||||||
href="match_results.html">match_results::format</a>, and are used
|
href="match_results.html">match_results::format</a>, and are used
|
||||||
to transform one string into another.</p>
|
to transform one string into another.</p>
|
||||||
|
|
||||||
|
@ -23,12 +23,6 @@
|
|||||||
</TABLE>
|
</TABLE>
|
||||||
</P>
|
</P>
|
||||||
<HR>
|
<HR>
|
||||||
<p></p>
|
|
||||||
<P><EM>[ </EM><STRONG><I>Important</I></STRONG><EM>: If you are upgrading from the
|
|
||||||
2.x version of this library then you will find a number of changes to the
|
|
||||||
documented header names and library interfaces, existing code should still
|
|
||||||
compile unchanged however - see </EM><A href="appendix.htm#upgrade"><FONT color="#0000ff">
|
|
||||||
<EM>Note for Upgraders</EM></FONT></A><EM>. ]</EM></P>
|
|
||||||
<P>When you extract the library from its zip file, you must preserve its internal
|
<P>When you extract the library from its zip file, you must preserve its internal
|
||||||
directory structure (for example by using the -d option when extracting). If
|
directory structure (for example by using the -d option when extracting). If
|
||||||
you didn't do that when extracting, then you'd better stop reading this, delete
|
you didn't do that when extracting, then you'd better stop reading this, delete
|
||||||
@ -37,7 +31,7 @@
|
|||||||
<P>This library should not need configuring before use; most popular
|
<P>This library should not need configuring before use; most popular
|
||||||
compilers/standard libraries/platforms are already supported "as is". If you do
|
compilers/standard libraries/platforms are already supported "as is". If you do
|
||||||
experience configuration problems, or just want to test the configuration with
|
experience configuration problems, or just want to test the configuration with
|
||||||
your compiler, then the process is the same as for all of boost; see the <A href="../config/config.htm">
|
your compiler, then the process is the same as for all of boost; see the <A href="../../config/config.htm">
|
||||||
configuration library documentation</A>.</P>
|
configuration library documentation</A>.</P>
|
||||||
<P>The library will encase all code inside namespace boost.
|
<P>The library will encase all code inside namespace boost.
|
||||||
</P>
|
</P>
|
||||||
@ -187,7 +181,7 @@
|
|||||||
<P>LDFLAGS: additional linker options.</P>
|
<P>LDFLAGS: additional linker options.</P>
|
||||||
<P>LIBS: additional library files.</P>
|
<P>LIBS: additional library files.</P>
|
||||||
<P>For the more adventurous there is a configure script in
|
<P>For the more adventurous there is a configure script in
|
||||||
<boost>/libs/config; see the <A href="../config/config.htm">config library
|
<boost>/libs/config; see the <A href="../../config/config.htm">config library
|
||||||
documentation</A>.</P>
|
documentation</A>.</P>
|
||||||
<P><B><A name="sun"></A>Sun Workshop 6.1</B></P>
|
<P><B><A name="sun"></A>Sun Workshop 6.1</B></P>
|
||||||
<P>There is a makefile for the sun (6.1) compiler (C++ version 3.12). From the
|
<P>There is a makefile for the sun (6.1) compiler (C++ version 3.12). From the
|
||||||
@ -214,14 +208,14 @@
|
|||||||
<P>will build v9 variants of the regex library named libboost_regex_v9.a etc.</P>
|
<P>will build v9 variants of the regex library named libboost_regex_v9.a etc.</P>
|
||||||
<P><B><A name="other"></A>Other compilers:</B>
|
<P><B><A name="other"></A>Other compilers:</B>
|
||||||
</P>
|
</P>
|
||||||
<P>There is a generic makefile (<A href="build/generic.mak">generic.mak</A>
|
<P>There is a generic makefile (<A href="../build/generic.mak">generic.mak</A>
|
||||||
) provided in <boost-root>/libs/regex/build - see that makefile for
|
) provided in <boost-root>/libs/regex/build - see that makefile for
|
||||||
details of environment variables that need to be set before use.
|
details of environment variables that need to be set before use.
|
||||||
<P>
|
<P>
|
||||||
Alternatively you can using the <A href="../../tools/build/index.html">Jam based
|
Alternatively you can using the <A href="../../../tools/build/index.html">Jam based
|
||||||
build system</A>: cd into <boost>/libs/regex/build and run:<PRE>bjam -sTOOLS=mytoolset</PRE>
|
build system</A>: cd into <boost>/libs/regex/build and run:<PRE>bjam -sTOOLS=mytoolset</PRE>
|
||||||
<P>
|
<P>
|
||||||
If you need to configure the library for your platform, then refer to the <A href="../config/config.htm">
|
If you need to configure the library for your platform, then refer to the <A href="../../config/config.htm">
|
||||||
config library documentation</A>
|
config library documentation</A>
|
||||||
.
|
.
|
||||||
<P>
|
<P>
|
||||||
|
@ -44,7 +44,7 @@ border="0">
|
|||||||
|
|
||||||
<h3><a name="synopsis"></a>Synopsis</h3>
|
<h3><a name="synopsis"></a>Synopsis</h3>
|
||||||
|
|
||||||
<p>#include <<a href="../../boost/regex.hpp">boost/regex.hpp</a>></p>
|
<p>#include <<a href="../../../boost/regex.hpp">boost/regex.hpp</a>></p>
|
||||||
|
|
||||||
<p>Regular expressions are different from many simple
|
<p>Regular expressions are different from many simple
|
||||||
pattern-matching algorithms in that as well as finding an overall
|
pattern-matching algorithms in that as well as finding an overall
|
||||||
@ -59,7 +59,7 @@ sub_match</a></i> .</p>
|
|||||||
|
|
||||||
<p>Template class match_results denotes a collection of character
|
<p>Template class match_results denotes a collection of character
|
||||||
sequences representing the result of a regular expression match.
|
sequences representing the result of a regular expression match.
|
||||||
Objects of type match_results are passed to the algorithms <a href="regex_match.html">regex_match</a> and <a href="regex_search">
|
Objects of type match_results are passed to the algorithms <a href="regex_match.html">regex_match</a> and <a href="regex_search.html">
|
||||||
regex_search</a>, and are returned by the iterator <a href="regex_iterator.html">regex_iterator</a> . Storage for the
|
regex_search</a>, and are returned by the iterator <a href="regex_iterator.html">regex_iterator</a> . Storage for the
|
||||||
collection is allocated and freed as necessary by the member
|
collection is allocated and freed as necessary by the member
|
||||||
functions of class match_results.</p>
|
functions of class match_results.</p>
|
||||||
|
@ -470,7 +470,7 @@ determine what gets matched, and how the format string should be
|
|||||||
treated. If <i>copy</i> is true then all unmatched sections of
|
treated. If <i>copy</i> is true then all unmatched sections of
|
||||||
input are copied unchanged to output, if the flag <em>
|
input are copied unchanged to output, if the flag <em>
|
||||||
format_first_only</em> is set then only the first occurance of the
|
format_first_only</em> is set then only the first occurance of the
|
||||||
pattern found is replaced. Returns the new string. See <a href="format_synatx.html">also format string syntax</a>, <a href="match_flag_type.html">match flags</a> and <a href="match_flag_type.html">format flags</a>.</td>
|
pattern found is replaced. Returns the new string. See <a href="format_syntax.html">also format string syntax</a>, <a href="match_flag_type.html">match flags</a> and <a href="match_flag_type.html">format flags</a>.</td>
|
||||||
<td valign="top" width="7%"> </td>
|
<td valign="top" width="7%"> </td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
@ -487,7 +487,7 @@ determine what gets matched, and how the format string should be
|
|||||||
treated. If <i>copy</i> is true then all unmatched sections of
|
treated. If <i>copy</i> is true then all unmatched sections of
|
||||||
input are copied unchanged to output, if the flag <em>
|
input are copied unchanged to output, if the flag <em>
|
||||||
format_first_only</em> is set then only the first occurance of the
|
format_first_only</em> is set then only the first occurance of the
|
||||||
pattern found is replaced. Returns the new string. See <a href="format_synatx.html">also format string syntax</a>, <a href="match_flag_type.html">match flags</a> and <a href="match_flag_type.html">format flags</a>.</td>
|
pattern found is replaced. Returns the new string. See <a href="format_syntax.html">also format string syntax</a>, <a href="match_flag_type.html">match flags</a> and <a href="match_flag_type.html">format flags</a>.</td>
|
||||||
<td valign="top" width="7%"> </td>
|
<td valign="top" width="7%"> </td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
|
@ -42,7 +42,7 @@ version of boost.regex and will not be further updated:</p>
|
|||||||
<h3>Algorithm regex_format</h3>
|
<h3>Algorithm regex_format</h3>
|
||||||
|
|
||||||
<pre>
|
<pre>
|
||||||
#include <<a href="../../boost/regex.hpp">boost/regex.hpp</a>>
|
#include <<a href="../../../boost/regex.hpp">boost/regex.hpp</a>>
|
||||||
</pre>
|
</pre>
|
||||||
|
|
||||||
<p>The algorithm regex_format takes the results of a match and
|
<p>The algorithm regex_format takes the results of a match and
|
||||||
|
@ -31,7 +31,7 @@
|
|||||||
and will not be updated in future.</p>
|
and will not be updated in future.</p>
|
||||||
<hr>
|
<hr>
|
||||||
<pre>
|
<pre>
|
||||||
#include <<a href="../../boost/regex.hpp">boost/regex.hpp</a>>
|
#include <<a href="../../../boost/regex.hpp">boost/regex.hpp</a>>
|
||||||
</pre>
|
</pre>
|
||||||
<p>regex_grep allows you to search through a bidirectional-iterator range and
|
<p>regex_grep allows you to search through a bidirectional-iterator range and
|
||||||
locate all the (non-overlapping) matches with a given regular expression. The
|
locate all the (non-overlapping) matches with a given regular expression. The
|
||||||
|
@ -30,7 +30,7 @@
|
|||||||
Examples</a></dt>
|
Examples</a></dt>
|
||||||
</dl>
|
</dl>
|
||||||
<H3><A name="synopsis"></A>Synopsis</H3>
|
<H3><A name="synopsis"></A>Synopsis</H3>
|
||||||
<PRE><A name=query_match></A>#include <<A href="../../boost/regex.hpp">boost/regex.hpp</A>> </PRE>
|
<PRE><A name=query_match></A>#include <<A href="../../../boost/regex.hpp">boost/regex.hpp</A>> </PRE>
|
||||||
<P>The algorithm regex _match determines whether a given regular expression
|
<P>The algorithm regex _match determines whether a given regular expression
|
||||||
matches a given sequence denoted by a pair of bidirectional-iterators, the
|
matches a given sequence denoted by a pair of bidirectional-iterators, the
|
||||||
algorithm is defined as follows, <STRONG>note that the result is true only if the
|
algorithm is defined as follows, <STRONG>note that the result is true only if the
|
||||||
|
@ -32,8 +32,8 @@
|
|||||||
all the matches to the regular expression: for each match it then calls <A href="match_results.html">
|
all the matches to the regular expression: for each match it then calls <A href="match_results.html">
|
||||||
match_results::format</A> to format the string and sends the result to the
|
match_results::format</A> to format the string and sends the result to the
|
||||||
output iterator. Sections of text that do not match are copied to the output
|
output iterator. Sections of text that do not match are copied to the output
|
||||||
unchanged only if the <EM>flags</EM> parameter does not have the flag <A href="match_flags.html">
|
unchanged only if the <EM>flags</EM> parameter does not have the flag <A href="match_flag_type.html">
|
||||||
format_no_copy</A> set. If the flag <A href="match_flags.html">format_first_only</A>
|
format_no_copy</A> set. If the flag <A href="match_flag_type.html">format_first_only</A>
|
||||||
is set then only the first occurrence is replaced rather than all
|
is set then only the first occurrence is replaced rather than all
|
||||||
occurrences. <PRE>template <class OutputIterator, class BidirectionalIterator, class traits,
|
occurrences. <PRE>template <class OutputIterator, class BidirectionalIterator, class traits,
|
||||||
class Allocator, class charT>
|
class Allocator, class charT>
|
||||||
|
@ -27,7 +27,7 @@
|
|||||||
<dt><A href="#synopsis">Synopsis</A> <dt><a href="#description">Description</a> <dt><A href="#examples">
|
<dt><A href="#synopsis">Synopsis</A> <dt><a href="#description">Description</a> <dt><A href="#examples">
|
||||||
Examples</A></dt></dl>
|
Examples</A></dt></dl>
|
||||||
<H3><A name="synopsis"></A>Synopsis</H3>
|
<H3><A name="synopsis"></A>Synopsis</H3>
|
||||||
<PRE>#include <<A href="../../boost/regex.hpp">boost/regex.hpp</A>> </PRE>
|
<PRE>#include <<A href="../../../boost/regex.hpp">boost/regex.hpp</A>> </PRE>
|
||||||
<P></P>
|
<P></P>
|
||||||
<P>The algorithm regex_search will search a range denoted by a pair of
|
<P>The algorithm regex_search will search a range denoted by a pair of
|
||||||
bidirectional-iterators for a given regular expression. The algorithm uses
|
bidirectional-iterators for a given regular expression. The algorithm uses
|
||||||
|
@ -24,14 +24,14 @@
|
|||||||
</P>
|
</P>
|
||||||
<HR>
|
<HR>
|
||||||
<H3>Synopsis</H3>
|
<H3>Synopsis</H3>
|
||||||
<P>#include <<A href="../../boost/regex.hpp">boost/regex.hpp</A>>
|
<P>#include <<A href="../../../boost/regex.hpp">boost/regex.hpp</A>>
|
||||||
</P>
|
</P>
|
||||||
<P>Regular expressions are different from many simple pattern-matching algorithms
|
<P>Regular expressions are different from many simple pattern-matching algorithms
|
||||||
in that as well as finding an overall match they can also produce
|
in that as well as finding an overall match they can also produce
|
||||||
sub-expression matches: each sub-expression being delimited in the pattern by a
|
sub-expression matches: each sub-expression being delimited in the pattern by a
|
||||||
pair of parenthesis (...). There has to be some method for reporting
|
pair of parenthesis (...). There has to be some method for reporting
|
||||||
sub-expression matches back to the user: this is achieved this by defining a
|
sub-expression matches back to the user: this is achieved this by defining a
|
||||||
class <I><A href="match_results.htm">match_results</A></I> that acts as an
|
class <I><A href="match_results.html">match_results</A></I> that acts as an
|
||||||
indexed collection of sub-expression matches, each sub-expression match being
|
indexed collection of sub-expression matches, each sub-expression match being
|
||||||
contained in an object of type <I>sub_match</I>
|
contained in an object of type <I>sub_match</I>
|
||||||
.
|
.
|
||||||
|
@ -90,10 +90,10 @@
|
|||||||
</H3>
|
</H3>
|
||||||
<P>Parentheses serve two purposes, to group items together into a sub-expression,
|
<P>Parentheses serve two purposes, to group items together into a sub-expression,
|
||||||
and to mark what generated the match. For example the expression "(ab)*" would
|
and to mark what generated the match. For example the expression "(ab)*" would
|
||||||
match all of the string "ababab". The matching algorithms <A href="template_class_ref.htm#query_match">
|
match all of the string "ababab". The matching algorithms <A href="regex_match.html">
|
||||||
regex_match</A> and <A href="template_class_ref.htm#reg_search">regex_search</A>
|
regex_match</A> and <A href="regex_search.html">regex_search</A>
|
||||||
each take an instance of <A href="template_class_ref.htm#reg_match">match_results</A>
|
each take an instance of <A href="match_results.html">match_results</A>
|
||||||
that reports what caused the match, on exit from these functions the <A href="template_class_ref.htm#reg_match">
|
that reports what caused the match, on exit from these functions the <A href="match_results.html">
|
||||||
match_results</A> contains information both on what the whole expression
|
match_results</A> contains information both on what the whole expression
|
||||||
matched and on what each sub-expression matched. In the example above
|
matched and on what each sub-expression matched. In the example above
|
||||||
match_results[1] would contain a pair of iterators denoting the final "ab" of
|
match_results[1] would contain a pair of iterators denoting the final "ab" of
|
||||||
|
@ -1,3 +1,5 @@
|
|||||||
|
# copyright John Maddock 2003
|
||||||
|
|
||||||
subproject libs/regex/example ;
|
subproject libs/regex/example ;
|
||||||
|
|
||||||
# bring in the rules for testing
|
# bring in the rules for testing
|
||||||
@ -42,6 +44,9 @@ test-suite regex-examples :
|
|||||||
[ regex-test-run snippets/regex_search_example.cpp : $(BOOST_ROOT)/boost/rational.hpp ]
|
[ regex-test-run snippets/regex_search_example.cpp : $(BOOST_ROOT)/boost/rational.hpp ]
|
||||||
[ regex-test-run snippets/regex_split_example_1.cpp : -auto ]
|
[ regex-test-run snippets/regex_split_example_1.cpp : -auto ]
|
||||||
[ regex-test-run snippets/regex_split_example_2.cpp : $(BOOST_ROOT)/libs/regex/doc/index.html ]
|
[ regex-test-run snippets/regex_split_example_2.cpp : $(BOOST_ROOT)/libs/regex/doc/index.html ]
|
||||||
|
[ regex-test-run snippets/regex_token_iterator_eg_1.cpp : -auto ]
|
||||||
|
[ regex-test-run snippets/regex_token_iterator_eg_2.cpp : $(BOOST_ROOT)/libs/regex/doc/index.html ]
|
||||||
|
[ regex-test-run snippets/regex_iterator_example.cpp : $(BOOST_ROOT)/boost/rational.hpp ]
|
||||||
|
|
||||||
;
|
;
|
||||||
|
|
||||||
|
@ -147,9 +147,10 @@ int main(int argc, const char** argv)
|
|||||||
int main()
|
int main()
|
||||||
{
|
{
|
||||||
return 0;
|
return 0;
|
||||||
};
|
}
|
||||||
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
# copyright John Maddock 2003
|
||||||
|
|
||||||
subproject libs/regex/performance ;
|
subproject libs/regex/performance ;
|
||||||
|
|
||||||
|
@ -1,3 +1,17 @@
|
|||||||
|
/*
|
||||||
|
*
|
||||||
|
* Copyright (c) 2002-2003
|
||||||
|
* Dr John Maddock
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, distribute and sell this software
|
||||||
|
* and its documentation for any purpose is hereby granted without fee,
|
||||||
|
* provided that the above copyright notice appear in all copies and
|
||||||
|
* that both that copyright notice and this permission notice appear
|
||||||
|
* in supporting documentation. Dr John Maddock makes no representations
|
||||||
|
* about the suitability of this software for any purpose.
|
||||||
|
* It is provided "as is" without express or implied warranty.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <iomanip>
|
#include <iomanip>
|
||||||
|
@ -1,3 +1,5 @@
|
|||||||
|
# copyright John Maddock 2003
|
||||||
|
|
||||||
subproject libs/regex/test ;
|
subproject libs/regex/test ;
|
||||||
|
|
||||||
# bring in the rules for testing
|
# bring in the rules for testing
|
||||||
|
Reference in New Issue
Block a user