다음을 통해 공유


DeserializingTypeConverter.ConvertTo Method

Definition

Overloads

ConvertTo(PSObject, Type, IFormatProvider, Boolean)

This method is not implemented - an overload taking a PSObject is implemented instead.

ConvertTo(Object, Type, IFormatProvider, Boolean)

Converts the sourceValue parameter to the destinationType parameter using formatProvider and ignoreCase.

ConvertTo(PSObject, Type, IFormatProvider, Boolean)

This method is not implemented - an overload taking a PSObject is implemented instead.

public:
 override System::Object ^ ConvertTo(System::Management::Automation::PSObject ^ sourceValue, Type ^ destinationType, IFormatProvider ^ formatProvider, bool ignoreCase);
public override object ConvertTo (System.Management.Automation.PSObject sourceValue, Type destinationType, IFormatProvider formatProvider, bool ignoreCase);
override this.ConvertTo : System.Management.Automation.PSObject * Type * IFormatProvider * bool -> obj
Public Overrides Function ConvertTo (sourceValue As PSObject, destinationType As Type, formatProvider As IFormatProvider, ignoreCase As Boolean) As Object

Parameters

sourceValue
PSObject
destinationType
Type
formatProvider
IFormatProvider
ignoreCase
Boolean

Returns

Applies to

ConvertTo(Object, Type, IFormatProvider, Boolean)

Converts the sourceValue parameter to the destinationType parameter using formatProvider and ignoreCase.

public:
 override System::Object ^ ConvertTo(System::Object ^ sourceValue, Type ^ destinationType, IFormatProvider ^ formatProvider, bool ignoreCase);
public override object ConvertTo (object sourceValue, Type destinationType, IFormatProvider formatProvider, bool ignoreCase);
override this.ConvertTo : obj * Type * IFormatProvider * bool -> obj
Public Overrides Function ConvertTo (sourceValue As Object, destinationType As Type, formatProvider As IFormatProvider, ignoreCase As Boolean) As Object

Parameters

sourceValue
Object

The value to convert from.

destinationType
Type

The type to convert to.

formatProvider
IFormatProvider

The format provider to use like in IFormattable's ToString.

ignoreCase
Boolean

True if case should be ignored.

Returns

SourceValue converted to the destinationType parameter using formatProvider and ignoreCase.

Exceptions

If no conversion was possible.

Applies to