mirror of
https://github.com/godotengine/godot.git
synced 2026-01-03 18:11:19 +03:00
doc: Use self-closing tags for return and argument
For the time being we don't support writing a description for those, preferring having all details in the method's description. Using self-closing tags saves half the lines, and prevents contributors from thinking that they should write the argument or return documentation there.
This commit is contained in:
@@ -13,81 +13,63 @@
|
||||
</tutorials>
|
||||
<methods>
|
||||
<method name="get_date_dict_from_system" qualifiers="const">
|
||||
<return type="Dictionary">
|
||||
</return>
|
||||
<argument index="0" name="utc" type="bool" default="false">
|
||||
</argument>
|
||||
<return type="Dictionary" />
|
||||
<argument index="0" name="utc" type="bool" default="false" />
|
||||
<description>
|
||||
Returns the current date as a dictionary of keys: [code]year[/code], [code]month[/code], [code]day[/code], [code]weekday[/code], and [code]dst[/code] (Daylight Savings Time).
|
||||
The returned values are in the system's local time when [code]utc[/code] is false, otherwise they are in UTC.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_date_dict_from_unix_time" qualifiers="const">
|
||||
<return type="Dictionary">
|
||||
</return>
|
||||
<argument index="0" name="unix_time_val" type="int">
|
||||
</argument>
|
||||
<return type="Dictionary" />
|
||||
<argument index="0" name="unix_time_val" type="int" />
|
||||
<description>
|
||||
Converts the given Unix timestamp to a dictionary of keys: [code]year[/code], [code]month[/code], [code]day[/code], and [code]weekday[/code].
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_date_string_from_system" qualifiers="const">
|
||||
<return type="String">
|
||||
</return>
|
||||
<argument index="0" name="utc" type="bool" default="false">
|
||||
</argument>
|
||||
<return type="String" />
|
||||
<argument index="0" name="utc" type="bool" default="false" />
|
||||
<description>
|
||||
Returns the current date as an ISO 8601 date string (YYYY-MM-DD).
|
||||
The returned values are in the system's local time when [code]utc[/code] is false, otherwise they are in UTC.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_date_string_from_unix_time" qualifiers="const">
|
||||
<return type="String">
|
||||
</return>
|
||||
<argument index="0" name="unix_time_val" type="int">
|
||||
</argument>
|
||||
<return type="String" />
|
||||
<argument index="0" name="unix_time_val" type="int" />
|
||||
<description>
|
||||
Converts the given Unix timestamp to an ISO 8601 date string (YYYY-MM-DD).
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_datetime_dict_from_string" qualifiers="const">
|
||||
<return type="Dictionary">
|
||||
</return>
|
||||
<argument index="0" name="datetime" type="String">
|
||||
</argument>
|
||||
<argument index="1" name="weekday" type="bool">
|
||||
</argument>
|
||||
<return type="Dictionary" />
|
||||
<argument index="0" name="datetime" type="String" />
|
||||
<argument index="1" name="weekday" type="bool" />
|
||||
<description>
|
||||
Converts the given ISO 8601 date and time string (YYYY-MM-DDTHH:MM:SS) to a dictionary of keys: [code]year[/code], [code]month[/code], [code]day[/code], [code]weekday[/code], [code]hour[/code], [code]minute[/code], and [code]second[/code].
|
||||
If [code]weekday[/code] is false, then the [code]weekday[/code] entry is excluded (the calculation is relatively expensive).
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_datetime_dict_from_system" qualifiers="const">
|
||||
<return type="Dictionary">
|
||||
</return>
|
||||
<argument index="0" name="utc" type="bool" default="false">
|
||||
</argument>
|
||||
<return type="Dictionary" />
|
||||
<argument index="0" name="utc" type="bool" default="false" />
|
||||
<description>
|
||||
Returns the current date as a dictionary of keys: [code]year[/code], [code]month[/code], [code]day[/code], [code]weekday[/code], [code]hour[/code], [code]minute[/code], and [code]second[/code].
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_datetime_dict_from_unix_time" qualifiers="const">
|
||||
<return type="Dictionary">
|
||||
</return>
|
||||
<argument index="0" name="unix_time_val" type="int">
|
||||
</argument>
|
||||
<return type="Dictionary" />
|
||||
<argument index="0" name="unix_time_val" type="int" />
|
||||
<description>
|
||||
Converts the given Unix timestamp to a dictionary of keys: [code]year[/code], [code]month[/code], [code]day[/code], and [code]weekday[/code].
|
||||
The returned Dictionary's values will be the same as the [method get_datetime_dict_from_system] if the Unix timestamp is the current time, with the exception of Daylight Savings Time as it cannot be determined from the epoch.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_datetime_string_from_dict" qualifiers="const">
|
||||
<return type="String">
|
||||
</return>
|
||||
<argument index="0" name="datetime" type="Dictionary">
|
||||
</argument>
|
||||
<argument index="1" name="use_space" type="bool">
|
||||
</argument>
|
||||
<return type="String" />
|
||||
<argument index="0" name="datetime" type="Dictionary" />
|
||||
<argument index="1" name="use_space" type="bool" />
|
||||
<description>
|
||||
Converts the given dictionary of keys to an ISO 8601 date and time string (YYYY-MM-DDTHH:MM:SS).
|
||||
The given dictionary can be populated with the following keys: [code]year[/code], [code]month[/code], [code]day[/code], [code]hour[/code], [code]minute[/code], and [code]second[/code]. Any other entries (including [code]dst[/code]) are ignored.
|
||||
@@ -96,12 +78,9 @@
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_datetime_string_from_system" qualifiers="const">
|
||||
<return type="String">
|
||||
</return>
|
||||
<argument index="0" name="utc" type="bool" default="false">
|
||||
</argument>
|
||||
<argument index="1" name="use_space" type="bool" default="false">
|
||||
</argument>
|
||||
<return type="String" />
|
||||
<argument index="0" name="utc" type="bool" default="false" />
|
||||
<argument index="1" name="use_space" type="bool" default="false" />
|
||||
<description>
|
||||
Returns the current date and time as a dictionary of keys: [code]year[/code], [code]month[/code], [code]day[/code], [code]weekday[/code], [code]dst[/code] (Daylight Savings Time), [code]hour[/code], [code]minute[/code], and [code]second[/code].
|
||||
The returned values are in the system's local time when [code]utc[/code] is false, otherwise they are in UTC.
|
||||
@@ -109,81 +88,65 @@
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_datetime_string_from_unix_time" qualifiers="const">
|
||||
<return type="String">
|
||||
</return>
|
||||
<argument index="0" name="unix_time_val" type="int">
|
||||
</argument>
|
||||
<argument index="1" name="use_space" type="bool" default="false">
|
||||
</argument>
|
||||
<return type="String" />
|
||||
<argument index="0" name="unix_time_val" type="int" />
|
||||
<argument index="1" name="use_space" type="bool" default="false" />
|
||||
<description>
|
||||
Converts the given Unix timestamp to an ISO 8601 date and time string (YYYY-MM-DDTHH:MM:SS).
|
||||
If [code]use_space[/code] is true, use a space instead of the letter T in the middle.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_ticks_msec" qualifiers="const">
|
||||
<return type="int">
|
||||
</return>
|
||||
<return type="int" />
|
||||
<description>
|
||||
Returns the amount of time passed in milliseconds since the engine started.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_ticks_usec" qualifiers="const">
|
||||
<return type="int">
|
||||
</return>
|
||||
<return type="int" />
|
||||
<description>
|
||||
Returns the amount of time passed in microseconds since the engine started.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_time_dict_from_system" qualifiers="const">
|
||||
<return type="Dictionary">
|
||||
</return>
|
||||
<argument index="0" name="utc" type="bool" default="false">
|
||||
</argument>
|
||||
<return type="Dictionary" />
|
||||
<argument index="0" name="utc" type="bool" default="false" />
|
||||
<description>
|
||||
Returns the current time as a dictionary of keys: [code]hour[/code], [code]minute[/code], and [code]second[/code].
|
||||
The returned values are in the system's local time when [code]utc[/code] is false, otherwise they are in UTC.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_time_dict_from_unix_time" qualifiers="const">
|
||||
<return type="Dictionary">
|
||||
</return>
|
||||
<argument index="0" name="unix_time_val" type="int">
|
||||
</argument>
|
||||
<return type="Dictionary" />
|
||||
<argument index="0" name="unix_time_val" type="int" />
|
||||
<description>
|
||||
Converts the given time to a dictionary of keys: [code]hour[/code], [code]minute[/code], and [code]second[/code].
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_time_string_from_system" qualifiers="const">
|
||||
<return type="String">
|
||||
</return>
|
||||
<argument index="0" name="utc" type="bool" default="false">
|
||||
</argument>
|
||||
<return type="String" />
|
||||
<argument index="0" name="utc" type="bool" default="false" />
|
||||
<description>
|
||||
Returns the current time as an ISO 8601 time string (HH:MM:SS).
|
||||
The returned values are in the system's local time when [code]utc[/code] is false, otherwise they are in UTC.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_time_string_from_unix_time" qualifiers="const">
|
||||
<return type="String">
|
||||
</return>
|
||||
<argument index="0" name="unix_time_val" type="int">
|
||||
</argument>
|
||||
<return type="String" />
|
||||
<argument index="0" name="unix_time_val" type="int" />
|
||||
<description>
|
||||
Converts the given Unix timestamp to an ISO 8601 time string (HH:MM:SS).
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_time_zone_from_system" qualifiers="const">
|
||||
<return type="Dictionary">
|
||||
</return>
|
||||
<return type="Dictionary" />
|
||||
<description>
|
||||
Returns the current time zone as a dictionary of keys: [code]bias[/code] and [code]name[/code]. The [code]bias[/code] value is the offset from UTC in minutes, since not all time zones are multiples of an hour from UTC.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_unix_time_from_datetime_dict" qualifiers="const">
|
||||
<return type="int">
|
||||
</return>
|
||||
<argument index="0" name="datetime" type="Dictionary">
|
||||
</argument>
|
||||
<return type="int" />
|
||||
<argument index="0" name="datetime" type="Dictionary" />
|
||||
<description>
|
||||
Converts a dictionary of time values to a Unix timestamp.
|
||||
The given dictionary can be populated with the following keys: [code]year[/code], [code]month[/code], [code]day[/code], [code]hour[/code], [code]minute[/code], and [code]second[/code]. Any other entries (including [code]dst[/code]) are ignored.
|
||||
@@ -192,17 +155,14 @@
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_unix_time_from_datetime_string" qualifiers="const">
|
||||
<return type="int">
|
||||
</return>
|
||||
<argument index="0" name="datetime" type="String">
|
||||
</argument>
|
||||
<return type="int" />
|
||||
<argument index="0" name="datetime" type="String" />
|
||||
<description>
|
||||
Converts the given ISO 8601 date and/or time string to a Unix timestamp. The string can contain a date only, a time only, or both.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_unix_time_from_system" qualifiers="const">
|
||||
<return type="float">
|
||||
</return>
|
||||
<return type="float" />
|
||||
<description>
|
||||
Returns the current Unix timestamp in seconds based on the system time.
|
||||
</description>
|
||||
|
||||
Reference in New Issue
Block a user