diff options
author | Sébastien Helleu <flashcode@flashtux.org> | 2017-04-29 17:54:53 +0200 |
---|---|---|
committer | Sébastien Helleu <flashcode@flashtux.org> | 2017-04-29 17:54:53 +0200 |
commit | b3073054a483da100fbf43115a86745e7994c2e9 (patch) | |
tree | 8146926a99c09316ae5e956139062b0c580c93ff /doc/it/weechat_plugin_api.it.adoc | |
parent | 1fc06ba0acc7bbf1413e0ef587e7405fd81eca34 (diff) | |
download | weechat-b3073054a483da100fbf43115a86745e7994c2e9.zip |
doc: add list of logical and comparison operators in function string_eval_expression (plugin API reference)
Diffstat (limited to 'doc/it/weechat_plugin_api.it.adoc')
-rw-r--r-- | doc/it/weechat_plugin_api.it.adoc | 114 |
1 files changed, 114 insertions, 0 deletions
diff --git a/doc/it/weechat_plugin_api.it.adoc b/doc/it/weechat_plugin_api.it.adoc index 647a392e4..c66a436d9 100644 --- a/doc/it/weechat_plugin_api.it.adoc +++ b/doc/it/weechat_plugin_api.it.adoc @@ -2085,6 +2085,120 @@ Valore restituito: if problem (invalid expression or not enough memory) // TRANSLATION MISSING +List of logical operators that can be used in conditions (by order of priority, +from first used to last): + +// TRANSLATION MISSING +[width="100%",cols="2,8,4,4",options="header"] +|=== +| Operator | Description | Examples | Results + +| `+&&+` | + Logical "and" | + `+25 && 77+` + + `+25 && 0+` | + `+1+` + + `+0+` + +| `+\|\|+` | + Logical "or" | + `+25 \|\| 0+` + + `+0 \|\| 0+` | + `+1+` + + `+0+` +|=== + +// TRANSLATION MISSING +List of comparison operators that can be used in conditions (by order of priority, +from first used to last): + +// TRANSLATION MISSING +[width="100%",cols="2,8,4,4",options="header"] +|=== +| Operator | Description | Examples | Results + +| `+=~+` | + Is matching POSIX extended regex (optional flags are allowed, see function <<_string_regcomp,string_regcomp>>) | + `+abc def =~ ab.*ef+` + + `+abc def =~ y.*z+` | + `+1+` + + `+0+` + +| `+!~+` | + Is NOT matching POSIX extended regex (optional flags are allowed, see function <<_string_regcomp,string_regcomp>>) | + `+abc def !~ ab.*ef+` + + `+abc def !~ y.*z+` | + `+0+` + + `+1+` + +| `+=*+` + + (_WeeChat ≥ 1.8_) | + Is matching mask where "*" is allowed (see function <<_string_match,string_match>>) | + `+abc def =* a*f+` + + `+abc def =* y*z+` | + `+1+` + + `+0+` + +| `+!*+` + + (_WeeChat ≥ 1.8_) | + Is NOT matching mask where "*" is allowed (see function <<_string_match,string_match>>) | + `+abc def !* a*f+` + + `+abc def !* y*z+` | + `+0+` + + `+1+` + +| `+==+` | + Equal | + `+test == test+` + + `+test == string+` | + `+1+` + + `+0+` + +| `+!=+` | + Not equal | + `+test != test+` + + `+test != string+` | + `+0+` + + `+1+` + +| `+<=+` | + Less or equal | + `+abc \<= defghi+` + + `+abc \<= abc+` + + `+defghi \<= abc+` | + `+1+` + + `+1+` + + `+0+` + +| `+<+` | + Less | + `+abc < defghi+` + + `+abc < abc+` + + `+defghi < abc+` | + `+1+` + + `+0+` + + `+0+` + +| `+>=+` | + Greater or equal | + `+defghi >= abc+` + + `+abc >= abc+` + + `+abc >= defghi+` | + `+1+` + + `+1+` + + `+0+` + +| `+>+` | + Greater | + `+defghi > abc+` + + `+abc > abc+` + + `+abc > defghi+` | + `+1+` + + `+0+` + + `+0+` +|=== + +// TRANSLATION MISSING List of variables expanded in expression (by order of priority, from first expanded to last): |