Click or drag to resize

DefaultPooledRegistrationPolicyTPooledObjectGet Method

Invoked when an instance of TPooledObject is requested. The policy can invoke getFromPool to retrieve an instance from the pool. Equally, it could decide to ignore the pool, and just return a custom instance.

Namespace:  Autofac.Pooling
Assembly:  Autofac.Pooling (in Autofac.Pooling.dll) Version: 1.0.1+e2b1e849d21d04643649a531a7435392bb1a29cd
Syntax
public virtual TPooledObject Get(
	IComponentContext context,
	IEnumerable<Parameter> parameters,
	Func<TPooledObject> getFromPool
)

Parameters

context
Type: AutofacIComponentContext
The current component context.
parameters
Type: System.Collections.GenericIEnumerableParameter
The set of parameters for the resolve request accessing the pool.
getFromPool
Type: SystemFuncTPooledObject
A callback that will retrieve an item from the underlying pool of objects.

Return Value

Type: TPooledObject

[Missing <returns> documentation for "M:Autofac.Pooling.DefaultPooledRegistrationPolicy`1.Get(Autofac.IComponentContext,System.Collections.Generic.IEnumerable{Autofac.Core.Parameter},System.Func{`0})"]

Implements

IPooledRegistrationPolicyTPooledObjectGet(IComponentContext, IEnumerableParameter, FuncTPooledObject)
See Also