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:
@@ -159,47 +159,37 @@
|
||||
</tutorials>
|
||||
<methods>
|
||||
<method name="cancel_request">
|
||||
<return type="void">
|
||||
</return>
|
||||
<return type="void" />
|
||||
<description>
|
||||
Cancels the current request.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_body_size" qualifiers="const">
|
||||
<return type="int">
|
||||
</return>
|
||||
<return type="int" />
|
||||
<description>
|
||||
Returns the response body length.
|
||||
[b]Note:[/b] Some Web servers may not send a body length. In this case, the value returned will be [code]-1[/code]. If using chunked transfer encoding, the body length will also be [code]-1[/code].
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_downloaded_bytes" qualifiers="const">
|
||||
<return type="int">
|
||||
</return>
|
||||
<return type="int" />
|
||||
<description>
|
||||
Returns the amount of bytes this HTTPRequest downloaded.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_http_client_status" qualifiers="const">
|
||||
<return type="int" enum="HTTPClient.Status">
|
||||
</return>
|
||||
<return type="int" enum="HTTPClient.Status" />
|
||||
<description>
|
||||
Returns the current status of the underlying [HTTPClient]. See [enum HTTPClient.Status].
|
||||
</description>
|
||||
</method>
|
||||
<method name="request">
|
||||
<return type="int" enum="Error">
|
||||
</return>
|
||||
<argument index="0" name="url" type="String">
|
||||
</argument>
|
||||
<argument index="1" name="custom_headers" type="PackedStringArray" default="PackedStringArray()">
|
||||
</argument>
|
||||
<argument index="2" name="ssl_validate_domain" type="bool" default="true">
|
||||
</argument>
|
||||
<argument index="3" name="method" type="int" enum="HTTPClient.Method" default="0">
|
||||
</argument>
|
||||
<argument index="4" name="request_data" type="String" default="""">
|
||||
</argument>
|
||||
<return type="int" enum="Error" />
|
||||
<argument index="0" name="url" type="String" />
|
||||
<argument index="1" name="custom_headers" type="PackedStringArray" default="PackedStringArray()" />
|
||||
<argument index="2" name="ssl_validate_domain" type="bool" default="true" />
|
||||
<argument index="3" name="method" type="int" enum="HTTPClient.Method" default="0" />
|
||||
<argument index="4" name="request_data" type="String" default="""" />
|
||||
<description>
|
||||
Creates request on the underlying [HTTPClient]. If there is no configuration errors, it tries to connect using [method HTTPClient.connect_to_host] and passes parameters onto [method HTTPClient.request].
|
||||
Returns [constant OK] if request is successfully created. (Does not imply that the server has responded), [constant ERR_UNCONFIGURED] if not in the tree, [constant ERR_BUSY] if still processing previous request, [constant ERR_INVALID_PARAMETER] if given string is not a valid URL format, or [constant ERR_CANT_CONNECT] if not using thread and the [HTTPClient] cannot connect to host.
|
||||
@@ -207,18 +197,12 @@
|
||||
</description>
|
||||
</method>
|
||||
<method name="request_raw">
|
||||
<return type="int" enum="Error">
|
||||
</return>
|
||||
<argument index="0" name="url" type="String">
|
||||
</argument>
|
||||
<argument index="1" name="custom_headers" type="PackedStringArray" default="PackedStringArray()">
|
||||
</argument>
|
||||
<argument index="2" name="ssl_validate_domain" type="bool" default="true">
|
||||
</argument>
|
||||
<argument index="3" name="method" type="int" enum="HTTPClient.Method" default="0">
|
||||
</argument>
|
||||
<argument index="4" name="request_data_raw" type="PackedByteArray" default="PackedByteArray()">
|
||||
</argument>
|
||||
<return type="int" enum="Error" />
|
||||
<argument index="0" name="url" type="String" />
|
||||
<argument index="1" name="custom_headers" type="PackedStringArray" default="PackedStringArray()" />
|
||||
<argument index="2" name="ssl_validate_domain" type="bool" default="true" />
|
||||
<argument index="3" name="method" type="int" enum="HTTPClient.Method" default="0" />
|
||||
<argument index="4" name="request_data_raw" type="PackedByteArray" default="PackedByteArray()" />
|
||||
<description>
|
||||
Creates request on the underlying [HTTPClient] using a raw array of bytes for the request body. If there is no configuration errors, it tries to connect using [method HTTPClient.connect_to_host] and passes parameters onto [method HTTPClient.request].
|
||||
Returns [constant OK] if request is successfully created. (Does not imply that the server has responded), [constant ERR_UNCONFIGURED] if not in the tree, [constant ERR_BUSY] if still processing previous request, [constant ERR_INVALID_PARAMETER] if given string is not a valid URL format, or [constant ERR_CANT_CONNECT] if not using thread and the [HTTPClient] cannot connect to host.
|
||||
@@ -253,14 +237,10 @@
|
||||
</members>
|
||||
<signals>
|
||||
<signal name="request_completed">
|
||||
<argument index="0" name="result" type="int">
|
||||
</argument>
|
||||
<argument index="1" name="response_code" type="int">
|
||||
</argument>
|
||||
<argument index="2" name="headers" type="PackedStringArray">
|
||||
</argument>
|
||||
<argument index="3" name="body" type="PackedByteArray">
|
||||
</argument>
|
||||
<argument index="0" name="result" type="int" />
|
||||
<argument index="1" name="response_code" type="int" />
|
||||
<argument index="2" name="headers" type="PackedStringArray" />
|
||||
<argument index="3" name="body" type="PackedByteArray" />
|
||||
<description>
|
||||
Emitted when a request is completed.
|
||||
</description>
|
||||
|
||||
Reference in New Issue
Block a user