Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
libvmod-re2
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
uplex-varnish
libvmod-re2
Commits
7f0cf6fe
Commit
7f0cf6fe
authored
Feb 02, 2019
by
Nils Goroll
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
documentation auto-update from vmodtool change
parent
3e08d60e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
58 additions
and
101 deletions
+58
-101
README.rst
README.rst
+58
-101
No files found.
README.rst
View file @
7f0cf6fe
...
...
@@ -6,8 +6,6 @@
.. role:: ref(emphasis)
.. _vmod_re2(3):
========
vmod_re2
========
...
...
@@ -20,12 +18,6 @@ Varnish Module for access to the Google RE2 regular expression engine
SYNOPSIS
========
...
...
@@ -319,11 +311,10 @@ turned off.
just after a newline, and ``$`` also matches just before a newline. Default is
**false**.
.. _vmod_re2.regex:
.. _obj_regex:
regex(...)
----------
new xregex = re2.regex(STRING pattern, BOOL utf8, BOOL posix_syntax, BOOL longest_match, INT max_mem, BOOL literal, BOOL never_nl, BOOL dot_nl, BOOL never_capture, BOOL case_sensitive, BOOL perl_classes, BOOL word_boundary, BOOL one_line)
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
::
...
...
@@ -358,7 +349,7 @@ Example::
never_capture=true);
}
.. _
func_
regex.match:
.. _
vmod_re2.
regex.match:
BOOL xregex.match(STRING)
-------------------------
...
...
@@ -372,8 +363,7 @@ Example::
call do_on_match;
}
.. _func_regex.backref:
.. _vmod_re2.regex.backref:
STRING xregex.backref(INT ref, STRING fallback)
-----------------------------------------------
...
...
@@ -440,8 +430,7 @@ Example::
set req.http.X-Domain = domainmatcher.backref(1);
}
.. _func_regex.namedref:
.. _vmod_re2.regex.namedref:
STRING xregex.namedref(STRING name, STRING fallback)
----------------------------------------------------
...
...
@@ -498,11 +487,10 @@ Example::
}
}
.. _vmod_re2.regex.sub:
.. _func_regex.sub:
regex.sub(...)
--------------
STRING xregex.sub(STRING text, STRING rewrite, STRING fallback)
---------------------------------------------------------------
::
...
...
@@ -540,11 +528,10 @@ Example::
set req.http.X-Yada = bmatcher.sub(req.http.Host, "d");
}
.. _vmod_re2.regex.suball:
.. _func_regex.suball:
regex.suball(...)
-----------------
STRING xregex.suball(STRING text, STRING rewrite, STRING fallback)
------------------------------------------------------------------
::
...
...
@@ -577,11 +564,10 @@ Example::
set req.http.X-Yada = bmatcher.suball(req.http.Host, "d");
}
.. _vmod_re2.regex.extract:
.. _func_regex.extract:
regex.extract(...)
------------------
STRING xregex.extract(STRING text, STRING rewrite, STRING fallback)
-------------------------------------------------------------------
::
...
...
@@ -612,8 +598,7 @@ Example::
set resp.http.X-UUCP = email.extract("boris@kremvax.ru", "\2!\1");
}
.. _func_regex.cost:
.. _vmod_re2.regex.cost:
INT xregex.cost()
-----------------
...
...
@@ -636,14 +621,10 @@ Example::
regex functional interface
==========================
.. _vmod_re2.match:
.. _func_match:
match(...)
----------
BOOL match(STRING pattern, STRING subject, BOOL utf8, BOOL posix_syntax, BOOL longest_match, INT max_mem, BOOL literal, BOOL never_nl, BOOL dot_nl, BOOL never_capture, BOOL case_sensitive, BOOL perl_classes, BOOL word_boundary, BOOL one_line)
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
::
...
...
@@ -678,8 +659,7 @@ Example::
call do_on_match;
}
.. _func_backref:
.. _vmod_re2.backref:
STRING backref(INT ref, STRING fallback)
----------------------------------------
...
...
@@ -721,8 +701,7 @@ Example::
set beresp.http.X-Capture = re2.backref(1);
}
.. _func_namedref:
.. _vmod_re2.namedref:
STRING namedref(STRING name, STRING fallback)
---------------------------------------------
...
...
@@ -759,11 +738,10 @@ Example::
set beresp.http.X-Capture = re2.namedref("foo");
}
.. _vmod_re2.sub:
.. _func_sub:
sub(...)
--------
STRING sub(STRING pattern, STRING text, STRING rewrite, STRING fallback, BOOL utf8, BOOL posix_syntax, BOOL longest_match, INT max_mem, BOOL literal, BOOL never_nl, BOOL dot_nl, BOOL never_capture, BOOL case_sensitive, BOOL perl_classes, BOOL word_boundary, BOOL one_line)
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
::
...
...
@@ -810,11 +788,10 @@ Example::
set beresp.http.X-Yada = re2.sub(beresp.http.X-Sub-Letters,
bereq.http.Host, "d");
.. _vmod_re2.suball:
.. _func_suball:
suball(...)
-----------
STRING suball(STRING pattern, STRING text, STRING rewrite, STRING fallback, BOOL utf8, BOOL posix_syntax, BOOL longest_match, INT max_mem, BOOL literal, BOOL never_nl, BOOL dot_nl, BOOL never_capture, BOOL case_sensitive, BOOL perl_classes, BOOL word_boundary, BOOL one_line)
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
::
...
...
@@ -851,11 +828,10 @@ Example::
set beresp.http.X-Yada = re2.suball(beresp.http.X-Sub-Letters,
bereq.http.Host, "d");
.. _vmod_re2.extract:
.. _func_extract:
extract(...)
------------
STRING extract(STRING pattern, STRING text, STRING rewrite, STRING fallback, BOOL utf8, BOOL posix_syntax, BOOL longest_match, INT max_mem, BOOL literal, BOOL never_nl, BOOL dot_nl, BOOL never_capture, BOOL case_sensitive, BOOL perl_classes, BOOL word_boundary, BOOL one_line)
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
::
...
...
@@ -893,11 +869,10 @@ Example::
set beresp.http.X-Query = re2.extract(beresp.http.X-Params, bereq.url,
"\1:\2");
.. _vmod_re2.cost:
.. _func_cost:
cost(...)
---------
INT cost(STRING pattern, BOOL utf8, BOOL posix_syntax, BOOL longest_match, INT max_mem, BOOL literal, BOOL never_nl, BOOL dot_nl, BOOL never_capture, BOOL case_sensitive, BOOL perl_classes, BOOL word_boundary, BOOL one_line)
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
::
...
...
@@ -928,11 +903,10 @@ Example::
std.log("simple cost=" + re2.cost("simple")
+ " complex cost=" + re2.cost("complex{1,128}"));
.. _vmod_re2.set:
.. _obj_set:
set(...)
--------
new xset = re2.set(ENUM anchor, BOOL utf8, BOOL posix_syntax, BOOL longest_match, INT max_mem, BOOL literal, BOOL never_nl, BOOL dot_nl, BOOL case_sensitive, BOOL perl_classes, BOOL word_boundary, BOOL one_line)
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
::
...
...
@@ -991,10 +965,10 @@ Example::
perl_classes=true);
}
.. _
func_
set.add:
.. _
vmod_re2.
set.add:
set.add(...
)
------------
VOID xset.add(STRING, STRING string, BACKEND backend, BOOL save, BOOL never_capture
)
------------
------------------------------------------------------------------------
::
...
...
@@ -1068,8 +1042,7 @@ Example::
# See the documentation of the .string() and .backend() methods
# below for uses of the parameters string and backend for .add().
.. _func_set.compile:
.. _vmod_re2.set.compile:
VOID xset.compile()
-------------------
...
...
@@ -1090,8 +1063,7 @@ will fail.
See above for examples.
.. _func_set.match:
.. _vmod_re2.set.match:
BOOL xset.match(STRING)
-----------------------
...
...
@@ -1125,8 +1097,7 @@ Example::
call do_when_a_host_matched;
}
.. _func_set.matched:
.. _vmod_re2.set.matched:
BOOL xset.matched(INT)
----------------------
...
...
@@ -1170,8 +1141,7 @@ Example::
}
}
.. _func_set.nmatches:
.. _vmod_re2.set.nmatches:
INT xset.nmatches()
-------------------
...
...
@@ -1196,8 +1166,7 @@ Example::
+ " patterns from the set");
}
.. _func_set.which:
.. _vmod_re2.set.which:
INT xset.which(ENUM {FIRST, LAST, UNIQUE} select=UNIQUE)
--------------------------------------------------------
...
...
@@ -1260,8 +1229,7 @@ Examples::
# unsuccessful.
}
.. _func_set.string:
.. _vmod_re2.set.string:
STRING xset.string(INT n, ENUM select)
--------------------------------------
...
...
@@ -1397,8 +1365,7 @@ Examples::
# vcl_synth is implemented as shown above
.. _func_set.backend:
.. _vmod_re2.set.backend:
BACKEND xset.backend(INT n, ENUM select)
----------------------------------------
...
...
@@ -1454,11 +1421,10 @@ Example::
}
}
.. _vmod_re2.set.sub:
.. _func_set.sub:
set.sub(...)
------------
STRING xset.sub(STRING text, STRING rewrite, STRING fallback, INT n, ENUM select)
---------------------------------------------------------------------------------
::
...
...
@@ -1532,11 +1498,10 @@ Examples::
}
}
.. _vmod_re2.set.suball:
.. _func_set.suball:
set.suball(...)
---------------
STRING xset.suball(STRING text, STRING rewrite, STRING fallback, INT n, ENUM select)
------------------------------------------------------------------------------------
::
...
...
@@ -1589,11 +1554,10 @@ Example::
}
}
.. _vmod_re2.set.extract:
.. _func_set.extract:
set.extract(...)
----------------
STRING xset.extract(STRING text, STRING rewrite, STRING fallback, INT n, ENUM select)
-------------------------------------------------------------------------------------
::
...
...
@@ -1646,8 +1610,7 @@ Example::
}
}
.. _func_set.saved:
.. _vmod_re2.set.saved:
BOOL xset.saved(ENUM which, INT n, ENUM select)
-----------------------------------------------
...
...
@@ -1721,11 +1684,7 @@ Example::
# and which=REGEX by default.
}
.. _func_quotemeta:
.. _vmod_re2.quotemeta:
STRING quotemeta(STRING, STRING fallback)
-----------------------------------------
...
...
@@ -1753,8 +1712,7 @@ Example::
re2.quotemeta("1.5-2.0?") == "1\.5\-2\.0\?"
re2.match(re2.quotemeta("1.5-2.0?"), "1.5-2.0?")
.. _func_version:
.. _vmod_re2.version:
STRING version()
----------------
...
...
@@ -1830,7 +1788,6 @@ SEE ALSO
* Series of articles motivating the design of RE2, with discussion
of how RE2 compares with PCRE
COPYRIGHT
=========
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment