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

/**
 * Information about a hop between the source and the destination.
 *
 */
class ConnectivityHop {
  /**
   * Create a ConnectivityHop.
   * @property {string} [type] The type of the hop.
   * @property {string} [id] The ID of the hop.
   * @property {string} [address] The IP address of the hop.
   * @property {string} [resourceId] The ID of the resource corresponding to
   * this hop.
   * @property {array} [nextHopIds] List of next hop identifiers.
   * @property {array} [issues] List of issues.
   */
  constructor() {
  }

  /**
   * Defines the metadata of ConnectivityHop
   *
   * @returns {object} metadata of ConnectivityHop
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'ConnectivityHop',
      type: {
        name: 'Composite',
        className: 'ConnectivityHop',
        modelProperties: {
          type: {
            required: false,
            readOnly: true,
            serializedName: 'type',
            type: {
              name: 'String'
            }
          },
          id: {
            required: false,
            readOnly: true,
            serializedName: 'id',
            type: {
              name: 'String'
            }
          },
          address: {
            required: false,
            readOnly: true,
            serializedName: 'address',
            type: {
              name: 'String'
            }
          },
          resourceId: {
            required: false,
            readOnly: true,
            serializedName: 'resourceId',
            type: {
              name: 'String'
            }
          },
          nextHopIds: {
            required: false,
            readOnly: true,
            serializedName: 'nextHopIds',
            type: {
              name: 'Sequence',
              element: {
                  required: false,
                  serializedName: 'StringElementType',
                  type: {
                    name: 'String'
                  }
              }
            }
          },
          issues: {
            required: false,
            readOnly: true,
            serializedName: 'issues',
            type: {
              name: 'Sequence',
              element: {
                  required: false,
                  serializedName: 'ConnectivityIssueElementType',
                  type: {
                    name: 'Composite',
                    className: 'ConnectivityIssue'
                  }
              }
            }
          }
        }
      }
    };
  }
}

module.exports = ConnectivityHop;
