/*
 * 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';

/**
 * Individial resource operation information.
 *
 */
class ResourceOperation {
  /**
   * Create a ResourceOperation.
   * @member {string} [resourceName] Name of the resource as specified in the
   * artifacts. For ARM resources, this is the name of the resource specified
   * in the template.
   * @member {string} [operationId] Unique identifier of the operation. For ARM
   * resources, this is the operationId obtained from ARM service.
   * @member {string} [resourceType] Type of the resource as specified in the
   * artifacts. For ARM resources, this is the type of the resource specified
   * in the template.
   * @member {string} [provisioningState] State of the resource deployment. For
   * ARM resources, this is the current provisioning state of the resource.
   * @member {string} [statusMessage] Descriptive information of the resource
   * operation.
   * @member {string} [statusCode] Http status code of the operation.
   */
  constructor() {
  }

  /**
   * Defines the metadata of ResourceOperation
   *
   * @returns {object} metadata of ResourceOperation
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'ResourceOperation',
      type: {
        name: 'Composite',
        className: 'ResourceOperation',
        modelProperties: {
          resourceName: {
            required: false,
            serializedName: 'resourceName',
            type: {
              name: 'String'
            }
          },
          operationId: {
            required: false,
            readOnly: true,
            serializedName: 'operationId',
            type: {
              name: 'String'
            }
          },
          resourceType: {
            required: false,
            serializedName: 'resourceType',
            type: {
              name: 'String'
            }
          },
          provisioningState: {
            required: false,
            readOnly: true,
            serializedName: 'provisioningState',
            type: {
              name: 'String'
            }
          },
          statusMessage: {
            required: false,
            readOnly: true,
            serializedName: 'statusMessage',
            type: {
              name: 'String'
            }
          },
          statusCode: {
            required: false,
            readOnly: true,
            serializedName: 'statusCode',
            type: {
              name: 'String'
            }
          }
        }
      }
    };
  }
}

module.exports = ResourceOperation;
