nerm/src/PSSailpoint.NERM/Model/ProfileTypeAttributes.ps1
|
# # NERM API # The NERM API accesss and modifies resources in your environment. # Version: 1.0.0 # Generated by OpenAPI Generator: https://openapi-generator.tech # <# .SYNOPSIS No summary available. .DESCRIPTION No description available. .PARAMETER Count How many ne attribute records exist .PARAMETER Records No description available. .OUTPUTS ProfileTypeAttributes<PSCustomObject> #> function Initialize-NERMProfileTypeAttributes { [CmdletBinding()] Param ( [Parameter(ValueFromPipelineByPropertyName = $true)] [System.Nullable[Int32]] ${Count}, [Parameter(ValueFromPipelineByPropertyName = $true)] [PSCustomObject[]] ${Records} ) Process { 'Creating PSCustomObject: PSSailpoint.NERM => NERMProfileTypeAttributes' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $PSO = [PSCustomObject]@{ "count" = ${Count} "records" = ${Records} } return $PSO } } <# .SYNOPSIS Convert from JSON to ProfileTypeAttributes<PSCustomObject> .DESCRIPTION Convert from JSON to ProfileTypeAttributes<PSCustomObject> .PARAMETER Json Json object .OUTPUTS ProfileTypeAttributes<PSCustomObject> #> function ConvertFrom-NERMJsonToProfileTypeAttributes { Param( [AllowEmptyString()] [string]$Json ) Process { 'Converting JSON to PSCustomObject: PSSailpoint.NERM => NERMProfileTypeAttributes' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $JsonParameters = ConvertFrom-Json -InputObject $Json # check if Json contains properties not defined in NERMProfileTypeAttributes $AllProperties = ("count", "records") 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 "count"))) { #optional property not found $Count = $null } else { $Count = $JsonParameters.PSobject.Properties["count"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "records"))) { #optional property not found $Records = $null } else { $Records = $JsonParameters.PSobject.Properties["records"].value } $PSO = [PSCustomObject]@{ "count" = ${Count} "records" = ${Records} } return $PSO } } |