#!/usr/bin/python
# Copyright: Ansible Project
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)

from __future__ import absolute_import, division, print_function
__metaclass__ = type


ANSIBLE_METADATA = {'metadata_version': '1.1',
                    'status': ['preview'],
                    'supported_by': 'community'}

DOCUMENTATION = """
---
module: icx_vlan
version_added: "2.9"
author: "Ruckus Wireless (@Commscope)"
short_description: Manage VLANs on Ruckus ICX 7000 series switches
description:
  - This module provides declarative management of VLANs
    on ICX network devices.
notes:
  - Tested against ICX 10.1.
  - For information on using ICX platform, see L(the ICX OS Platform Options guide,../network/user_guide/platform_icx.html).
options:
  name:
    description:
      - Name of the VLAN.
    type: str
  vlan_id:
    description:
      - ID of the VLAN. Range 1-4094.
    required: true
    type: int
  interfaces:
    description:
      - List of ethernet ports or LAGS to be added as access(untagged) ports to the vlan.
        To add a range of ports use 'to' keyword. See the example.
    suboptions:
      name:
        description:
          - Name of the interface or lag
        type: list
      purge:
        description:
          - Purge interfaces not defined in the I(name)
        type: bool
    type: dict
  tagged:
    description:
      - List of ethernet ports or LAGS to be added as trunk(tagged) ports to the vlan.
        To add a range of ports use 'to' keyword. See the example.
    suboptions:
      name:
        description:
          - Name of the interface or lag
        type: list
      purge:
        description:
          - Purge interfaces not defined in the I(name)
        type: bool
    type: dict
  ip_dhcp_snooping:
    description:
      - Enables DHCP snooping on a VLAN.
    type: bool