Model/PublicIdentitiesNestedCompositeEntry.ps1
|
# # SailPoint Identity Security API - Public Identities # Use these APIs to interact with the SailPoint Identity Security platform to achieve repeatable, automated processes with greater scalability. We encourage you to join the SailPoint Developer Community forum at https://developer.sailpoint.com/discuss to connect with other developers using our APIs. # Version: v1 # Generated by OpenAPI Generator: https://openapi-generator.tech # <# .SYNOPSIS No summary available. .DESCRIPTION A COMPOSITE query entry that nests another querySet. .PARAMETER QueryType Entry type discriminator. Must be COMPOSITE for nested query sets. .PARAMETER QuerySet Nested query set for this COMPOSITE entry. .OUTPUTS PublicIdentitiesNestedCompositeEntry<PSCustomObject> #> function Initialize-PublicIdentitiesNestedCompositeEntry { [CmdletBinding()] Param ( [Parameter(ValueFromPipelineByPropertyName = $true)] [ValidateSet("COMPOSITE")] [String] ${QueryType}, [Parameter(ValueFromPipelineByPropertyName = $true)] [PSCustomObject] ${QuerySet} ) Process { 'Creating PSCustomObject: PSSailpoint.PublicIdentities => PublicIdentitiesNestedCompositeEntry' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug if (!$QueryType) { throw "invalid value for 'QueryType', 'QueryType' cannot be null." } if (!$QuerySet) { throw "invalid value for 'QuerySet', 'QuerySet' cannot be null." } $PSO = [PSCustomObject]@{ "queryType" = ${QueryType} "querySet" = ${QuerySet} } return $PSO } } <# .SYNOPSIS Convert from JSON to PublicIdentitiesNestedCompositeEntry<PSCustomObject> .DESCRIPTION Convert from JSON to PublicIdentitiesNestedCompositeEntry<PSCustomObject> .PARAMETER Json Json object .OUTPUTS PublicIdentitiesNestedCompositeEntry<PSCustomObject> #> function ConvertFrom-JsonToPublicIdentitiesNestedCompositeEntry { Param( [AllowEmptyString()] [string]$Json ) Process { 'Converting JSON to PSCustomObject: PSSailpoint.PublicIdentities => PublicIdentitiesNestedCompositeEntry' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $JsonParameters = ConvertFrom-Json -InputObject $Json # check if Json contains properties not defined in PublicIdentitiesNestedCompositeEntry $AllProperties = ("queryType", "querySet") foreach ($name in $JsonParameters.PsObject.Properties.Name) { if (!($AllProperties.Contains($name))) { throw "Error! JSON key '$name' not found in the properties: $($AllProperties)" } } If ([string]::IsNullOrEmpty($Json) -or $Json -eq "{}") { # empty json throw "Error! Empty JSON cannot be serialized due to the required property 'queryType' missing." } if (!([bool]($JsonParameters.PSobject.Properties.name -match "queryType"))) { throw "Error! JSON cannot be serialized due to the required property 'queryType' missing." } else { $QueryType = $JsonParameters.PSobject.Properties["queryType"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "querySet"))) { throw "Error! JSON cannot be serialized due to the required property 'querySet' missing." } else { $QuerySet = $JsonParameters.PSobject.Properties["querySet"].value } $PSO = [PSCustomObject]@{ "queryType" = ${QueryType} "querySet" = ${QuerySet} } return $PSO } } |