다음을 통해 공유


DeserializingTypeConverter.ConvertFrom Method

Definition

Overloads

ConvertFrom(PSObject, Type, IFormatProvider, Boolean)

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

ConvertFrom(Object, Type, IFormatProvider, Boolean)

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

ConvertFrom(PSObject, Type, IFormatProvider, Boolean)

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

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

Parameters

sourceValue
PSObject

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

The sourceValue parameter converted to the destinationType parameter using formatProvider and ignoreCase.

Exceptions

If no conversion was possible.

Applies to

ConvertFrom(Object, Type, IFormatProvider, Boolean)

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

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

Parameters

sourceValue
Object
destinationType
Type
formatProvider
IFormatProvider
ignoreCase
Boolean

Returns

Applies to