classref: Sync with current master branch (2e7fc81)

This commit is contained in:
Godot Organization
2024-02-24 03:20:02 +00:00
parent 4f21f44632
commit 8978497bb6
938 changed files with 42729 additions and 36889 deletions

View File

@@ -81,19 +81,19 @@ Methods
.. table::
:widths: auto
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_error_line<class_JSON_method_get_error_line>` **(** **)** |const| |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`get_error_message<class_JSON_method_get_error_message>` **(** **)** |const| |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`get_parsed_text<class_JSON_method_get_parsed_text>` **(** **)** |const| |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Error<enum_@GlobalScope_Error>` | :ref:`parse<class_JSON_method_parse>` **(** :ref:`String<class_String>` json_text, :ref:`bool<class_bool>` keep_text=false **)** |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Variant<class_Variant>` | :ref:`parse_string<class_JSON_method_parse_string>` **(** :ref:`String<class_String>` json_string **)** |static| |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`stringify<class_JSON_method_stringify>` **(** :ref:`Variant<class_Variant>` data, :ref:`String<class_String>` indent="", :ref:`bool<class_bool>` sort_keys=true, :ref:`bool<class_bool>` full_precision=false **)** |static| |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_error_line<class_JSON_method_get_error_line>`\ (\ ) |const| |
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`get_error_message<class_JSON_method_get_error_message>`\ (\ ) |const| |
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`get_parsed_text<class_JSON_method_get_parsed_text>`\ (\ ) |const| |
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Error<enum_@GlobalScope_Error>` | :ref:`parse<class_JSON_method_parse>`\ (\ json_text\: :ref:`String<class_String>`, keep_text\: :ref:`bool<class_bool>` = false\ ) |
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Variant<class_Variant>` | :ref:`parse_string<class_JSON_method_parse_string>`\ (\ json_string\: :ref:`String<class_String>`\ ) |static| |
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`stringify<class_JSON_method_stringify>`\ (\ data\: :ref:`Variant<class_Variant>`, indent\: :ref:`String<class_String>` = "", sort_keys\: :ref:`bool<class_bool>` = true, full_precision\: :ref:`bool<class_bool>` = false\ ) |static| |
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
@@ -112,8 +112,8 @@ Property Descriptions
.. rst-class:: classref-property-setget
- void **set_data** **(** :ref:`Variant<class_Variant>` value **)**
- :ref:`Variant<class_Variant>` **get_data** **(** **)**
- |void| **set_data**\ (\ value\: :ref:`Variant<class_Variant>`\ )
- :ref:`Variant<class_Variant>` **get_data**\ (\ )
Contains the parsed JSON data in :ref:`Variant<class_Variant>` form.
@@ -130,7 +130,7 @@ Method Descriptions
.. rst-class:: classref-method
:ref:`int<class_int>` **get_error_line** **(** **)** |const|
:ref:`int<class_int>` **get_error_line**\ (\ ) |const|
Returns ``0`` if the last call to :ref:`parse<class_JSON_method_parse>` was successful, or the line number where the parse failed.
@@ -142,7 +142,7 @@ Returns ``0`` if the last call to :ref:`parse<class_JSON_method_parse>` was succ
.. rst-class:: classref-method
:ref:`String<class_String>` **get_error_message** **(** **)** |const|
:ref:`String<class_String>` **get_error_message**\ (\ ) |const|
Returns an empty string if the last call to :ref:`parse<class_JSON_method_parse>` was successful, or the error message if it failed.
@@ -154,7 +154,7 @@ Returns an empty string if the last call to :ref:`parse<class_JSON_method_parse>
.. rst-class:: classref-method
:ref:`String<class_String>` **get_parsed_text** **(** **)** |const|
:ref:`String<class_String>` **get_parsed_text**\ (\ ) |const|
Return the text parsed by :ref:`parse<class_JSON_method_parse>` as long as the function is instructed to keep it.
@@ -166,7 +166,7 @@ Return the text parsed by :ref:`parse<class_JSON_method_parse>` as long as the f
.. rst-class:: classref-method
:ref:`Error<enum_@GlobalScope_Error>` **parse** **(** :ref:`String<class_String>` json_text, :ref:`bool<class_bool>` keep_text=false **)**
:ref:`Error<enum_@GlobalScope_Error>` **parse**\ (\ json_text\: :ref:`String<class_String>`, keep_text\: :ref:`bool<class_bool>` = false\ )
Attempts to parse the ``json_text`` provided.
@@ -184,7 +184,7 @@ The optional ``keep_text`` argument instructs the parser to keep a copy of the o
.. rst-class:: classref-method
:ref:`Variant<class_Variant>` **parse_string** **(** :ref:`String<class_String>` json_string **)** |static|
:ref:`Variant<class_Variant>` **parse_string**\ (\ json_string\: :ref:`String<class_String>`\ ) |static|
Attempts to parse the ``json_string`` provided and returns the parsed data. Returns ``null`` if parse failed.
@@ -196,7 +196,7 @@ Attempts to parse the ``json_string`` provided and returns the parsed data. Retu
.. rst-class:: classref-method
:ref:`String<class_String>` **stringify** **(** :ref:`Variant<class_Variant>` data, :ref:`String<class_String>` indent="", :ref:`bool<class_bool>` sort_keys=true, :ref:`bool<class_bool>` full_precision=false **)** |static|
:ref:`String<class_String>` **stringify**\ (\ data\: :ref:`Variant<class_Variant>`, indent\: :ref:`String<class_String>` = "", sort_keys\: :ref:`bool<class_bool>` = true, full_precision\: :ref:`bool<class_bool>` = false\ ) |static|
Converts a :ref:`Variant<class_Variant>` var to JSON text and returns the result. Useful for serializing data to store or send over the network.
@@ -252,3 +252,4 @@ The ``indent`` parameter controls if and how something is indented, the string u
.. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
.. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`
.. |bitfield| replace:: :abbr:`BitField (This value is an integer composed as a bitmask of the following flags.)`
.. |void| replace:: :abbr:`void (No return value.)`