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

/**
 * Protection container mapping properties.
 *
 */
class ProtectionContainerMappingProperties {
  /**
   * Create a ProtectionContainerMappingProperties.
   * @member {string} [targetProtectionContainerId] Paired protection container
   * ARM ID.
   * @member {string} [targetProtectionContainerFriendlyName] Friendly name of
   * paired container.
   * @member {object} [providerSpecificDetails] Provider specific provider
   * details.
   * @member {string} [providerSpecificDetails.instanceType] Polymorphic
   * Discriminator
   * @member {string} [health] Health of pairing.
   * @member {array} [healthErrorDetails] Health error.
   * @member {string} [policyId] Policy ARM Id.
   * @member {string} [state] Association Status
   * @member {string} [sourceProtectionContainerFriendlyName] Friendly name of
   * source protection container.
   * @member {string} [sourceFabricFriendlyName] Friendly name of source
   * fabric.
   * @member {string} [targetFabricFriendlyName] Friendly name of target
   * fabric.
   * @member {string} [policyFriendlyName] Friendly name of replication policy.
   */
  constructor() {
  }

  /**
   * Defines the metadata of ProtectionContainerMappingProperties
   *
   * @returns {object} metadata of ProtectionContainerMappingProperties
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'ProtectionContainerMappingProperties',
      type: {
        name: 'Composite',
        className: 'ProtectionContainerMappingProperties',
        modelProperties: {
          targetProtectionContainerId: {
            required: false,
            serializedName: 'targetProtectionContainerId',
            type: {
              name: 'String'
            }
          },
          targetProtectionContainerFriendlyName: {
            required: false,
            serializedName: 'targetProtectionContainerFriendlyName',
            type: {
              name: 'String'
            }
          },
          providerSpecificDetails: {
            required: false,
            serializedName: 'providerSpecificDetails',
            type: {
              name: 'Composite',
              polymorphicDiscriminator: {
                serializedName: 'instanceType',
                clientName: 'instanceType'
              },
              uberParent: 'ProtectionContainerMappingProviderSpecificDetails',
              className: 'ProtectionContainerMappingProviderSpecificDetails'
            }
          },
          health: {
            required: false,
            serializedName: 'health',
            type: {
              name: 'String'
            }
          },
          healthErrorDetails: {
            required: false,
            serializedName: 'healthErrorDetails',
            type: {
              name: 'Sequence',
              element: {
                  required: false,
                  serializedName: 'HealthErrorElementType',
                  type: {
                    name: 'Composite',
                    className: 'HealthError'
                  }
              }
            }
          },
          policyId: {
            required: false,
            serializedName: 'policyId',
            type: {
              name: 'String'
            }
          },
          state: {
            required: false,
            serializedName: 'state',
            type: {
              name: 'String'
            }
          },
          sourceProtectionContainerFriendlyName: {
            required: false,
            serializedName: 'sourceProtectionContainerFriendlyName',
            type: {
              name: 'String'
            }
          },
          sourceFabricFriendlyName: {
            required: false,
            serializedName: 'sourceFabricFriendlyName',
            type: {
              name: 'String'
            }
          },
          targetFabricFriendlyName: {
            required: false,
            serializedName: 'targetFabricFriendlyName',
            type: {
              name: 'String'
            }
          },
          policyFriendlyName: {
            required: false,
            serializedName: 'policyFriendlyName',
            type: {
              name: 'String'
            }
          }
        }
      }
    };
  }
}

module.exports = ProtectionContainerMappingProperties;
