/*
 * 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.
 * Changes may cause incorrect behavior and will be lost if the code is
 * regenerated.
 */

'use strict';

/**
 * An error response from the Batch service.
 *
 */
class DeleteCertificateError {
  /**
   * Create a DeleteCertificateError.
   * @property {string} code An identifier for the error. Codes are invariant
   * and are intended to be consumed programmatically.
   * @property {string} message A message describing the error, intended to be
   * suitable for display in a user interface.
   * @property {string} [target] The target of the particular error. For
   * example, the name of the property in error.
   * @property {array} [details] A list of additional details about the error.
   */
  constructor() {
  }

  /**
   * Defines the metadata of DeleteCertificateError
   *
   * @returns {object} metadata of DeleteCertificateError
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'DeleteCertificateError',
      type: {
        name: 'Composite',
        className: 'DeleteCertificateError',
        modelProperties: {
          code: {
            required: true,
            serializedName: 'code',
            type: {
              name: 'String'
            }
          },
          message: {
            required: true,
            serializedName: 'message',
            type: {
              name: 'String'
            }
          },
          target: {
            required: false,
            serializedName: 'target',
            type: {
              name: 'String'
            }
          },
          details: {
            required: false,
            serializedName: 'details',
            type: {
              name: 'Sequence',
              element: {
                  required: false,
                  serializedName: 'DeleteCertificateErrorElementType',
                  type: {
                    name: 'Composite',
                    className: 'DeleteCertificateError'
                  }
              }
            }
          }
        }
      }
    };
  }
}

module.exports = DeleteCertificateError;
