public PSDeploymentWhatIfCmdletParameters(
     DeploymentScopeType scopeType,
     string deploymentName              = null,
     DeploymentMode mode                = DeploymentMode.Incremental,
     string location                    = null,
     string managementGroupId           = null,
     string queryString                 = null,
     string resourceGroupName           = null,
     string templateUri                 = null,
     string templateSpecId              = null,
     string templateParametersUri       = null,
     Hashtable templateObject           = null,
     Hashtable templateParametersObject = null,
     WhatIfResultFormat resultFormat    = WhatIfResultFormat.FullResourcePayloads,
     string[] excludeChangeTypes        = null)
 {
     this.DeploymentName           = deploymentName ?? this.GenerateDeployName();
     this.ScopeType                = scopeType;
     this.Mode                     = mode;
     this.Location                 = location;
     this.ManagementGroupId        = managementGroupId;
     this.QueryString              = queryString;
     this.ResourceGroupName        = resourceGroupName;
     this.TemplateUri              = templateUri;
     this.TemplateParametersUri    = templateParametersUri;
     this.TemplateObject           = templateObject;
     this.TemplateSpecId           = templateSpecId;
     this.TemplateParametersObject = templateParametersObject;
     this.ResultFormat             = resultFormat;
     this.ExcludeChangeTypes       = excludeChangeTypes?
                                     .Select(changeType => changeType.ToLowerInvariant())
                                     .Distinct()
                                     .Select(changeType => (ChangeType)Enum.Parse(typeof(ChangeType), changeType, true));
 }
        internal static string ToSerializedValue(this WhatIfResultFormat value)
        {
            switch (value)
            {
            case WhatIfResultFormat.ResourceIdOnly:
                return("ResourceIdOnly");

            case WhatIfResultFormat.FullResourcePayloads:
                return("FullResourcePayloads");
            }
            return(null);
        }
 public static string ToSerialString(this WhatIfResultFormat value) => value switch
 {