190 строки
13 KiB
YAML
190 строки
13 KiB
YAML
### YamlMime:JavaType
|
|
uid: "com.azure.json.models.JsonArray"
|
|
fullName: "com.azure.json.models.JsonArray"
|
|
name: "JsonArray"
|
|
nameWithType: "JsonArray"
|
|
summary: "Model representing a JSON array."
|
|
inheritances:
|
|
- "<xref href=\"java.lang.Object?displayProperty=fullName\" data-throw-if-not-resolved=\"False\" />"
|
|
- "<xref href=\"com.azure.json.models.JsonElement?displayProperty=fullName\" data-throw-if-not-resolved=\"False\" />"
|
|
inheritedClassMethods:
|
|
- classRef: "<xref href=\"com.azure.json.models.JsonElement?alt=com.azure.json.models.JsonElement&text=JsonElement\" data-throw-if-not-resolved=\"False\" />"
|
|
methodsRef:
|
|
- "<xref href=\"com.azure.json.models.JsonElement.isArray()?alt=com.azure.json.models.JsonElement.isArray&text=isArray\" data-throw-if-not-resolved=\"False\" />"
|
|
- "<xref href=\"com.azure.json.models.JsonElement.isBoolean()?alt=com.azure.json.models.JsonElement.isBoolean&text=isBoolean\" data-throw-if-not-resolved=\"False\" />"
|
|
- "<xref href=\"com.azure.json.models.JsonElement.isNull()?alt=com.azure.json.models.JsonElement.isNull&text=isNull\" data-throw-if-not-resolved=\"False\" />"
|
|
- "<xref href=\"com.azure.json.models.JsonElement.isNumber()?alt=com.azure.json.models.JsonElement.isNumber&text=isNumber\" data-throw-if-not-resolved=\"False\" />"
|
|
- "<xref href=\"com.azure.json.models.JsonElement.isObject()?alt=com.azure.json.models.JsonElement.isObject&text=isObject\" data-throw-if-not-resolved=\"False\" />"
|
|
- "<xref href=\"com.azure.json.models.JsonElement.isString()?alt=com.azure.json.models.JsonElement.isString&text=isString\" data-throw-if-not-resolved=\"False\" />"
|
|
- classRef: "java.lang.<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html\">Object</a>"
|
|
methodsRef:
|
|
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#clone--\">clone</a>"
|
|
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#equals-java.lang.Object-\">equals</a>"
|
|
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#finalize--\">finalize</a>"
|
|
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#getClass--\">getClass</a>"
|
|
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#hashCode--\">hashCode</a>"
|
|
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#notify--\">notify</a>"
|
|
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#notifyAll--\">notifyAll</a>"
|
|
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#toString--\">toString</a>"
|
|
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#wait--\">wait</a>"
|
|
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#wait-long-\">wait</a>"
|
|
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#wait-long-int-\">wait</a>"
|
|
syntax: "public final class **JsonArray**</br> extends <xref href=\"com.azure.json.models.JsonElement?alt=com.azure.json.models.JsonElement&text=JsonElement\" data-throw-if-not-resolved=\"False\" />"
|
|
constructors:
|
|
- uid: "com.azure.json.models.JsonArray.JsonArray()"
|
|
fullName: "com.azure.json.models.JsonArray.JsonArray()"
|
|
name: "JsonArray()"
|
|
nameWithType: "JsonArray.JsonArray()"
|
|
summary: "Default constructor."
|
|
syntax: "public JsonArray()"
|
|
desc: "Default constructor."
|
|
methods:
|
|
- uid: "com.azure.json.models.JsonArray.addElement(com.azure.json.models.JsonElement)"
|
|
fullName: "com.azure.json.models.JsonArray.addElement(JsonElement element)"
|
|
name: "addElement(JsonElement element)"
|
|
nameWithType: "JsonArray.addElement(JsonElement element)"
|
|
summary: "Adds a Json<wbr>Element to the JSON array."
|
|
parameters:
|
|
- description: "The JsonElement to add to the array."
|
|
name: "element"
|
|
type: "<xref href=\"com.azure.json.models.JsonElement?alt=com.azure.json.models.JsonElement&text=JsonElement\" data-throw-if-not-resolved=\"False\" />"
|
|
syntax: "public JsonArray addElement(JsonElement element)"
|
|
desc: "Adds a JsonElement to the JSON array. This element will be appended to the end of the array."
|
|
returns:
|
|
description: "The updated JsonArray object."
|
|
type: "<xref href=\"com.azure.json.models.JsonArray?alt=com.azure.json.models.JsonArray&text=JsonArray\" data-throw-if-not-resolved=\"False\" />"
|
|
- uid: "com.azure.json.models.JsonArray.addElement(int,com.azure.json.models.JsonElement)"
|
|
fullName: "com.azure.json.models.JsonArray.addElement(int index, JsonElement element)"
|
|
name: "addElement(int index, JsonElement element)"
|
|
nameWithType: "JsonArray.addElement(int index, JsonElement element)"
|
|
summary: "Adds a Json<wbr>Element to the JSON array at the specified index."
|
|
parameters:
|
|
- description: "The index at which to add the element."
|
|
name: "index"
|
|
type: "<xref href=\"int?alt=int&text=int\" data-throw-if-not-resolved=\"False\" />"
|
|
- description: "The JsonElement to add to the array."
|
|
name: "element"
|
|
type: "<xref href=\"com.azure.json.models.JsonElement?alt=com.azure.json.models.JsonElement&text=JsonElement\" data-throw-if-not-resolved=\"False\" />"
|
|
syntax: "public JsonArray addElement(int index, JsonElement element)"
|
|
desc: "Adds a JsonElement to the JSON array at the specified index. This element will be inserted at the specified index and all elements at or after the index will be shifted."
|
|
returns:
|
|
description: "The updated JsonArray object."
|
|
type: "<xref href=\"com.azure.json.models.JsonArray?alt=com.azure.json.models.JsonArray&text=JsonArray\" data-throw-if-not-resolved=\"False\" />"
|
|
- uid: "com.azure.json.models.JsonArray.fromJson(com.azure.json.JsonReader)"
|
|
fullName: "com.azure.json.models.JsonArray.fromJson(JsonReader jsonReader)"
|
|
name: "fromJson(JsonReader jsonReader)"
|
|
nameWithType: "JsonArray.fromJson(JsonReader jsonReader)"
|
|
summary: "Deserializes a JSON array from a Json<wbr>Reader."
|
|
modifiers:
|
|
- "static"
|
|
parameters:
|
|
- description: "The JsonReader to deserialize from."
|
|
name: "jsonReader"
|
|
type: "<xref href=\"com.azure.json.JsonReader?alt=com.azure.json.JsonReader&text=JsonReader\" data-throw-if-not-resolved=\"False\" />"
|
|
syntax: "public static JsonArray fromJson(JsonReader jsonReader)"
|
|
exceptions:
|
|
- description: "If an error occurs while deserializing the JSON array."
|
|
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html\">IOException</a>"
|
|
desc: "Deserializes a JSON array from a JsonReader.\n\nIf the JsonReader's current token is null, it is assumed the JsonReader hasn't begun reading and <xref uid=\"com.azure.json.JsonReader.nextToken()\" data-throw-if-not-resolved=\"false\" data-raw-source=\"JsonReader#nextToken()\"></xref> will be called to begin reading.\n\nAfter ensuring the JsonReader has begun reading, if the current token is not <xref uid=\"com.azure.json.JsonToken.START_ARRAY\" data-throw-if-not-resolved=\"false\" data-raw-source=\"JsonToken#START_ARRAY\"></xref>, an <xref uid=\"\" data-throw-if-not-resolved=\"false\" data-raw-source=\"IllegalStateException\"></xref> will be thrown. Otherwise, a JSON array representing the array will be created and returned."
|
|
returns:
|
|
description: "The deserialized JSON array."
|
|
type: "<xref href=\"com.azure.json.models.JsonArray?alt=com.azure.json.models.JsonArray&text=JsonArray\" data-throw-if-not-resolved=\"False\" />"
|
|
- uid: "com.azure.json.models.JsonArray.getElement(int)"
|
|
fullName: "com.azure.json.models.JsonArray.getElement(int index)"
|
|
name: "getElement(int index)"
|
|
nameWithType: "JsonArray.getElement(int index)"
|
|
summary: "Gets the Json<wbr>Element at the specified index from the Json<wbr>Array."
|
|
parameters:
|
|
- description: "The index at which to get the element."
|
|
name: "index"
|
|
type: "<xref href=\"int?alt=int&text=int\" data-throw-if-not-resolved=\"False\" />"
|
|
syntax: "public JsonElement getElement(int index)"
|
|
exceptions:
|
|
- description: "If the <code>index</code> is less than zero or greater than or equal to\n <xref uid=\"#size()\" data-throw-if-not-resolved=\"false\" data-raw-source=\"#size()\"></xref>."
|
|
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html\">IndexOutOfBoundsException</a>"
|
|
desc: "Gets the JsonElement at the specified index from the JsonArray."
|
|
returns:
|
|
description: "The JsonElement at the specified index."
|
|
type: "<xref href=\"com.azure.json.models.JsonElement?alt=com.azure.json.models.JsonElement&text=JsonElement\" data-throw-if-not-resolved=\"False\" />"
|
|
- uid: "com.azure.json.models.JsonArray.isArray()"
|
|
fullName: "com.azure.json.models.JsonArray.isArray()"
|
|
name: "isArray()"
|
|
nameWithType: "JsonArray.isArray()"
|
|
summary: "Indicates whether the element is an array."
|
|
overridden: "com.azure.json.models.JsonElement.isArray()"
|
|
syntax: "public boolean isArray()"
|
|
desc: "Indicates whether the element is an array."
|
|
returns:
|
|
description: "boolean of whether this JsonElement object is of type JsonArray."
|
|
type: "<xref href=\"boolean?alt=boolean&text=boolean\" data-throw-if-not-resolved=\"False\" />"
|
|
- uid: "com.azure.json.models.JsonArray.removeElement(int)"
|
|
fullName: "com.azure.json.models.JsonArray.removeElement(int index)"
|
|
name: "removeElement(int index)"
|
|
nameWithType: "JsonArray.removeElement(int index)"
|
|
summary: "Removes the Json<wbr>Element at the specified index from the Json<wbr>Array."
|
|
parameters:
|
|
- description: "The index at which to remove the element."
|
|
name: "index"
|
|
type: "<xref href=\"int?alt=int&text=int\" data-throw-if-not-resolved=\"False\" />"
|
|
syntax: "public JsonElement removeElement(int index)"
|
|
exceptions:
|
|
- description: "If the <code>index</code> is less than zero or greater than or equal to\n <xref uid=\"#size()\" data-throw-if-not-resolved=\"false\" data-raw-source=\"#size()\"></xref>."
|
|
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html\">IndexOutOfBoundsException</a>"
|
|
desc: "Removes the JsonElement at the specified index from the JsonArray. This will shift all elements after the specified index."
|
|
returns:
|
|
description: "The removed JsonElement."
|
|
type: "<xref href=\"com.azure.json.models.JsonElement?alt=com.azure.json.models.JsonElement&text=JsonElement\" data-throw-if-not-resolved=\"False\" />"
|
|
- uid: "com.azure.json.models.JsonArray.setElement(int,com.azure.json.models.JsonElement)"
|
|
fullName: "com.azure.json.models.JsonArray.setElement(int index, JsonElement element)"
|
|
name: "setElement(int index, JsonElement element)"
|
|
nameWithType: "JsonArray.setElement(int index, JsonElement element)"
|
|
summary: "Sets a specified Json<wbr>Element object at a specified index within the Json<wbr>Array."
|
|
parameters:
|
|
- description: "The index at which to set the element."
|
|
name: "index"
|
|
type: "<xref href=\"int?alt=int&text=int\" data-throw-if-not-resolved=\"False\" />"
|
|
- description: "The JsonElement to set at the specified index."
|
|
name: "element"
|
|
type: "<xref href=\"com.azure.json.models.JsonElement?alt=com.azure.json.models.JsonElement&text=JsonElement\" data-throw-if-not-resolved=\"False\" />"
|
|
syntax: "public JsonArray setElement(int index, JsonElement element)"
|
|
desc: "Sets a specified JsonElement object at a specified index within the JsonArray. This will replace the current JsonElement at the specified index with the newly specified JsonElement object."
|
|
returns:
|
|
description: "The updated JsonArray object."
|
|
type: "<xref href=\"com.azure.json.models.JsonArray?alt=com.azure.json.models.JsonArray&text=JsonArray\" data-throw-if-not-resolved=\"False\" />"
|
|
- uid: "com.azure.json.models.JsonArray.size()"
|
|
fullName: "com.azure.json.models.JsonArray.size()"
|
|
name: "size()"
|
|
nameWithType: "JsonArray.size()"
|
|
summary: "The number of elements in the Json<wbr>Array."
|
|
syntax: "public int size()"
|
|
desc: "The number of elements in the JsonArray."
|
|
returns:
|
|
description: "The number of elements in the JsonArray."
|
|
type: "<xref href=\"int?alt=int&text=int\" data-throw-if-not-resolved=\"False\" />"
|
|
- uid: "com.azure.json.models.JsonArray.toJson(com.azure.json.JsonWriter)"
|
|
fullName: "com.azure.json.models.JsonArray.toJson(JsonWriter jsonWriter)"
|
|
name: "toJson(JsonWriter jsonWriter)"
|
|
nameWithType: "JsonArray.toJson(JsonWriter jsonWriter)"
|
|
parameters:
|
|
- name: "jsonWriter"
|
|
type: "<xref href=\"com.azure.json.JsonWriter?alt=com.azure.json.JsonWriter&text=JsonWriter\" data-throw-if-not-resolved=\"False\" />"
|
|
syntax: "public JsonWriter toJson(JsonWriter jsonWriter)"
|
|
exceptions:
|
|
- type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html\">IOException</a>"
|
|
returns:
|
|
type: "<xref href=\"com.azure.json.JsonWriter?alt=com.azure.json.JsonWriter&text=JsonWriter\" data-throw-if-not-resolved=\"False\" />"
|
|
- uid: "com.azure.json.models.JsonArray.toJsonString()"
|
|
fullName: "com.azure.json.models.JsonArray.toJsonString()"
|
|
name: "toJsonString()"
|
|
nameWithType: "JsonArray.toJsonString()"
|
|
syntax: "public String toJsonString()"
|
|
exceptions:
|
|
- type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html\">IOException</a>"
|
|
returns:
|
|
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
|
|
type: "class"
|
|
desc: "Model representing a JSON array."
|
|
metadata: {}
|
|
package: "com.azure.json.models"
|
|
artifact: com.azure:azure-json:1.3.0
|