From 09a1d01b747ffb2ae58b5c9785618a36e736b6dc Mon Sep 17 00:00:00 2001 From: Nathan Warden Date: Tue, 7 Nov 2017 18:23:34 -0500 Subject: [PATCH] [DOCS] Object --- doc/classes/Object.xml | 55 +++++++++++++++++++++++++----------------- 1 file changed, 33 insertions(+), 22 deletions(-) diff --git a/doc/classes/Object.xml b/doc/classes/Object.xml index d30ebfaef82..5ba5299a777 100644 --- a/doc/classes/Object.xml +++ b/doc/classes/Object.xml @@ -21,20 +21,21 @@ - Return a property, return null if the property does not exist. + Returns the given property. Returns [code]null[/code] if the [code]property[/code] does not exist. - Return the property list, array of dictionaries, dictionaries must contain: name:String, type:int (see TYPE_* enum in [@Global Scope]) and optionally: hint:int (see PROPERTY_HINT_* in [@Global Scope]), hint_string:String, usage:int (see PROPERTY_USAGE_* in [@Global Scope]). + Returns the object's property list as an [Array] of dictionaries. Dictionaries must contain: name:String, type:int (see TYPE_* enum in [@Global Scope]) and optionally: hint:int (see PROPERTY_HINT_* in [@Global Scope]), hint_string:String, usage:int (see PROPERTY_USAGE_* in [@Global Scope]). + The virtual method called upon initialization. @@ -43,7 +44,7 @@ - Notification request, the notification id is received. + Notify the object internally using an ID. @@ -54,7 +55,7 @@ - Set a property. Return true if the property was found. + Sets a property. Returns [code]true[/code] if the [code]property[/code] exists. @@ -65,7 +66,7 @@ - Add a user signal (can be added anytime). Arguments are optional, but can be added as an array of dictionaries, each containing "name" and "type" (from [@Global Scope] TYPE_*). + Adds a user-defined [code]signal[/code]. Arguments are optional, but can be added as an [Array] of dictionaries, each containing "name" and "type" (from [@Global Scope] TYPE_*). @@ -74,6 +75,7 @@ + Calls the [code]method[/code] on the object and returns a result. Pass parameters as a comma separated list. @@ -82,6 +84,7 @@ + Calls the [code]method[/code] on the object during idle time and returns a result. Pass parameters as a comma separated list. @@ -92,13 +95,14 @@ + Calls the [code]method[/code] on the object and returns a result. Pass parameters as an [Array]. - Return true if this object can translate strings. + Returns [code]true[/code] if the object can translate strings. @@ -115,7 +119,7 @@ - Connect a signal to a method at a target (member function). Binds are optional and are passed as extra arguments to the call. Flags specify optional deferred or one shot connections, see enum CONNECT_*. A signal can only be connected once to a method, and it will throw an error if already connected. If you want to avoid this, use [method is_connected] to check. + Connects a [code]signal[/code] to a [code]method[/code] on a [code]target[/code] object. Pass optional [code]binds[/code] to the call. Use [code]flags[/code] to set deferred or one shot connections. See [code]CONNECT_*[/code] constants. A [code]signal[/code] can only be connected once to a [code]method[/code]. It will throw an error if already connected. To avoid this, first use [method is_connected] to check for existing connections. @@ -128,7 +132,7 @@ - Disconnect a signal from a method. + Disconnects a [code]signal[/code] from a [code]method[/code] on the given [code]target[/code]. @@ -137,12 +141,14 @@ + Emits the given [code]signal[/code]. + Deletes the object from memory. @@ -151,21 +157,21 @@ - Get a property from the object. + Returns a [Variant] for a [code]property[/code]. - Return the class of the object as a string. + Returns the object's class as a [String]. - Returns an [Array] of dictionaries with information about signals that are connected to this object. + Returns an [Array] of dictionaries with information about signals that are connected to the object. Inside each [Dictionary] there are 3 fields: - "source" is a reference to signal emitter. - "signal_name" is name of connected signal. @@ -176,7 +182,7 @@ - Return the instance ID. All objects have a unique instance ID. + Returns the object's unique instance ID. @@ -185,34 +191,35 @@ - Return a metadata from the object. + Returns the object's metadata for the given [code]name[/code]. - Return the list of metadata in the object. + Returns the object's metadata as a [PoolStringArray]. + Returns the object's methods and their signatures as an [Array]. - Return the list of properties as an array of dictionaries, dictionaries contain: name:String, type:int (see TYPE_* enum in [@Global Scope]) and optionally: hint:int (see PROPERTY_HINT_* in [@Global Scope]), hint_string:String, usage:int (see PROPERTY_USAGE_* in [@Global Scope]). + Returns the list of properties as an [Array] of dictionaries. Dictionaries contain: name:String, type:int (see TYPE_* enum in [@Global Scope]) and optionally: hint:int (see PROPERTY_HINT_* in [@Global Scope]), hint_string:String, usage:int (see PROPERTY_USAGE_* in [@Global Scope]). - Return the object script (or null if it doesn't have one). + Returns the object's [Script] or [code]null[/code] if one doesn't exist. @@ -221,13 +228,14 @@ + Returns an [Array] of connections for the given [code]signal[/code]. - Return the list of signals as an array of dictionaries. + Returns the list of signals as an [Array] of dictionaries. @@ -236,7 +244,7 @@ - Return true if a metadata is found with the requested name. + Returns [code]true[/code] if a metadata is found with the given [code]name[/code]. @@ -245,6 +253,7 @@ + Returns [code]true[/code] if the object contains the given [code]method[/code]. @@ -253,13 +262,14 @@ + Returns [code]true[/code] if the given user-defined [code]signal[/code] exists. - Return true if signal emission blocking is enabled. + Returns [code]true[/code] if signal emission blocking is enabled. @@ -268,7 +278,7 @@ - Check the class of the object against a string (including inheritance). + Returns [code]true[/code] if the object inherits from the given [code]type[/code]. @@ -281,13 +291,14 @@ - Return true if a connection exists for a given signal and target/method. + Returns [code]true[/code] if a connection exists for a given [code]signal[/code], [code]target[/code], and [code]method[/code]. + Returns [code]true[/code] if the [code]queue_free[/code] method was called for the object. @@ -333,7 +344,7 @@ - Define whether this object can translate strings (with calls to [method tr]). Default is true. + Define whether the object can translate strings (with calls to [method tr]). Default is true.