ConversionAttempt Delegate

Represents a delegate for a type conversion attempt. A conversion can be registered by the RegisterConversion extension method.


Namespace: KGySoft.CoreLibraries
Assembly: KGySoft.CoreLibraries (in KGySoft.CoreLibraries.dll) Version: 8.0.0
public delegate bool ConversionAttempt(
	Object obj,
	Type targetType,
	CultureInfo? culture,
	out Object result


obj  Object
The source object to convert.
targetType  Type
The desired type of the result parameter if the return value is .
culture  CultureInfo
The used culture for the conversion. If , then the conversion must use culture invariant conversion.
result  Object
The result if the return value is .

Return Value

if the conversion was successful; otherwise, .

See Also