Model/MicrosoftODataEdmIEdmType.ps1
# # Portal Api # Portal Api HTTP API V1 # Version: v1 # Generated by OpenAPI Generator: https://openapi-generator.tech # <# .SYNOPSIS No summary available. .DESCRIPTION No description available. .PARAMETER TypeKind No description available. .OUTPUTS MicrosoftODataEdmIEdmType<PSCustomObject> #> function Initialize-ElementsMicrosoftODataEdmIEdmType { [CmdletBinding()] Param ( [Parameter(ValueFromPipelineByPropertyName = $true)] [ValidateSet("0", "1", "2", "3", "4", "5", "6", "7", "8", "9")] [PSCustomObject] ${TypeKind} ) Process { 'Creating PSCustomObject: Elements.Client => ElementsMicrosoftODataEdmIEdmType' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $PSO = [PSCustomObject]@{ "typeKind" = ${TypeKind} } return $PSO } } <# .SYNOPSIS Convert from JSON to MicrosoftODataEdmIEdmType<PSCustomObject> .DESCRIPTION Convert from JSON to MicrosoftODataEdmIEdmType<PSCustomObject> .PARAMETER Json Json object .OUTPUTS MicrosoftODataEdmIEdmType<PSCustomObject> #> function ConvertFrom-ElementsJsonToMicrosoftODataEdmIEdmType { Param( [AllowEmptyString()] [string]$Json ) Process { 'Converting JSON to PSCustomObject: Elements.Client => ElementsMicrosoftODataEdmIEdmType' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $JsonParameters = ConvertFrom-Json -InputObject $Json # check if Json contains properties not defined in ElementsMicrosoftODataEdmIEdmType $AllProperties = ("typeKind") 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 "typeKind"))) { #optional property not found $TypeKind = $null } else { $TypeKind = $JsonParameters.PSobject.Properties["typeKind"].value } $PSO = [PSCustomObject]@{ "typeKind" = ${TypeKind} } return $PSO } } |