Skip to content

Commit

Permalink
Add table structure to ref
Browse files Browse the repository at this point in the history
  • Loading branch information
p7nov committed Oct 17, 2024
1 parent 76125f6 commit d026a38
Showing 1 changed file with 30 additions and 5 deletions.
35 changes: 30 additions & 5 deletions doc/reference/reference_lua/config/utils_schema.rst
Original file line number Diff line number Diff line change
Expand Up @@ -651,7 +651,12 @@ Functions
See also: :ref:`schema_node_object <config-utils-schema_node_object>`, :ref:`schema_node_annotation <config-utils-schema_node_annotation>`.

:return: the created schema node
:return: the created array node as a table with the following fields:

- ``type``: ``array``
- ``items``: a table describing an array item as a schema node
- annotations, if provided in ``array_def``

:rtype: table

**See also:** :ref:`config_utils_schema_nodes_array`
Expand All @@ -665,7 +670,12 @@ Functions
:param table allowed_values: a list of enum members -- values allowed for the node
:param table annotations: annotations (see :ref:`schema_node_annotation <config-utils-schema_node_annotation>`)

:return: the created schema node
:return: the created scalar node as a table with the following fields:

- ``type``: ``string``
- ``allowed_values``: allowed node values
- annotations, if ``annotations`` is provided

:rtype: table

**See also:** :ref:`config_utils_schema_nodes_scalar`
Expand Down Expand Up @@ -726,7 +736,13 @@ Functions
See also: :ref:`schema_node_object <config-utils-schema_node_object>`, :ref:`schema_node_annotation <config-utils-schema_node_annotation>`.

:return: the created schema node
:return: the created map node as a table with the following fields:

- ``type``: ``map``
- ``key``: map key type
- ``value``: map value type
- annotations, if provided in ``map_def``

:rtype: table

**See also:** :ref:`config_utils_schema_nodes_map`
Expand Down Expand Up @@ -771,7 +787,12 @@ Functions

:param table annotations: annotations (see :ref:`config_utils_schema_annotation`)

:return: the created schema node
:return: the created record node as a table with the following fields:

- ``type``: ``record``
- ``fields``: a table describing the record fields
- annotations, if provided

:rtype: table

**See also:** :ref:`config_utils_schema_nodes_record`
Expand All @@ -785,7 +806,11 @@ Functions
:param string type: data type (see :ref:`config_utils_schema_data_types`)
:param table annotations: annotations (see :ref:`config_utils_schema_annotation`)

:return: the created schema node
:return: the created scalar node as a table with the following fields:

- ``type``: the node type (see :ref:`config_utils_schema_data_types`)
- annotations, if provided

:rtype: table

**See also:** :ref:`config_utils_schema_nodes_scalar`
Expand Down

0 comments on commit d026a38

Please sign in to comment.