PSObjectTypeDescriptionProvider.GetTypeDescriptor(Type, Object) Method

Definition

Retrieves a PSObjectTypeDescriptor to provide information about the properties for an object of the type PSObject.

public:
 override System::ComponentModel::ICustomTypeDescriptor ^ GetTypeDescriptor(Type ^ objectType, System::Object ^ instance);
public override System.ComponentModel.ICustomTypeDescriptor GetTypeDescriptor (Type objectType, object instance);
override this.GetTypeDescriptor : Type * obj -> System.ComponentModel.ICustomTypeDescriptor
Public Overrides Function GetTypeDescriptor (objectType As Type, instance As Object) As ICustomTypeDescriptor

Parameters

objectType
Type

The type of object for which to retrieve the type descriptor. If this parameter is not noll and is not the PSObject, the return of this method will be null.

instance
Object

An instance of the type. If instance is null or has a type other than PSObject, this method returns null.

Returns

An ICustomTypeDescriptor that can provide property information for the type PSObject, or null if objectType is not null, but has a type other than PSObject.

Applies to