C# Class Composable.Windsor.KeyReplacementHandlerSelector

When multiple registrations to the same type are made this HandlerSelector returns the service registered with the 'replacementKey' when the container is asked for a service with 'originalKey' Use it by adding it to the container at wire-up with container.Kernel.AddHandlerSelector(new KeyReplacementHandlerSelector(typeof([ComponentType]),"originalKey", "replacementKey"));
Inheritance: IHandlerSelector
Afficher le fichier Open project: mlidbom/Composable.Monolithic

Méthodes publiques

Méthode Description
HasOpinionAbout ( string key, Type service ) : bool
KeyReplacementHandlerSelector ( Type serviceType, string originalKey, string replacementKey ) : System
SelectHandler ( string key, Type service, IHandler handlers ) : IHandler

Method Details

HasOpinionAbout() public méthode

public HasOpinionAbout ( string key, Type service ) : bool
key string
service System.Type
Résultat bool

KeyReplacementHandlerSelector() public méthode

public KeyReplacementHandlerSelector ( Type serviceType, string originalKey, string replacementKey ) : System
serviceType System.Type
originalKey string
replacementKey string
Résultat System

SelectHandler() public méthode

public SelectHandler ( string key, Type service, IHandler handlers ) : IHandler
key string
service System.Type
handlers IHandler
Résultat IHandler