vSphere PowerCLI Reference

Get-VIProperty

Synopsis

Retrieves extended object properties.

Syntax

Get-VIProperty [[-Name] <String[]>] [[-ObjectType] <String[]>] [-DeclaredOnly] [<CommonParameters>]

Related Commands

Online version
Remove-VIProperty
New-VIProperty

Detailed Description

Retrieves the extended properties and filters them by using the provided cmdlet parameters.

Parameters

NameTypeDescriptionRequired?Pipeline InputDefault Value
NameString[]Specify the names of the extended properties you want to retrieve.falsefalse
ObjectTypeString[]Specify the object types for which you want to retrieve extended properties.falsefalse
DeclaredOnlySwitchParameterIndicate that you want to retrieve only the extended properties that have been directly defined for the specified object types.falsefalse

Return Type

VIProperty

Notes

Examples

-------------- Example 1 --------------

Get-VIProperty -Name "property*"

Retrieve all custom properties that match the specified name pattern.

-------------- Example 2 --------------

Get-VIProperty -ObjectType 'VirtualMachine'

Retrieve all custom properties for the specified object type.

-------------- Example 3 --------------

Get-VIProperty -ObjectType 'VirtualMachine' -DeclaredOnly

Retrieve all custom properties for the specified object type that are not inherited.


Copyright © 1998 - 2011 VMware, Inc. All rights reserved.