Annotation of embedaddon/pcre/doc/pcre_dfa_exec.3, revision 1.1.1.3
1.1.1.3 ! misho 1: .TH PCRE_DFA_EXEC 3 "13 January 2012" "PCRE 8.30"
1.1 misho 2: .SH NAME
3: PCRE - Perl-compatible regular expressions
4: .SH SYNOPSIS
5: .rs
6: .sp
7: .B #include <pcre.h>
8: .PP
9: .SM
10: .B int pcre_dfa_exec(const pcre *\fIcode\fP, "const pcre_extra *\fIextra\fP,"
11: .ti +5n
12: .B "const char *\fIsubject\fP," int \fIlength\fP, int \fIstartoffset\fP,
13: .ti +5n
14: .B int \fIoptions\fP, int *\fIovector\fP, int \fIovecsize\fP,
15: .ti +5n
16: .B int *\fIworkspace\fP, int \fIwscount\fP);
1.1.1.2 misho 17: .PP
18: .B int pcre16_dfa_exec(const pcre16 *\fIcode\fP, "const pcre16_extra *\fIextra\fP,"
19: .ti +5n
20: .B "PCRE_SPTR16 \fIsubject\fP," int \fIlength\fP, int \fIstartoffset\fP,
21: .ti +5n
22: .B int \fIoptions\fP, int *\fIovector\fP, int \fIovecsize\fP,
23: .ti +5n
24: .B int *\fIworkspace\fP, int \fIwscount\fP);
1.1 misho 25: .
26: .SH DESCRIPTION
27: .rs
28: .sp
29: This function matches a compiled regular expression against a given subject
30: string, using an alternative matching algorithm that scans the subject string
31: just once (\fInot\fP Perl-compatible). Note that the main, Perl-compatible,
1.1.1.2 misho 32: matching function is \fBpcre[16]_exec()\fP. The arguments for this function
33: are:
1.1 misho 34: .sp
35: \fIcode\fP Points to the compiled pattern
1.1.1.2 misho 36: \fIextra\fP Points to an associated \fBpcre[16]_extra\fP structure,
1.1 misho 37: or is NULL
38: \fIsubject\fP Points to the subject string
39: \fIlength\fP Length of the subject string, in bytes
40: \fIstartoffset\fP Offset in bytes in the subject at which to
41: start matching
42: \fIoptions\fP Option bits
43: \fIovector\fP Points to a vector of ints for result offsets
44: \fIovecsize\fP Number of elements in the vector
45: \fIworkspace\fP Points to a vector of ints used as working space
46: \fIwscount\fP Number of elements in the vector
47: .sp
48: The options are:
49: .sp
50: PCRE_ANCHORED Match only at the first position
51: PCRE_BSR_ANYCRLF \eR matches only CR, LF, or CRLF
52: PCRE_BSR_UNICODE \eR matches all Unicode line endings
53: PCRE_NEWLINE_ANY Recognize any Unicode newline sequence
54: PCRE_NEWLINE_ANYCRLF Recognize CR, LF, & CRLF as newline sequences
55: PCRE_NEWLINE_CR Recognize CR as the only newline sequence
56: PCRE_NEWLINE_CRLF Recognize CRLF as the only newline sequence
57: PCRE_NEWLINE_LF Recognize LF as the only newline sequence
58: PCRE_NOTBOL Subject is not the beginning of a line
59: PCRE_NOTEOL Subject is not the end of a line
60: PCRE_NOTEMPTY An empty string is not a valid match
61: PCRE_NOTEMPTY_ATSTART An empty string at the start of the subject
62: is not a valid match
63: PCRE_NO_START_OPTIMIZE Do not do "start-match" optimizations
1.1.1.2 misho 64: PCRE_NO_UTF16_CHECK Do not check the subject for UTF-16
65: validity (only relevant if PCRE_UTF16
66: was set at compile time)
1.1 misho 67: PCRE_NO_UTF8_CHECK Do not check the subject for UTF-8
68: validity (only relevant if PCRE_UTF8
69: was set at compile time)
70: PCRE_PARTIAL ) Return PCRE_ERROR_PARTIAL for a partial
71: PCRE_PARTIAL_SOFT ) match if no full matches are found
72: PCRE_PARTIAL_HARD Return PCRE_ERROR_PARTIAL for a partial match
73: even if there is a full match as well
74: PCRE_DFA_SHORTEST Return only the shortest match
75: PCRE_DFA_RESTART Restart after a partial match
76: .sp
77: There are restrictions on what may appear in a pattern when using this matching
78: function. Details are given in the
79: .\" HREF
80: \fBpcrematching\fP
81: .\"
82: documentation. For details of partial matching, see the
83: .\" HREF
84: \fBpcrepartial\fP
85: .\"
86: page.
87: .P
1.1.1.2 misho 88: A \fBpcre[16]_extra\fP structure contains the following fields:
1.1 misho 89: .sp
90: \fIflags\fP Bits indicating which fields are set
1.1.1.2 misho 91: \fIstudy_data\fP Opaque data from \fBpcre[16]_study()\fP
1.1 misho 92: \fImatch_limit\fP Limit on internal resource use
93: \fImatch_limit_recursion\fP Limit on internal recursion depth
94: \fIcallout_data\fP Opaque data passed back to callouts
95: \fItables\fP Points to character tables or is NULL
96: \fImark\fP For passing back a *MARK pointer
97: \fIexecutable_jit\fP Opaque data from JIT compilation
98: .sp
99: The flag bits are PCRE_EXTRA_STUDY_DATA, PCRE_EXTRA_MATCH_LIMIT,
100: PCRE_EXTRA_MATCH_LIMIT_RECURSION, PCRE_EXTRA_CALLOUT_DATA,
101: PCRE_EXTRA_TABLES, PCRE_EXTRA_MARK and PCRE_EXTRA_EXECUTABLE_JIT. For this
102: matching function, the \fImatch_limit\fP and \fImatch_limit_recursion\fP fields
103: are not used, and must not be set. The PCRE_EXTRA_EXECUTABLE_JIT flag and
104: the corresponding variable are ignored.
105: .P
106: There is a complete description of the PCRE native API in the
107: .\" HREF
108: \fBpcreapi\fP
109: .\"
110: page and a description of the POSIX API in the
111: .\" HREF
112: \fBpcreposix\fP
113: .\"
114: page.
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>