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

/**
 * Class representing a RunbookDraft.
 */
class RunbookDraft {
  /**
   * Create a RunbookDraft.
   * @member {boolean} [inEdit] Gets or sets whether runbook is in edit mode.
   * @member {object} [draftContentLink] Gets or sets the draft runbook content
   * link.
   * @member {string} [draftContentLink.uri] Gets or sets the uri of the
   * runbook content.
   * @member {object} [draftContentLink.contentHash] Gets or sets the hash.
   * @member {string} [draftContentLink.contentHash.algorithm] Gets or sets the
   * content hash algorithm used to hash the content.
   * @member {string} [draftContentLink.contentHash.value] Gets or sets
   * expected hash value of the content.
   * @member {string} [draftContentLink.version] Gets or sets the version of
   * the content.
   * @member {date} [creationTime] Gets or sets the creation time of the
   * runbook draft.
   * @member {date} [lastModifiedTime] Gets or sets the last modified time of
   * the runbook draft.
   * @member {object} [parameters] Gets or sets the runbook draft parameters.
   * @member {array} [outputTypes] Gets or sets the runbook output types.
   */
  constructor() {
  }

  /**
   * Defines the metadata of RunbookDraft
   *
   * @returns {object} metadata of RunbookDraft
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'RunbookDraft',
      type: {
        name: 'Composite',
        className: 'RunbookDraft',
        modelProperties: {
          inEdit: {
            required: false,
            serializedName: 'inEdit',
            type: {
              name: 'Boolean'
            }
          },
          draftContentLink: {
            required: false,
            serializedName: 'draftContentLink',
            type: {
              name: 'Composite',
              className: 'ContentLink'
            }
          },
          creationTime: {
            required: false,
            nullable: false,
            serializedName: 'creationTime',
            type: {
              name: 'DateTime'
            }
          },
          lastModifiedTime: {
            required: false,
            nullable: false,
            serializedName: 'lastModifiedTime',
            type: {
              name: 'DateTime'
            }
          },
          parameters: {
            required: false,
            serializedName: 'parameters',
            type: {
              name: 'Dictionary',
              value: {
                  required: false,
                  serializedName: 'RunbookParameterElementType',
                  type: {
                    name: 'Composite',
                    className: 'RunbookParameter'
                  }
              }
            }
          },
          outputTypes: {
            required: false,
            serializedName: 'outputTypes',
            type: {
              name: 'Sequence',
              element: {
                  required: false,
                  serializedName: 'StringElementType',
                  type: {
                    name: 'String'
                  }
              }
            }
          }
        }
      }
    };
  }
}

module.exports = RunbookDraft;
