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

var models = require('./index');

var util = require('util');

/**
 * @class
 * Initializes a new instance of the USqlView class.
 * @constructor
 * A Data Lake Analytics catalog U-SQL view item.
 *
 * @member {string} [databaseName] the name of the database.
 * 
 * @member {string} [schemaName] the name of the schema associated with this
 * view and database.
 * 
 * @member {string} [name] the name of the view.
 * 
 * @member {string} [definition] the defined query of the view.
 * 
 */
function USqlView() {
  USqlView['super_'].call(this);
}

util.inherits(USqlView, models['CatalogItem']);

/**
 * Defines the metadata of USqlView
 *
 * @returns {object} metadata of USqlView
 *
 */
USqlView.prototype.mapper = function () {
  return {
    required: false,
    serializedName: 'USqlView',
    type: {
      name: 'Composite',
      className: 'USqlView',
      modelProperties: {
        computeAccountName: {
          required: false,
          serializedName: 'computeAccountName',
          type: {
            name: 'String'
          }
        },
        version: {
          required: false,
          serializedName: 'version',
          type: {
            name: 'String'
          }
        },
        databaseName: {
          required: false,
          serializedName: 'databaseName',
          type: {
            name: 'String'
          }
        },
        schemaName: {
          required: false,
          serializedName: 'schemaName',
          type: {
            name: 'String'
          }
        },
        name: {
          required: false,
          serializedName: 'viewName',
          type: {
            name: 'String'
          }
        },
        definition: {
          required: false,
          serializedName: 'definition',
          type: {
            name: 'String'
          }
        }
      }
    }
  };
};

module.exports = USqlView;
