azure-docs-sdk-java/docs-ref-autogen/com.azure.core.models.Respo...

98 строки
7.4 KiB
YAML

### YamlMime:JavaType
uid: "com.azure.core.models.ResponseError"
fullName: "com.azure.core.models.ResponseError"
name: "ResponseError"
nameWithType: "ResponseError"
summary: "Represents the error details of an HTTP response."
inheritances:
- "<xref href=\"java.lang.Object?displayProperty=fullName\" data-throw-if-not-resolved=\"False\" />"
inheritedClassMethods:
- 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 **ResponseError**</br> implements <xref href=\"com.azure.json.JsonSerializable?alt=com.azure.json.JsonSerializable&text=JsonSerializable\" data-throw-if-not-resolved=\"False\" />&lt;<xref href=\"com.azure.core.models.ResponseError?alt=com.azure.core.models.ResponseError&text=ResponseError\" data-throw-if-not-resolved=\"False\" />&gt;"
constructors:
- uid: "com.azure.core.models.ResponseError.ResponseError(java.lang.String,java.lang.String)"
fullName: "com.azure.core.models.ResponseError.ResponseError(String code, String message)"
name: "ResponseError(String code, String message)"
nameWithType: "ResponseError.ResponseError(String code, String message)"
summary: "Creates an instance of <xref uid=\"com.azure.core.models.ResponseError\" data-throw-if-not-resolved=\"false\" data-raw-source=\"ResponseError\"></xref>."
parameters:
- description: "the error code of this error."
name: "code"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
- description: "the error message of this error."
name: "message"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
syntax: "public ResponseError(String code, String message)"
desc: "Creates an instance of <xref uid=\"com.azure.core.models.ResponseError\" data-throw-if-not-resolved=\"false\" data-raw-source=\"ResponseError\"></xref>."
methods:
- uid: "com.azure.core.models.ResponseError.fromJson(com.azure.json.JsonReader)"
fullName: "com.azure.core.models.ResponseError.fromJson(JsonReader jsonReader)"
name: "fromJson(JsonReader jsonReader)"
nameWithType: "ResponseError.fromJson(JsonReader jsonReader)"
summary: "Reads a JSON stream into a <xref uid=\"com.azure.core.models.ResponseError\" data-throw-if-not-resolved=\"false\" data-raw-source=\"ResponseError\"></xref>."
modifiers:
- "static"
parameters:
- description: "The <xref uid=\"com.azure.json.JsonReader\" data-throw-if-not-resolved=\"false\" data-raw-source=\"JsonReader\"></xref> being read."
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 ResponseError fromJson(JsonReader jsonReader)"
exceptions:
- description: "If the deserialized JSON object was missing any required properties."
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html\">IOException</a>"
desc: "Reads a JSON stream into a <xref uid=\"com.azure.core.models.ResponseError\" data-throw-if-not-resolved=\"false\" data-raw-source=\"ResponseError\"></xref>."
returns:
description: "The <xref uid=\"com.azure.core.models.ResponseError\" data-throw-if-not-resolved=\"false\" data-raw-source=\"ResponseError\"></xref> that the JSON stream represented, or null if it pointed to JSON null."
type: "<xref href=\"com.azure.core.models.ResponseError?alt=com.azure.core.models.ResponseError&text=ResponseError\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.azure.core.models.ResponseError.getCode()"
fullName: "com.azure.core.models.ResponseError.getCode()"
name: "getCode()"
nameWithType: "ResponseError.getCode()"
summary: "Returns the error code of this error."
syntax: "public String getCode()"
desc: "Returns the error code of this error."
returns:
description: "the error code of this error."
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
- uid: "com.azure.core.models.ResponseError.getMessage()"
fullName: "com.azure.core.models.ResponseError.getMessage()"
name: "getMessage()"
nameWithType: "ResponseError.getMessage()"
summary: "Returns the error message of this error."
syntax: "public String getMessage()"
desc: "Returns the error message of this error."
returns:
description: "the error message of this error."
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
- uid: "com.azure.core.models.ResponseError.toJson(com.azure.json.JsonWriter)"
fullName: "com.azure.core.models.ResponseError.toJson(JsonWriter jsonWriter)"
name: "toJson(JsonWriter jsonWriter)"
nameWithType: "ResponseError.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\" />"
type: "class"
desc: "Represents the error details of an HTTP response.\n\nThis class encapsulates the details of an HTTP error response, including the error code, message, target, inner error, and additional error details. It provides methods to access these properties.\n\nThis class also provides a <xref uid=\"com.azure.core.models.ResponseError.toJson(com.azure.json.JsonWriter)\" data-throw-if-not-resolved=\"false\" data-raw-source=\"#toJson(JsonWriter)\"></xref> method to serialize the error details to JSON, and a <xref uid=\"com.azure.core.models.ResponseError.fromJson(com.azure.json.JsonReader)\" data-throw-if-not-resolved=\"false\" data-raw-source=\"#fromJson(JsonReader)\"></xref> method to deserialize the error details from JSON."
implements:
- "<xref href=\"com.azure.json.JsonSerializable?alt=com.azure.json.JsonSerializable&text=JsonSerializable\" data-throw-if-not-resolved=\"False\" />&lt;<xref href=\"com.azure.core.models.ResponseError?alt=com.azure.core.models.ResponseError&text=ResponseError\" data-throw-if-not-resolved=\"False\" />&gt;"
metadata: {}
package: "com.azure.core.models"
artifact: com.azure:azure-core:1.52.0