File: rs-re_match_i.rst

package info (click to toggle)
rsyslog-doc 8.2504.0%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 4,556 kB
  • sloc: python: 178; makefile: 8
file content (29 lines) | stat: -rw-r--r-- 553 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
************
re_match_i()
************

Purpose
=======

re_match_i(expr, re)

Returns 1, if expr matches re, 0 otherwise. Uses POSIX ERE. In contrast to
`re_match()` the matching is case-insensitive.

.. note::

   Functions using regular expressions tend to be slow and other options
   may be faster.


Example
=======

In the following example it is checked if the msg object matches the regex string.

.. code-block:: none

   re_match($msg,'TesT')

It matches it the message "Test", in any case ("TEST", "tEst", ...)
is contained in msg property.