Click or drag to resize

ResolvedParameterCanSupplyValue Method

Returns true if the parameter is able to provide a value to a particular site.

Namespace:  Autofac.Core
Assembly:  Autofac (in Autofac.dll) Version: 6.0.0+39696a967e8826f7f1ebc8c1ff4523c9dd75abe0
Syntax
public override bool CanSupplyValue(
	ParameterInfo pi,
	IComponentContext context,
	out Func<Object> valueProvider
)

Parameters

pi
Type: System.ReflectionParameterInfo
Constructor, method, or property-mutator parameter.
context
Type: AutofacIComponentContext
The component context in which the value is being provided.
valueProvider
Type: SystemFuncObject
If the result is true, the valueProvider parameter will be set to a function that will lazily retrieve the parameter value. If the result is false, will be set to null.

Return Value

Type: Boolean
True if a value can be supplied; otherwise, false.
See Also