mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-08-20 12:00:53 +08:00
added interfaces
This commit is contained in:
Vendored
+15
@@ -4,6 +4,21 @@
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
declare module inversify {
|
||||
|
||||
interface TypeBindingInterface<TServiceType> {
|
||||
runtimeIdentifier : string;
|
||||
implementationType : { new(): TServiceType ;};
|
||||
cache : TServiceType;
|
||||
scope : number; // TypeBindingScopeEnum
|
||||
}
|
||||
|
||||
interface KernelInterface {
|
||||
bind(typeBinding : TypeBindingInterface<any>) : void;
|
||||
unbind(runtimeIdentifier : string) : void;
|
||||
unbindAll() : void;
|
||||
resolve<TImplementationType>(runtimeIdentifier : string) : TImplementationType;
|
||||
}
|
||||
|
||||
enum TypeBindingScopeEnum {
|
||||
Transient = 0,
|
||||
Singleton = 1,
|
||||
|
||||
Reference in New Issue
Block a user