def _create_network_adapters(network_interfaces, parent=None):
    '''
    Returns a list of vim.vm.device.VirtualDeviceSpec objects representing
    the interfaces to be created for a virtual machine

    network_interfaces
        List of network interfaces and properties

    parent
        Parent object reference

    .. code-block: bash

        interfaces:
          adapter: 'Network adapter 1'
          name: vlan100
          switch_type: distributed or standard
          adapter_type: vmxnet3 or vmxnet, vmxnet2, vmxnet3, e1000, e1000e
          mac: '00:11:22:33:44:55'
    '''
    network_specs = []
    nics_settings = []
    keys = range(-4000, -4050, -1)
    if network_interfaces:
        devs = [inter['adapter'] for inter in network_interfaces]
        log.trace('Creating network interfaces %s', devs)
        for interface, key in zip(network_interfaces, keys):
            network_spec = _apply_network_adapter_config(
                key, interface['name'],
                interface['adapter_type'],
                interface['switch_type'],
                network_adapter_label=interface['adapter'],
                operation='add',
                connectable=interface['connectable'] if 'connectable' in interface else None,
                mac=interface['mac'], parent=parent)
            network_specs.append(network_spec)
            if 'mapping' in interface:
                adapter_mapping = _set_network_adapter_mapping(
                    interface['mapping']['domain'],
                    interface['mapping']['gateway'],
                    interface['mapping']['ip_addr'],
                    interface['mapping']['subnet_mask'],
                    interface['mac'])
                nics_settings.append(adapter_mapping)
    return (network_specs, nics_settings)
Returns a list of vim.vm.device.VirtualDeviceSpec objects representing
    the interfaces to be created for a virtual machine

    network_interfaces
        List of network interfaces and properties

    parent
        Parent object reference

    .. code-block: bash

        interfaces:
          adapter: 'Network adapter 1'
          name: vlan100
          switch_type: distributed or standard
          adapter_type: vmxnet3 or vmxnet, vmxnet2, vmxnet3, e1000, e1000e
          mac: '00:11:22:33:44:55'