vsphere/distributed_virtual_switch_structure.go
func expandDVSCreateSpec(d *schema.ResourceData) types.DVSCreateSpec {
	// Since we are only working with the version string from the product spec,
	// we don't have a separate expander/flattener for it. Just do that here.
	obj := types.DVSCreateSpec{
		ProductInfo: &types.DistributedVirtualSwitchProductSpec{
			Version: d.Get("version").(string),
		},
		ConfigSpec: expandVMwareDVSConfigSpec(d),
	}
	return obj
}
func expandDVSCreateSpec(d *schema.ResourceData) types.DVSCreateSpec {
	// Since we are only working with the version string from the product spec,
	// we don't have a separate expander/flattener for it. Just do that here.
	obj := types.DVSCreateSpec{
		ProductInfo: &types.DistributedVirtualSwitchProductSpec{
			Version: d.Get("version").(string),
		},
		ConfigSpec: expandVMwareDVSConfigSpec(d),
	}
	return obj
}
// expandDVSCreateSpec reads certain ResourceData keys and
// returns a DVSCreateSpec.