Implement this interface for two type to provide auto-discovered converters to be used when fuzzy-duck-typing.
More...
|
| T1 | Convert (T2 input) |
| | Convert an object of type T2 to T1.
|
| T2 | Convert (T1 input) |
| | Convert an object of type T1 to T2.
|
| bool | CanConvert (Type t1, Type t2) |
| | Should return true when this converter can convert between t1 and t2.
|
|
|
bool | IsInitialised [get] |
| | Should return true if the converter can be used later. For converters which rely on reflection, this is a double-check that the required underlying method has been located (which may not be the case in a trimmed executable)
|
Implement this interface for two type to provide auto-discovered converters to be used when fuzzy-duck-typing.
- Template Parameters
-
| T1 | Type to convert from or to |
| T2 | Type to convert to or from |
◆ Convert() [1/2]
Convert an object of type T1 to T2.
- Parameters
-
- Returns
- Converted value, as implemented by the converter
◆ Convert() [2/2]
Convert an object of type T2 to T1.
- Parameters
-
- Returns
- Converted value, as implemented by the converter
The documentation for this interface was generated from the following file:
- source/Utils/PeanutButter.DuckTyping/AutoConversion/IConverter.cs