Home

Castle Stronghold

IHandler API Document

Contract for the IHandler, which manages an component state and coordinates its creation and destruction (dispatching to activators, lifestyle managers)

Properties

NameTypeDescription
CurrentStateHandlerState Gets the state of the handler
ComponentModelComponentModel Gets the model of the component being managed by this handler.

Events

OnHandlerStateChanged:HandlerStateDelegate(Object source, EventArgs args)

TODO: Document this

ParameterDescription
source Missing documentation
args Missing documentation

Methods

HasCustomParameter(String key) : Boolean

TODO: Document this

ParameterDescription
key

RemoveCustomDependencyValue(String key)

TODO: Document this

ParameterDescription
key

AddCustomDependencyValue(String key, Object value)

Dictionary of String/object used to associate data with a component dependency. For example, if you component SmtpServer depends on host and port, you can add those to this dictionary and the handler will be able to use them.

Quick Note

TODO: Document this

ParameterDescription
key Missing documentation
value Missing documentation

Release(Object instance)

Implementors should dispose the component instance

ParameterDescription
instance

Resolve(CreationContext context) : Object

Implementors should return a valid instance for the component the handler is responsible. It should throw an exception in the case the component can't be created for some reason

ParameterDescription
context Missing documentation

Init(IKernel kernel)

Initializes the handler with a reference to the kernel.

ParameterDescription
kernel

Google
Search WWW Search castleproject.org