Language

JSONObject.ToJSONArray(JSONArray) Method

Definition

Returns an array with the values corresponding to names.

[Android.Runtime.Register("toJSONArray", "(Lorg/json/JSONArray;)Lorg/json/JSONArray;", "GetToJSONArray_Lorg_json_JSONArray_Handler")]
public virtual Org.Json.JSONArray? ToJSONArray(Org.Json.JSONArray? names);
[<Android.Runtime.Register("toJSONArray", "(Lorg/json/JSONArray;)Lorg/json/JSONArray;", "GetToJSONArray_Lorg_json_JSONArray_Handler")>]
abstract member ToJSONArray : Org.Json.JSONArray -> Org.Json.JSONArray
override this.ToJSONArray : Org.Json.JSONArray -> Org.Json.JSONArray

Parameters

names
JSONArray

The array of names whose values are requested, in the order to use in the result. Non-string names are converted to strings. Can be null.

Returns

An array with one value for each requested name, including a null reference for each missing mapping. Returns null if names is null or empty. Stored Null values are retained.

Attributes

Exceptions

Remarks

Returns an array with the values corresponding to names. The array contains null for names that aren't mapped. This method returns null if names is either null or empty.

Java documentation for org.json.JSONObject.toJSONArray(org.json.JSONArray).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to