// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.quantum.jobs.models;

import com.azure.core.annotation.Fluent;
import com.fasterxml.jackson.annotation.JsonProperty;

/** An error response from Azure. */
@Fluent
public final class ErrorData {
    /*
     * An identifier for the error. Codes are invariant and are intended to be
     * consumed programmatically.
     */
    @JsonProperty(value = "code")
    private String code;

    /*
     * A message describing the error, intended to be suitable for displaying
     * in a user interface.
     */
    @JsonProperty(value = "message")
    private String message;

    /**
     * Get the code property: An identifier for the error. Codes are invariant and are intended to be consumed
     * programmatically.
     *
     * @return the code value.
     */
    public String getCode() {
        return this.code;
    }

    /**
     * Set the code property: An identifier for the error. Codes are invariant and are intended to be consumed
     * programmatically.
     *
     * @param code the code value to set.
     * @return the ErrorData object itself.
     */
    public ErrorData setCode(String code) {
        this.code = code;
        return this;
    }

    /**
     * Get the message property: A message describing the error, intended to be suitable for displaying in a user
     * interface.
     *
     * @return the message value.
     */
    public String getMessage() {
        return this.message;
    }

    /**
     * Set the message property: A message describing the error, intended to be suitable for displaying in a user
     * interface.
     *
     * @param message the message value to set.
     * @return the ErrorData object itself.
     */
    public ErrorData setMessage(String message) {
        this.message = message;
        return this;
    }
}
