C# Class LinFu.IoC.Scope

Represents a class that keeps track of all the disposable objects created within a service container and disposes them when the scope itself has been disposed.
Inheritance: IScope, IPostProcessor, IInitialize
Show file Open project: philiplaureano/LinFu

Public Methods

Method Description
Dispose ( ) : void

Disposes the services that have been created while the scope has been active.

Initialize ( IServiceContainer source ) : void

Inserts the scope into the target container.

PostProcess ( IServiceRequestResult result ) : void

Monitors the IServiceContainer for any services that are created and automatically disposes them once the IScope is disposed.

Method Details

Dispose() public method

Disposes the services that have been created while the scope has been active.
public Dispose ( ) : void
return void

Initialize() public method

Inserts the scope into the target container.
public Initialize ( IServiceContainer source ) : void
source IServiceContainer The container that will hold the scope instance.
return void

PostProcess() public method

Monitors the IServiceContainer for any services that are created and automatically disposes them once the IScope is disposed.
public PostProcess ( IServiceRequestResult result ) : void
result IServiceRequestResult The that describes the service being instantiated.
return void