From 6ee5af0a16a5f1a32eb933e30d8b86ff4e691beb Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Mon, 21 Apr 2025 14:45:39 -0400 Subject: Add short descriptions for API methods to improve manpages --- api/tables.yaml | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'api/tables.yaml') diff --git a/api/tables.yaml b/api/tables.yaml index 6ab5f505..6a58e818 100644 --- a/api/tables.yaml +++ b/api/tables.yaml @@ -1,4 +1,5 @@ Table.clear: + short: clear a table description: > Removes all key-value pairs from the table. return: @@ -14,6 +15,7 @@ Table.clear: >> t.clear() Table.get: + short: get an item from a table description: > Retrieves the value associated with a key, or returns `none` if the key is not present. note: > @@ -46,6 +48,7 @@ Table.get: = 0 Table.get_or_set: + short: get an item or set a default if absent description: > If the given key is in the table, return the associated value. Otherwise, insert the given default value into the table and return it. @@ -85,6 +88,7 @@ Table.get_or_set: = &{"A"=@[1, 2, 3, 4], "B"=@[99], "C"=@[0, 0, 0]} Table.has: + short: check for a key description: > Checks if the table contains a specified key. return: @@ -107,6 +111,7 @@ Table.has: = no Table.remove: + short: remove a table entry description: > Removes the key-value pair associated with a specified key. return: @@ -129,6 +134,7 @@ Table.remove: = {"B"=2} Table.set: + short: set a table entry description: > Sets or updates the value associated with a specified key. return: -- cgit v1.2.3