String Lists

Syntax

"[" string *("," string) "]" / string

Description

When matching patterns, it is frequently convenient to match against groups of strings instead of single strings. For this reason, a list of strings is allowed in many tests, implying that if the test is true using any one of the strings, then the test is true. Implementations are encouraged to use short-circuit evaluation in these cases.

For instance, the test header :contains ["To", "Cc"] ["me@example.com", "me00@landru.example.edu"] is true if either the To header or Cc header of the input message contains either of the e-mail addresses "me@example.com" or "me00@landru.example.edu".

Conversely, in any case where a list of strings is appropriate, a single string is allowed without being a member of a list: it is equivalent to a list with a single member. This means that the test exists "To" is equivalent to the test exists ["To"].

Module

Core : Requires no import statement

Resources

RFC3028