| IExportProviderGetExportedValueOrDefaultT Method |
Gets the exported object with the specified contract name.
Namespace:
TomsToolbox.Composition
Assembly:
TomsToolbox.Composition (in TomsToolbox.Composition.dll)
Syntax T GetExportedValueOrDefault<T>(
string? contractName = null
)
where T : class
Function GetExportedValueOrDefault(Of T As Class) (
Optional contractName As String = Nothing
) As T
Parameters
- contractName (Optional)
- Type: SystemString
Name of the contract.
Type Parameters
- T
- The type of the object.
Return Value
Type:
T
The object, or null if no such export exists.
See Also