diff options
author | Aaron Franke <arnfranke@yahoo.com> | 2023-05-17 19:52:44 -0500 |
---|---|---|
committer | Aaron Franke <arnfranke@yahoo.com> | 2024-10-02 14:26:33 -0700 |
commit | a7f6ec0e4c6e502238f56d9088c1bf8a75010e6f (patch) | |
tree | 26caf16fa2f913fc7748a6a2ab37afa500aaa9ec /doc/classes/Dictionary.xml | |
parent | 1917bc3454e58fc56750b00e04aa25cb94d8d266 (diff) | |
download | redot-engine-a7f6ec0e4c6e502238f56d9088c1bf8a75010e6f.tar.gz |
Add a sort method to Dictionary and HashMap
Diffstat (limited to 'doc/classes/Dictionary.xml')
-rw-r--r-- | doc/classes/Dictionary.xml | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/doc/classes/Dictionary.xml b/doc/classes/Dictionary.xml index 4441c3cb79..5c9b22fe4a 100644 --- a/doc/classes/Dictionary.xml +++ b/doc/classes/Dictionary.xml @@ -474,6 +474,12 @@ Returns the number of entries in the dictionary. Empty dictionaries ([code]{ }[/code]) always return [code]0[/code]. See also [method is_empty]. </description> </method> + <method name="sort"> + <return type="void" /> + <description> + Sorts the dictionary in-place by key. This can be used to ensure dictionaries with the same contents produce equivalent results when getting the [method keys], getting the [method values], and converting to a string. This is also useful when wanting a JSON representation consistent with what is in memory, and useful for storing on a database that requires dictionaries to be sorted. + </description> + </method> <method name="values" qualifiers="const"> <return type="Array" /> <description> |