Model/DetailedDecisionSummary.ps1
|
# # Identity Security Cloud API - Next Generation Certification Campaigns # Use these APIs to interact with the Identity Security Cloud 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 No description available. .PARAMETER EntitlementDecisions No description available. .PARAMETER AccessProfileDecisions No description available. .PARAMETER RoleDecisions No description available. .OUTPUTS DetailedDecisionSummary<PSCustomObject> #> function Initialize-DetailedDecisionSummary { [CmdletBinding()] Param ( [Parameter(ValueFromPipelineByPropertyName = $true)] [PSCustomObject] ${EntitlementDecisions}, [Parameter(ValueFromPipelineByPropertyName = $true)] [PSCustomObject] ${AccessProfileDecisions}, [Parameter(ValueFromPipelineByPropertyName = $true)] [PSCustomObject] ${RoleDecisions} ) Process { 'Creating PSCustomObject: PSSailpoint.GovCertification => DetailedDecisionSummary' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $PSO = [PSCustomObject]@{ "entitlementDecisions" = ${EntitlementDecisions} "accessProfileDecisions" = ${AccessProfileDecisions} "roleDecisions" = ${RoleDecisions} } return $PSO } } <# .SYNOPSIS Convert from JSON to DetailedDecisionSummary<PSCustomObject> .DESCRIPTION Convert from JSON to DetailedDecisionSummary<PSCustomObject> .PARAMETER Json Json object .OUTPUTS DetailedDecisionSummary<PSCustomObject> #> function ConvertFrom-JsonToDetailedDecisionSummary { Param( [AllowEmptyString()] [string]$Json ) Process { 'Converting JSON to PSCustomObject: PSSailpoint.GovCertification => DetailedDecisionSummary' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $JsonParameters = ConvertFrom-Json -InputObject $Json # check if Json contains properties not defined in DetailedDecisionSummary $AllProperties = ("entitlementDecisions", "accessProfileDecisions", "roleDecisions") foreach ($name in $JsonParameters.PsObject.Properties.Name) { if (!($AllProperties.Contains($name))) { throw "Error! JSON key '$name' not found in the properties: $($AllProperties)" } } if (!([bool]($JsonParameters.PSobject.Properties.name -match "entitlementDecisions"))) { #optional property not found $EntitlementDecisions = $null } else { $EntitlementDecisions = $JsonParameters.PSobject.Properties["entitlementDecisions"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "accessProfileDecisions"))) { #optional property not found $AccessProfileDecisions = $null } else { $AccessProfileDecisions = $JsonParameters.PSobject.Properties["accessProfileDecisions"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "roleDecisions"))) { #optional property not found $RoleDecisions = $null } else { $RoleDecisions = $JsonParameters.PSobject.Properties["roleDecisions"].value } $PSO = [PSCustomObject]@{ "entitlementDecisions" = ${EntitlementDecisions} "accessProfileDecisions" = ${AccessProfileDecisions} "roleDecisions" = ${RoleDecisions} } return $PSO } } |