Model/NodesSdnZonesBridgesInner.ps1
|
# # Proxmox PowerShell VE # Generated module to access all Proxmox VE Api Endpoints. This module has been generated from the proxmox api description v. 9.1.1 # Version: 9.1.1 # Contact: mail@timo-wolf.de # Generated by OpenAPI Generator: https://openapi-generator.tech # <# .SYNOPSIS No summary available. .DESCRIPTION No description available. .PARAMETER VlanFiltering No description available. .PARAMETER Name No description available. .PARAMETER Ports No description available. .OUTPUTS NodesSdnZonesBridgesInner<PSCustomObject> #> function Initialize-PVENodesSdnZonesBridgesInner { [CmdletBinding()] Param ( [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${VlanFiltering}, [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${Name}, [Parameter(ValueFromPipelineByPropertyName = $true)] [PSCustomObject[]] ${Ports} ) Process { 'Creating PSCustomObject: ProxmoxPVE => PVENodesSdnZonesBridgesInner' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $DisplayNameMapping =@{ "VlanFiltering"="vlan_filtering"; "Name"="name"; "Ports"="ports" } $OBJ = @{} foreach($parameter in $PSBoundParameters.Keys){ #If Specifield map the Display name back $OBJ.($DisplayNameMapping.($parameter)) = $PSBoundParameters.$parameter } $PSO = [PSCustomObject]$OBJ return $PSO } } <# .SYNOPSIS Convert from JSON to NodesSdnZonesBridgesInner<PSCustomObject> .DESCRIPTION Convert from JSON to NodesSdnZonesBridgesInner<PSCustomObject> .PARAMETER Json Json object .OUTPUTS NodesSdnZonesBridgesInner<PSCustomObject> #> function ConvertFrom-PVEJsonToNodesSdnZonesBridgesInner { Param( [AllowEmptyString()] [string]$Json ) Process { 'Converting JSON to PSCustomObject: ProxmoxPVE => PVENodesSdnZonesBridgesInner' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $JsonParameters = ConvertFrom-Json -InputObject $Json # check if Json contains properties not defined in PVENodesSdnZonesBridgesInner $AllProperties = ("vlan_filtering", "name", "ports") 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 "vlan_filtering"))) { #optional property not found $VlanFiltering = $null } else { $VlanFiltering = $JsonParameters.PSobject.Properties["vlan_filtering"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "name"))) { #optional property not found $Name = $null } else { $Name = $JsonParameters.PSobject.Properties["name"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "ports"))) { #optional property not found $Ports = $null } else { $Ports = $JsonParameters.PSobject.Properties["ports"].value } $PSO = [PSCustomObject]@{ "vlan_filtering" = ${VlanFiltering} "name" = ${Name} "ports" = ${Ports} } return $PSO } } |