Factory<TParam1,TParam2,TInstance> Delegate
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Creates an instance of TInstance
.
public delegate TInstance Factory<in TParam1,in TParam2,out TInstance>(TParam1 param1, TParam2 param2);
type Factory<'TParam1, 'TParam2, 'Instance> = delegate of 'TParam1 * 'TParam2 -> 'Instance
Public Delegate Function Factory(Of In TParam1, In TParam2, Out TInstance)(param1 As TParam1, param2 As TParam2) As TInstance
Type Parameters
- TParam1
The first parameter type.
This type parameter is contravariant. That is, you can use either the type you specified or any type that is less derived. For more information about covariance and contravariance, see Covariance and Contravariance in Generics.- TParam2
The second parameter type.
This type parameter is contravariant. That is, you can use either the type you specified or any type that is less derived. For more information about covariance and contravariance, see Covariance and Contravariance in Generics.- TInstance
The instance type.
This type parameter is covariant. That is, you can use either the type you specified or any type that is more derived. For more information about covariance and contravariance, see Covariance and Contravariance in Generics.Parameters
- param1
- TParam1
- param2
- TParam2
Return Value
TInstance
The instance.