private/write/Write-Instance.ps1
function Write-Instance { [CmdletBinding(PositionalBinding = $true)] param( [Parameter(Mandatory = $true)] $Instances ) $tableFormat = @( @{Expression = { $_.InstanceId }; Label = 'Instance'; Width = 21 }, @{Expression = { $_.Status }; Label = 'Status' ; Width = 9 }, @{Expression = { $_.PlatformType }; Label = 'Platform'; Width = 12 }, @{Expression = { $_.LaunchTimeMessage }; Label = 'Launch'; Width = 12 }, @{Expression = { $_.InstanceName }; Label = 'Name' } ) return $Instances | Sort-Object -Property InstanceName | Format-Table -Property $tableFormat } |