From 38e00caedb425f3498b7aeab382a213e3fc7fa98 Mon Sep 17 00:00:00 2001 From: Felix Fontein Date: Sat, 26 Nov 2022 22:06:43 +0100 Subject: [PATCH] Directly reference filters. (#136) --- docs/docsite/rst/quoting.rst | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/docsite/rst/quoting.rst b/docs/docsite/rst/quoting.rst index 785c7f89..3091fc85 100644 --- a/docs/docsite/rst/quoting.rst +++ b/docs/docsite/rst/quoting.rst @@ -12,8 +12,8 @@ When using the :ref:`community.routeros.command module ` quotes an argument value: ``'this is a "comment"' | community.routeros.quote_argument_value == '"this is a \\"comment\\""'``. +- The :ref:`community.routeros.quote_argument filter ` quotes an argument with or without a value: ``'comment=this is a "comment"' | community.routeros.quote_argument == 'comment="this is a \\"comment\\""'``. +- The :ref:`community.routeros.join filter ` quotes a list of arguments and joins them to one string: ``['foo=bar', 'comment=foo is bar'] | community.routeros.join == 'foo=bar comment="foo is bar"'``. +- The :ref:`community.routeros.split filter ` splits a command into a list of arguments (with or without values): ``'foo=bar comment="foo is bar"' | community.routeros.split == ['foo=bar', 'comment=foo is bar']`` +- The :ref:`community.routeros.list_to_dict filter ` splits a list of arguments with values into a dictionary: ``['foo=bar', 'comment=foo is bar'] | community.routeros.list_to_dict == {'foo': 'bar', 'comment': 'foo is bar'}``. It has two optional arguments: ``require_assignment`` (default value ``true``) allows to accept arguments without values when set to ``false``; and ``skip_empty_values`` (default value ``false``) allows to skip arguments whose value is empty.