Class CassandraError
java.lang.Object
com.azure.resourcemanager.cosmos.models.CassandraError
- All Implemented Interfaces:
com.azure.json.JsonSerializable<CassandraError>
public final class CassandraError
extends Object
implements com.azure.json.JsonSerializable<CassandraError>
The CassandraError model.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the additionalErrorInfo property: Additional information about the error.code()
Get the code property: The code of error that occurred.static CassandraError
fromJson
(com.azure.json.JsonReader jsonReader) Reads an instance of CassandraError from the JsonReader.message()
Get the message property: The message of the error.target()
Get the target property: The target resource of the error.com.azure.json.JsonWriter
toJson
(com.azure.json.JsonWriter jsonWriter) void
validate()
Validates the instance.withAdditionalErrorInfo
(String additionalErrorInfo) Set the additionalErrorInfo property: Additional information about the error.Set the code property: The code of error that occurred.withMessage
(String message) Set the message property: The message of the error.withTarget
(String target) Set the target property: The target resource of the error.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
CassandraError
public CassandraError()Creates an instance of CassandraError class.
-
-
Method Details
-
code
Get the code property: The code of error that occurred.- Returns:
- the code value.
-
withCode
Set the code property: The code of error that occurred.- Parameters:
code
- the code value to set.- Returns:
- the CassandraError object itself.
-
message
Get the message property: The message of the error.- Returns:
- the message value.
-
withMessage
Set the message property: The message of the error.- Parameters:
message
- the message value to set.- Returns:
- the CassandraError object itself.
-
target
Get the target property: The target resource of the error.- Returns:
- the target value.
-
withTarget
Set the target property: The target resource of the error.- Parameters:
target
- the target value to set.- Returns:
- the CassandraError object itself.
-
additionalErrorInfo
Get the additionalErrorInfo property: Additional information about the error.- Returns:
- the additionalErrorInfo value.
-
withAdditionalErrorInfo
Set the additionalErrorInfo property: Additional information about the error.- Parameters:
additionalErrorInfo
- the additionalErrorInfo value to set.- Returns:
- the CassandraError object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException
- thrown if the instance is not valid.
-
toJson
- Specified by:
toJson
in interfacecom.azure.json.JsonSerializable<CassandraError>
- Throws:
IOException
-
fromJson
Reads an instance of CassandraError from the JsonReader.- Parameters:
jsonReader
- The JsonReader being read.- Returns:
- An instance of CassandraError if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
- Throws:
IOException
- If an error occurs while reading the CassandraError.
-