Packagepotomac.inject
Interfacepublic interface ILinker extends IScoper

An ILinker links a injectable class or interface to an implementation or implementation provider.



Public Methods
 MethodDefined By
 Inherited
Sets the injection binding as a singleton.
IScoper
  
toClass(clazz:Class):IScoper
Links an injectable to the given class.
ILinker
  
toInstance(instance:Object):void
Links the injectable to the given instance.
ILinker
  
toProvider(providerClass:Class):IScoper
Links an injectable to the given provider.
ILinker
  
Links an injectable to the given provider.
ILinker
Method Detail
toClass()method
public function toClass(clazz:Class):IScoper

Links an injectable to the given class. Instances of the given class will be created to satisfy injection requests.

Parameters

clazz:Class — class to link to injectable

Returns
IScoper — an IScoper to allow for scope refinement
toInstance()method 
public function toInstance(instance:Object):void

Links the injectable to the given instance.

Parameters

instance:Object — instance to link to the injectable

toProvider()method 
public function toProvider(providerClass:Class):IScoper

Links an injectable to the given provider.

Parameters

providerClass:Class — provider class to request injection instance from

Returns
IScoper — an IScoper to allow for scope refinement
toProviderInstance()method 
public function toProviderInstance(providerInstance:IProvider):IScoper

Links an injectable to the given provider.

Parameters

providerInstance:IProvider — provider to request injection instance from

Returns
IScoper — an IScoper to allow for scope refinement