NetboxPS/Functions/DCIM/Interfaces/Get-NetboxDCIMInterfaceConnection.ps1

46 lines
1.3 KiB
PowerShell
Raw Normal View History

<#
2020-03-23 12:18:01 -04:00
.NOTES
===========================================================================
Created with: SAPIEN Technologies, Inc., PowerShell Studio 2020 v5.7.172
Created on: 3/23/2020 12:10
Created by: Claussen
Organization: NEOnet
Filename: Get-NetboxDCIMInterfaceConnection.ps1
===========================================================================
.DESCRIPTION
A description of the file.
#>
function Get-NetboxDCIMInterfaceConnection {
[CmdletBinding()]
[OutputType([pscustomobject])]
param
(
[uint16]$Limit,
2020-03-23 12:18:01 -04:00
[uint16]$Offset,
2020-03-23 12:18:01 -04:00
[uint16]$Id,
2020-03-23 12:18:01 -04:00
[object]$Connection_Status,
2020-03-23 12:18:01 -04:00
[uint16]$Site,
2020-03-23 12:18:01 -04:00
[uint16]$Device,
2020-03-23 12:18:01 -04:00
[switch]$Raw
)
2020-03-23 12:18:01 -04:00
if ($null -ne $Connection_Status) {
$PSBoundParameters.Connection_Status = ValidateDCIMChoice -ProvidedValue $Connection_Status -InterfaceConnectionStatus
}
2020-03-23 12:18:01 -04:00
$Segments = [System.Collections.ArrayList]::new(@('dcim', 'interface-connections'))
2020-03-23 12:18:01 -04:00
$URIComponents = BuildURIComponents -URISegments $Segments.Clone() -ParametersDictionary $PSBoundParameters -SkipParameterByName 'Raw'
2020-03-23 12:18:01 -04:00
$URI = BuildNewURI -Segments $URIComponents.Segments -Parameters $URIComponents.Parameters
2020-03-23 12:18:01 -04:00
InvokeNetboxRequest -URI $URI -Raw:$Raw
}