From 45163b10bebb07769fdb103a76468915e0066f76 Mon Sep 17 00:00:00 2001 From: J08nY Date: Wed, 1 Jun 2016 19:22:50 +0200 Subject: [PATCH 1/3] Sync classref --- doc/base/classes.xml | 61 ++++++++++++++++++++++++++++++++++---------- 1 file changed, 48 insertions(+), 13 deletions(-) diff --git a/doc/base/classes.xml b/doc/base/classes.xml index c531482950..e94da24fd5 100644 --- a/doc/base/classes.xml +++ b/doc/base/classes.xml @@ -10552,6 +10552,40 @@ This approximation makes straight segments between each point, then subdivides t + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -14403,7 +14437,7 @@ This approximation makes straight segments between each point, then subdivides t - + @@ -30850,7 +30884,7 @@ This method controls whether the position between two cached points is interpola - Return the current axis lock of the body. One of AXIS_LOCK_* enum. + Return the current axis lock of the body. One of AXIS_LOCK_* enum. @@ -30912,13 +30946,13 @@ This method controls whether the position between two cached points is interpola - Static mode. The body behaves like a [StaticBody], and can only move by user code. + Static mode. The body behaves like a [StaticBody], and can only move by user code. - Kinematic body. The body behaves like a [KinematicBody], and can only move by user code. + Kinematic body. The body behaves like a [KinematicBody], and can only move by user code. - Rigid body. This is the "natural" state of a rigid body. It is affected by forces, and can move, rotate, and be affected by user code. + Rigid body. This is the "natural" state of a rigid body. It is affected by forces, and can move, rotate, and be affected by user code. @@ -32717,8 +32751,9 @@ This method controls whether the position between two cached points is interpola + + - Reload the script. This will fail if there are existing instances. @@ -42769,10 +42804,10 @@ This method controls whether the position between two cached points is interpola - This enabler will freeze [RigidBody] nodes. + This enabler will freeze [RigidBody] nodes. - This enabler will pause [AnimationPlayer] nodes. + This enabler will pause [AnimationPlayer] nodes. @@ -42807,21 +42842,21 @@ This method controls whether the position between two cached points is interpola - This enabler will freeze [RigidBody2D] nodes. + This enabler will freeze [RigidBody2D] nodes. - This enabler will pause [AnimationPlayer] nodes. + This enabler will pause [AnimationPlayer] nodes. - This enabler will stop [Particles2D] nodes. + This enabler will stop [Particles2D] nodes. - This enabler will stop the parent's _process function. + This enabler will stop the parent's _process function. - This enabler will stop the parent's _fixed_process function. + This enabler will stop the parent's _fixed_process function. From dd4eaa10051407034bf854a7f876fbb6d1027f01 Mon Sep 17 00:00:00 2001 From: J08nY Date: Fri, 3 Jun 2016 17:55:28 +0200 Subject: [PATCH 2/3] Exposed a RESULT_DOWNLOAD_FILE_CANT_OPEN constant to docs and GDScript. --- scene/main/http_request.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scene/main/http_request.cpp b/scene/main/http_request.cpp index 328ad8fb26..2320616629 100644 --- a/scene/main/http_request.cpp +++ b/scene/main/http_request.cpp @@ -480,8 +480,9 @@ void HTTPRequest::_bind_methods() { BIND_CONSTANT( RESULT_NO_RESPONSE ); BIND_CONSTANT( RESULT_BODY_SIZE_LIMIT_EXCEEDED ); BIND_CONSTANT( RESULT_REQUEST_FAILED ); - BIND_CONSTANT( RESULT_REDIRECT_LIMIT_REACHED ); + BIND_CONSTANT( RESULT_DOWNLOAD_FILE_CANT_OPEN ); BIND_CONSTANT( RESULT_DOWNLOAD_FILE_WRITE_ERROR ); + BIND_CONSTANT( RESULT_REDIRECT_LIMIT_REACHED ); } From 4c5439f8cd787d6422a5ca30316f256227ff3405 Mon Sep 17 00:00:00 2001 From: J08nY Date: Fri, 3 Jun 2016 18:01:16 +0200 Subject: [PATCH 3/3] Added classref for HTTPClient and HTTPRequest --- doc/base/classes.xml | 62 +++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 59 insertions(+), 3 deletions(-) diff --git a/doc/base/classes.xml b/doc/base/classes.xml index e94da24fd5..a380c19115 100644 --- a/doc/base/classes.xml +++ b/doc/base/classes.xml @@ -14395,8 +14395,11 @@ This approximation makes straight segments between each point, then subdivides t + Hyper-text transfer protocol client. + Hyper-text transfer protocol client. Supports SSL and SSL server certificate verification. + Can be reused to connect to different hosts and make many requests. @@ -14420,12 +14423,14 @@ This approximation makes straight segments between each point, then subdivides t + Set connection to use, for this client. + Return current connection. @@ -14440,6 +14445,9 @@ This approximation makes straight segments between each point, then subdivides t + Sends a raw request to the connected host. The url is what is normally behind the hostname, i.e. in [code]http://somehost.com/index.php[/code], url would be "index.php". + Headers are HTTP request headers. + Sends body raw, as a byte array, does not encode it in any way. @@ -14485,30 +14493,35 @@ This approximation makes straight segments between each point, then subdivides t + Cloces the current connection, allows for reusal of [HTTPClient]. + Return whether this [HTTPClient] has a response available. + Return whether this [HTTPClient] has a response that is chunked. + Return the HTTP status code of the response. + Return the response headers. @@ -14524,32 +14537,35 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8) + Return the response's body length. + Reads one chunk from the response. - Sets the size of the buffer used and maximum bytes to read per iteration + Sets the size of the buffer used and maximum bytes to read per iteration. see [method read_response_body_chunk] - If set to true, execute will wait until all data is read from the response. + If set to true, execution will block until all data is read from the response. + Return whether blocking mode is enabled. @@ -14722,8 +14738,11 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8) + A Node with the ability to send HTTP requests. + A Node with the ability to send HTTP requests. Uses a [HTTPClient] internally, supports HTTPS. + Can be used to make HTTP requests or download files via HTTP. @@ -14736,76 +14755,91 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8) + Make a HTTP GET request. The url is the complete url including "http://" or "https://" which will be parsed for a host and a port. + The custom_headers are HTTP request headers which will be used. If User-Agent is not specified a Godot specific will be used. + The ssl_validate_domain specifies if in case of HTTPS the server certificate should be verified. + Cancel the current request. + Return the current status of the underlying [HTTPClient]. + Make this HTTPRequest use threads. + Whether this request is using threads. + Set the response body size limit. + Return current body size limit. + Set the maximum amount of redirects the request will follow. + Return the maximum amount of redirects that will be followed. + Set the file to download into. Outputs the response body into the file. + Return the file this request will download into. + Return the amount of bytes this HTTPRequest downloaded. + Return the response body length. @@ -14820,31 +14854,45 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8) + This signal is emitted upon request completion. + Request successful. + Request failed while connecting. + Request failed while resolving. + Request failed due to connection(read/write) error. + Request failed on SSL handshake. + Request does not have a response(yet). + Request exceded it's maximum size limit, see [method set_body_size_limit]. + Request failed. (unused) - + + HTTPRequest couldn't open the download file. + HTTPRequest couldn't write to the download file. + + + Request reached it's maximum redirect limit, see [method set_max_redirects]. @@ -30053,6 +30101,14 @@ This method controls whether the position between two cached points is interpola + + + + + + + +