Scripts/get-SCSMProjectionComponent.ps1

1
2
3
4
5
6
7
8
9
10
11
12
13
[CmdletBinding()]
param (
    [Parameter(Mandatory=$true,ValueFromPipeline=$true)]$projection
    )
Process
{
    if ( $projection.__base -isnot "Microsoft.EnterpriseManagement.Configuration.ManagementPackTypeProjection" )
    {
        throw "$projection is not a projection"
    }
    ,$projection.ComponentCollection
}