Class DscReportError
java.lang.Object
com.azure.resourcemanager.automation.models.DscReportError
- All Implemented Interfaces:
com.azure.json.JsonSerializable<DscReportError>
public final class DscReportError
extends Object
implements com.azure.json.JsonSerializable<DscReportError>
Definition of the dsc node report error type.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the errorCode property: Gets or sets the error code.Get the errorDetails property: Gets or sets the error details.Get the errorMessage property: Gets or sets the error message.Get the errorSource property: Gets or sets the source of the error.static DscReportError
fromJson
(com.azure.json.JsonReader jsonReader) Reads an instance of DscReportError from the JsonReader.locale()
Get the locale property: Gets or sets the locale of the error.Get the resourceId property: Gets or sets the resource ID which generated the error.com.azure.json.JsonWriter
toJson
(com.azure.json.JsonWriter jsonWriter) void
validate()
Validates the instance.withErrorCode
(String errorCode) Set the errorCode property: Gets or sets the error code.withErrorDetails
(String errorDetails) Set the errorDetails property: Gets or sets the error details.withErrorMessage
(String errorMessage) Set the errorMessage property: Gets or sets the error message.withErrorSource
(String errorSource) Set the errorSource property: Gets or sets the source of the error.withLocale
(String locale) Set the locale property: Gets or sets the locale of the error.withResourceId
(String resourceId) Set the resourceId property: Gets or sets the resource ID which generated 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
-
DscReportError
public DscReportError()Creates an instance of DscReportError class.
-
-
Method Details
-
errorSource
Get the errorSource property: Gets or sets the source of the error.- Returns:
- the errorSource value.
-
withErrorSource
Set the errorSource property: Gets or sets the source of the error.- Parameters:
errorSource
- the errorSource value to set.- Returns:
- the DscReportError object itself.
-
resourceId
Get the resourceId property: Gets or sets the resource ID which generated the error.- Returns:
- the resourceId value.
-
withResourceId
Set the resourceId property: Gets or sets the resource ID which generated the error.- Parameters:
resourceId
- the resourceId value to set.- Returns:
- the DscReportError object itself.
-
errorCode
Get the errorCode property: Gets or sets the error code.- Returns:
- the errorCode value.
-
withErrorCode
Set the errorCode property: Gets or sets the error code.- Parameters:
errorCode
- the errorCode value to set.- Returns:
- the DscReportError object itself.
-
errorMessage
Get the errorMessage property: Gets or sets the error message.- Returns:
- the errorMessage value.
-
withErrorMessage
Set the errorMessage property: Gets or sets the error message.- Parameters:
errorMessage
- the errorMessage value to set.- Returns:
- the DscReportError object itself.
-
locale
Get the locale property: Gets or sets the locale of the error.- Returns:
- the locale value.
-
withLocale
Set the locale property: Gets or sets the locale of the error.- Parameters:
locale
- the locale value to set.- Returns:
- the DscReportError object itself.
-
errorDetails
Get the errorDetails property: Gets or sets the error details.- Returns:
- the errorDetails value.
-
withErrorDetails
Set the errorDetails property: Gets or sets the error details.- Parameters:
errorDetails
- the errorDetails value to set.- Returns:
- the DscReportError 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<DscReportError>
- Throws:
IOException
-
fromJson
Reads an instance of DscReportError from the JsonReader.- Parameters:
jsonReader
- The JsonReader being read.- Returns:
- An instance of DscReportError 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 DscReportError.
-