| Package | potomac.inject |
| Interface | public interface ILinker extends IScoper |
| Method | Defined By | ||
|---|---|---|---|
![]() | asSingleton():void
Sets the injection binding as a singleton. | 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 | ||
| toClass | () | method |
public function toClass(clazz:Class):IScoperLinks 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
|
IScoper — an IScoper to allow for scope refinement
|
| toInstance | () | method |
public function toInstance(instance:Object):voidLinks the injectable to the given instance.
Parameters
instance:Object — instance to link to the injectable
|
| toProvider | () | method |
public function toProvider(providerClass:Class):IScoperLinks an injectable to the given provider.
Parameters
providerClass:Class — provider class to request injection instance from
|
IScoper — an IScoper to allow for scope refinement
|
| toProviderInstance | () | method |
public function toProviderInstance(providerInstance:IProvider):IScoperLinks an injectable to the given provider.
Parameters
providerInstance:IProvider — provider to request injection instance from
|
IScoper — an IScoper to allow for scope refinement
|