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

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

/**
 * The prediction resource format.
 *
 * @extends models['ProxyResource']
 */
class PredictionResourceFormat extends models['ProxyResource'] {
  /**
   * Create a PredictionResourceFormat.
   * @member {object} [description] Description of the prediction.
   * @member {object} [displayName] Display name of the prediction.
   * @member {array} [involvedInteractionTypes] Interaction types involved in
   * the prediction.
   * @member {array} [involvedKpiTypes] KPI types involved in the prediction.
   * @member {array} [involvedRelationships] Relationships involved in the
   * prediction.
   * @member {string} negativeOutcomeExpression Negative outcome expression.
   * @member {string} positiveOutcomeExpression Positive outcome expression.
   * @member {string} primaryProfileType Primary profile type.
   * @member {string} [provisioningState] Provisioning state. Possible values
   * include: 'Provisioning', 'Succeeded', 'Expiring', 'Deleting',
   * 'HumanIntervention', 'Failed'
   * @member {string} [predictionName] Name of the prediction.
   * @member {string} scopeExpression Scope expression.
   * @member {string} [tenantId] The hub name.
   * @member {boolean} autoAnalyze Whether do auto analyze.
   * @member {object} mappings Definition of the link mapping of prediction.
   * @member {string} [mappings.score] The score of the link mapping.
   * @member {string} [mappings.grade] The grade of the link mapping.
   * @member {string} [mappings.reason] The reason of the link mapping.
   * @member {string} scoreLabel Score label.
   * @member {array} [grades] The prediction grades.
   * @member {object} [systemGeneratedEntities] System generated entities.
   * @member {array} [systemGeneratedEntities.generatedInteractionTypes]
   * Generated interaction types.
   * @member {array} [systemGeneratedEntities.generatedLinks] Generated links.
   * @member {object} [systemGeneratedEntities.generatedKpis] Generated KPIs.
   */
  constructor() {
    super();
  }

  /**
   * Defines the metadata of PredictionResourceFormat
   *
   * @returns {object} metadata of PredictionResourceFormat
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'PredictionResourceFormat',
      type: {
        name: 'Composite',
        className: 'PredictionResourceFormat',
        modelProperties: {
          id: {
            required: false,
            readOnly: true,
            serializedName: 'id',
            type: {
              name: 'String'
            }
          },
          name: {
            required: false,
            readOnly: true,
            serializedName: 'name',
            type: {
              name: 'String'
            }
          },
          type: {
            required: false,
            readOnly: true,
            serializedName: 'type',
            type: {
              name: 'String'
            }
          },
          description: {
            required: false,
            serializedName: 'properties.description',
            type: {
              name: 'Dictionary',
              value: {
                  required: false,
                  serializedName: 'StringElementType',
                  type: {
                    name: 'String'
                  }
              }
            }
          },
          displayName: {
            required: false,
            serializedName: 'properties.displayName',
            type: {
              name: 'Dictionary',
              value: {
                  required: false,
                  serializedName: 'StringElementType',
                  type: {
                    name: 'String'
                  }
              }
            }
          },
          involvedInteractionTypes: {
            required: false,
            serializedName: 'properties.involvedInteractionTypes',
            type: {
              name: 'Sequence',
              element: {
                  required: false,
                  serializedName: 'StringElementType',
                  type: {
                    name: 'String'
                  }
              }
            }
          },
          involvedKpiTypes: {
            required: false,
            serializedName: 'properties.involvedKpiTypes',
            type: {
              name: 'Sequence',
              element: {
                  required: false,
                  serializedName: 'StringElementType',
                  type: {
                    name: 'String'
                  }
              }
            }
          },
          involvedRelationships: {
            required: false,
            serializedName: 'properties.involvedRelationships',
            type: {
              name: 'Sequence',
              element: {
                  required: false,
                  serializedName: 'StringElementType',
                  type: {
                    name: 'String'
                  }
              }
            }
          },
          negativeOutcomeExpression: {
            required: true,
            serializedName: 'properties.negativeOutcomeExpression',
            type: {
              name: 'String'
            }
          },
          positiveOutcomeExpression: {
            required: true,
            serializedName: 'properties.positiveOutcomeExpression',
            type: {
              name: 'String'
            }
          },
          primaryProfileType: {
            required: true,
            serializedName: 'properties.primaryProfileType',
            type: {
              name: 'String'
            }
          },
          provisioningState: {
            required: false,
            readOnly: true,
            serializedName: 'properties.provisioningState',
            type: {
              name: 'String'
            }
          },
          predictionName: {
            required: false,
            serializedName: 'properties.predictionName',
            type: {
              name: 'String'
            }
          },
          scopeExpression: {
            required: true,
            serializedName: 'properties.scopeExpression',
            type: {
              name: 'String'
            }
          },
          tenantId: {
            required: false,
            readOnly: true,
            serializedName: 'properties.tenantId',
            type: {
              name: 'String'
            }
          },
          autoAnalyze: {
            required: true,
            serializedName: 'properties.autoAnalyze',
            type: {
              name: 'Boolean'
            }
          },
          mappings: {
            required: true,
            serializedName: 'properties.mappings',
            type: {
              name: 'Composite',
              className: 'PredictionMappings'
            }
          },
          scoreLabel: {
            required: true,
            serializedName: 'properties.scoreLabel',
            type: {
              name: 'String'
            }
          },
          grades: {
            required: false,
            serializedName: 'properties.grades',
            type: {
              name: 'Sequence',
              element: {
                  required: false,
                  serializedName: 'PredictionGradesItemElementType',
                  type: {
                    name: 'Composite',
                    className: 'PredictionGradesItem'
                  }
              }
            }
          },
          systemGeneratedEntities: {
            required: false,
            readOnly: true,
            serializedName: 'properties.systemGeneratedEntities',
            type: {
              name: 'Composite',
              className: 'PredictionSystemGeneratedEntities'
            }
          }
        }
      }
    };
  }
}

module.exports = PredictionResourceFormat;
