vsphere/distributed_port_group_structure.go
func flattenVMwareDVSPortgroupPolicy(d *schema.ResourceData, obj *types.VMwareDVSPortgroupPolicy) error {
	d.Set("block_override_allowed", obj.BlockOverrideAllowed)
	d.Set("shaping_override_allowed", obj.ShapingOverrideAllowed)
	d.Set("live_port_moving_allowed", obj.LivePortMovingAllowed)
	d.Set("port_config_reset_at_disconnect", obj.PortConfigResetAtDisconnect)
	d.Set("vlan_override_allowed", obj.VlanOverrideAllowed)
	d.Set("uplink_teaming_override_allowed", obj.UplinkTeamingOverrideAllowed)
	d.Set("security_policy_override_allowed", obj.SecurityPolicyOverrideAllowed)

	structure.SetBoolPtr(d, "network_resource_pool_override_allowed", obj.NetworkResourcePoolOverrideAllowed)
	structure.SetBoolPtr(d, "traffic_filter_override_allowed", obj.TrafficFilterOverrideAllowed)
	structure.SetBoolPtr(d, "netflow_override_allowed", obj.IpfixOverrideAllowed)
	return nil
}
func flattenVMwareDVSPortgroupPolicy(d *schema.ResourceData, obj *types.VMwareDVSPortgroupPolicy) error {
	d.Set("block_override_allowed", obj.BlockOverrideAllowed)
	d.Set("shaping_override_allowed", obj.ShapingOverrideAllowed)
	d.Set("live_port_moving_allowed", obj.LivePortMovingAllowed)
	d.Set("port_config_reset_at_disconnect", obj.PortConfigResetAtDisconnect)
	d.Set("vlan_override_allowed", obj.VlanOverrideAllowed)
	d.Set("uplink_teaming_override_allowed", obj.UplinkTeamingOverrideAllowed)
	d.Set("security_policy_override_allowed", obj.SecurityPolicyOverrideAllowed)

	structure.SetBoolPtr(d, "network_resource_pool_override_allowed", obj.NetworkResourcePoolOverrideAllowed)
	structure.SetBoolPtr(d, "traffic_filter_override_allowed", obj.TrafficFilterOverrideAllowed)
	structure.SetBoolPtr(d, "netflow_override_allowed", obj.IpfixOverrideAllowed)
	return nil
}
// flattenVMwareDVSPortgroupPolicy reads various fields from a
// VMwareDVSPortgroupPolicy into the passed in ResourceData.