code: def _parse_settings_vlan(opts, iface):
  
      '''
      Filters given options and outputs valid settings for a vlan
      '''
      vlan = {}
      if 'reorder_hdr' in opts:
          if opts['reorder_hdr'] in _CONFIG_TRUE + _CONFIG_FALSE:
              vlan.update({'reorder_hdr': opts['reorder_hdr']})
          else:
              valid = _CONFIG_TRUE + _CONFIG_FALSE
              _raise_error_iface(iface, 'reorder_hdr', valid)
  
      if 'vlan_id' in opts:
          if opts['vlan_id'] > 0:
              vlan.update({'vlan_id': opts['vlan_id']})
          else:
              _raise_error_iface(iface, 'vlan_id', 'Positive integer')
  
      if 'phys_dev' in opts:
          if opts['phys_dev']:
              vlan.update({'phys_dev': opts['phys_dev']})
          else:
              _raise_error_iface(iface, 'phys_dev', 'Non-empty string')
  
      return vlaf _parse_settings_vlan(opts, iface):
  
      '''
      Filters given options and outputs valid settings for a vlan
      '''
      vlan = {}
      if 'reorder_hdr' in opts:
          if opts['reorder_hdr'] in _CONFIG_TRUE + _CONFIG_FALSE:
              vlan.update({'reorder_hdr': opts['reorder_hdr']})
          else:
              valid = _CONFIG_TRUE + _CONFIG_FALSE
              _raise_error_iface(iface, 'reorder_hdr', valid)
  
      if 'vlan_id' in opts:
          if opts['vlan_id'] > 0:
              vlan.update({'vlan_id': opts['vlan_id']})
          else:
              _raise_error_iface(iface, 'vlan_id', 'Positive integer')
  
      if 'phys_dev' in opts:
          if opts['phys_dev']:
              vlan.update({'phys_dev': opts['phys_dev']})
          else:
              _raise_error_iface(iface, 'phys_dev', 'Non-empty string')
  
      return vlan
docs: Filters given options and outputs valid settings for a vlan