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

/**
 * The hardware component.
 *
 */
class HardwareComponent {
  /**
   * Create a HardwareComponent.
   * @member {string} componentId The component ID.
   * @member {string} displayName The display name of the hardware component.
   * @member {string} status The status of the hardware component. Possible
   * values include: 'Unknown', 'NotPresent', 'PoweredOff', 'Ok', 'Recovering',
   * 'Warning', 'Failure'
   * @member {string} statusDisplayName The display name of the status of
   * hardware component.
   */
  constructor() {
  }

  /**
   * Defines the metadata of HardwareComponent
   *
   * @returns {object} metadata of HardwareComponent
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'HardwareComponent',
      type: {
        name: 'Composite',
        className: 'HardwareComponent',
        modelProperties: {
          componentId: {
            required: true,
            serializedName: 'componentId',
            type: {
              name: 'String'
            }
          },
          displayName: {
            required: true,
            serializedName: 'displayName',
            type: {
              name: 'String'
            }
          },
          status: {
            required: true,
            serializedName: 'status',
            type: {
              name: 'Enum',
              allowedValues: [ 'Unknown', 'NotPresent', 'PoweredOff', 'Ok', 'Recovering', 'Warning', 'Failure' ]
            }
          },
          statusDisplayName: {
            required: true,
            serializedName: 'statusDisplayName',
            type: {
              name: 'String'
            }
          }
        }
      }
    };
  }
}

module.exports = HardwareComponent;
