internal/v1.0/Remove-MgSubSite.ps1
<# .Synopsis The collection of the sub-sites under this site. .Description The collection of the sub-sites under this site. .Inputs Microsoft.Graph.PowerShell.Models.ISitesIdentity .Outputs System.Boolean .Notes Please use Get-Help -Online. .Link https://docs.microsoft.com/en-us/powershell/module/microsoft.graph.sites/remove-mgsubsite #> function Remove-MgSubSite { [OutputType([System.Boolean])] [CmdletBinding(DefaultParameterSetName='Delete2', PositionalBinding=$false, SupportsShouldProcess, ConfirmImpact='Medium')] [Microsoft.Graph.PowerShell.Profile('v1.0')] param( [Parameter(ParameterSetName='Delete2', Mandatory)] [Microsoft.Graph.PowerShell.Category('Path')] [System.String] # key: id of site ${SiteId}, [Parameter(ParameterSetName='Delete2', Mandatory)] [Microsoft.Graph.PowerShell.Category('Path')] [System.String] # key: id of site ${SiteId1}, [Parameter(ParameterSetName='DeleteViaIdentity2', Mandatory, ValueFromPipeline)] [Microsoft.Graph.PowerShell.Category('Path')] [Microsoft.Graph.PowerShell.Models.ISitesIdentity] # Identity Parameter # To construct, please use Get-Help -Online and see NOTES section for INPUTOBJECT properties and create a hash table. ${InputObject}, [Parameter()] [Microsoft.Graph.PowerShell.Category('Header')] [System.String] # ETag ${IfMatch}, [Parameter(DontShow)] [Microsoft.Graph.PowerShell.Category('Runtime')] [System.Management.Automation.SwitchParameter] # Wait for .NET debugger to attach ${Break}, [Parameter(DontShow)] [ValidateNotNull()] [Microsoft.Graph.PowerShell.Category('Runtime')] [Microsoft.Graph.PowerShell.Runtime.SendAsyncStep[]] # SendAsync Pipeline Steps to be appended to the front of the pipeline ${HttpPipelineAppend}, [Parameter(DontShow)] [ValidateNotNull()] [Microsoft.Graph.PowerShell.Category('Runtime')] [Microsoft.Graph.PowerShell.Runtime.SendAsyncStep[]] # SendAsync Pipeline Steps to be prepended to the front of the pipeline ${HttpPipelinePrepend}, [Parameter()] [Microsoft.Graph.PowerShell.Category('Runtime')] [System.Management.Automation.SwitchParameter] # Returns true when the command succeeds ${PassThru}, [Parameter(DontShow)] [Microsoft.Graph.PowerShell.Category('Runtime')] [System.Uri] # The URI for the proxy server to use ${Proxy}, [Parameter(DontShow)] [ValidateNotNull()] [Microsoft.Graph.PowerShell.Category('Runtime')] [System.Management.Automation.PSCredential] # Credentials for a proxy server to use for the remote call ${ProxyCredential}, [Parameter(DontShow)] [Microsoft.Graph.PowerShell.Category('Runtime')] [System.Management.Automation.SwitchParameter] # Use the default credentials for the proxy ${ProxyUseDefaultCredentials} ) begin { try { $outBuffer = $null if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) { $PSBoundParameters['OutBuffer'] = 1 } $parameterSet = $PSCmdlet.ParameterSetName $mapping = @{ Delete2 = 'Microsoft.Graph.Sites.private\Remove-MgSubSite_Delete2'; DeleteViaIdentity2 = 'Microsoft.Graph.Sites.private\Remove-MgSubSite_DeleteViaIdentity2'; } $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet) $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 } } } |