1 |
<html>
|
2 |
<head>
|
3 |
<title>pcre_exec specification</title>
|
4 |
</head>
|
5 |
<body bgcolor="#FFFFFF" text="#00005A" link="#0066FF" alink="#3399FF" vlink="#2222BB">
|
6 |
This HTML document has been generated automatically from the original man page.
|
7 |
If there is any nonsense in it, please consult the man page, in case the
|
8 |
conversion went wrong.<br>
|
9 |
<br><b>
|
10 |
SYNOPSIS
|
11 |
</b><br>
|
12 |
<P>
|
13 |
<b>#include <pcre.h></b>
|
14 |
</P>
|
15 |
<P>
|
16 |
<b>int pcre_exec(const pcre *<i>code</i>, const pcre_extra *<i>extra</i>,</b>
|
17 |
<b>const char *<i>subject</i>, int <i>length</i>, int <i>startoffset</i>,</b>
|
18 |
<b>int <i>options</i>, int *<i>ovector</i>, int <i>ovecsize</i>);</b>
|
19 |
</P>
|
20 |
<br><b>
|
21 |
DESCRIPTION
|
22 |
</b><br>
|
23 |
<P>
|
24 |
This function matches a compiled regular expression against a given subject
|
25 |
string, and returns offsets to capturing subexpressions. Its arguments are:
|
26 |
</P>
|
27 |
<P>
|
28 |
<pre>
|
29 |
<i>code</i> Points to the compiled pattern
|
30 |
<i>extra</i> Points to an associated <b>pcre_extra</b> structure,
|
31 |
or is NULL
|
32 |
<i>subject</i> Points to the subject string
|
33 |
<i>length</i> Length of the subject string, in bytes
|
34 |
<i>startoffset</i> Offset in bytes in the subject at which to
|
35 |
start matching
|
36 |
<i>options</i> Option bits
|
37 |
<i>ovector</i> Points to a vector of ints for result offsets
|
38 |
<i>ovecsize</i> Size of the vector (a multiple of 3)
|
39 |
</PRE>
|
40 |
</P>
|
41 |
<P>
|
42 |
The options are:
|
43 |
</P>
|
44 |
<P>
|
45 |
<pre>
|
46 |
PCRE_ANCHORED Match only at the first position
|
47 |
PCRE_NOTBOL Subject is not the beginning of a line
|
48 |
PCRE_NOTEOL Subject is not the end of a line
|
49 |
PCRE_NOTEMPTY An empty string is not a valid match
|
50 |
</PRE>
|
51 |
</P>
|
52 |
<P>
|
53 |
There is a complete description of the PCRE API in the
|
54 |
<a href="pcreapi.html"><b>pcreapi</b></a>
|
55 |
page.
|