| FactoryCreateFirstT Method (Object) |
Creates an instance of the specified type depending on the
ComponentAttribute.
If multiple implementations are available, the
Factory will prefer the implementation with the highest priority.
Namespace:
Cauldron.Activator
Assembly:
Cauldron.Activator (in Cauldron.Activator.dll) Version: 3.2.0.2
Syntax public static T CreateFirst<T>(
params Object[] parameters
)
where T : class
Public Shared Function CreateFirst(Of T As Class) (
ParamArray parameters As Object()
) As T
public:
generic<typename T>
where T : ref class
static T CreateFirst(
... array<Object^>^ parameters
)
Parameters
- parameters
- Type: SystemObject
An array of arguments that match in number, order, and type the parameters of the
constructor to invoke. If args is an empty array or null, the constructor that takes no
parameters (the default constructor) is invoked.
Type Parameters
- T
- The Type that contract name derives from
Return Value
Type:
TA reference to the newly created object.
Exceptions See Also