exports/New-NmeHostPoolControlUpUpdateModel.ps1


# ----------------------------------------------------------------------------------
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.10.8, generator: @autorest/powershell@4.0.752)
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# ----------------------------------------------------------------------------------

<#
.Synopsis
Create an in-memory object for HostPoolControlUpUpdate.
.Description
Create an in-memory object for HostPoolControlUpUpdate.

#>

function New-NmeHostPoolControlUpUpdateModel {
[OutputType([NmePowershell.Models.HostPoolControlUpUpdate])]
[CmdletBinding(PositionalBinding=$false)]
param(
    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.Boolean]
    ${AuthenticationDefault},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.String]
    ${AuthenticationValue},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.String]
    ${DnsZone},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.String]
    ${Folder},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.Boolean]
    ${IsEnabled},

    [Parameter()]
    [NmePowershell.PSArgumentCompleterAttribute("0", "1", "2", "3", "4", "5", "6")]
    [NmePowershell.Category('Body')]
    [System.Int32[]]
    ${MaintenanceWindowDays},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.Int32]
    ${MaintenanceWindowDurationMinutes},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.Boolean]
    ${MaintenanceWindowEnabled},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.Int32]
    ${MaintenanceWindowStartHour},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.Int32]
    ${MaintenanceWindowStartMinutes},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.String]
    ${MaintenanceWindowTimezoneId},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.Int32]
    ${MaxJobs},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.String[]]
    ${Monitors},

    [Parameter()]
    [NmePowershell.PSArgumentCompleterAttribute("Disabled", "Default", "Custom")]
    [NmePowershell.Category('Body')]
    [System.String]
    ${RegistrationType},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.String]
    ${RegistrationValue},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.String]
    ${SecondaryDnsZone},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.Boolean]
    ${SecondaryEnabled},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.String]
    ${SecondaryFolder},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.String[]]
    ${SecondaryMonitors},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.String]
    ${SecondarySite},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.String]
    ${Site},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.Boolean]
    ${UnjoinHosts},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.Int32]
    ${UnjoinHostsDelayInDays},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.Boolean]
    ${UseDefault},

    [Parameter()]
    [NmePowershell.Category('Body')]
    [System.String]
    ${Version}
)

begin {
    try {
        $outBuffer = $null
        if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) {
            $PSBoundParameters['OutBuffer'] = 1
        }
        $parameterSet = $PSCmdlet.ParameterSetName
        
        $testPlayback = $false
        $PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('NmePowershell.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }

        $mapping = @{
            __AllParameterSets = 'NerdioManagerPowerShell.custom\New-NmeHostPoolControlUpUpdateModel';
        }
        $cmdInfo = Get-Command -Name $mapping[$parameterSet]
        [NmePowershell.Runtime.MessageAttributeHelper]::ProcessCustomAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
        [NmePowershell.Runtime.MessageAttributeHelper]::ProcessPreviewMessageAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
        $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
        if ($wrappedCmd -eq $null) {
            $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Function)
        }
        $scriptCmd = {& $wrappedCmd @PSBoundParameters}
        $steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
        $steppablePipeline.Begin($PSCmdlet)
    } catch {

        throw
    }
}

process {
    try {
        $steppablePipeline.Process($_)
    } catch {

        throw
    }

}
end {
    try {
        $steppablePipeline.End()

    } catch {

        throw
    }
} 
}