SB-6.1-PRE
This commit is contained in:
1 parent
690169a409
commit
358a25f522
3760 files changed
+300059
-36
No files matched your search
+34
@@ -0,0 +1,34 @@
|
||||
import { BindingTypeEnum } from "../constants/literal_types";
|
||||
import { id } from "../utils/id";
|
||||
var Binding = (function () {
|
||||
function Binding(serviceIdentifier, scope) {
|
||||
this.id = id();
|
||||
this.activated = false;
|
||||
this.serviceIdentifier = serviceIdentifier;
|
||||
this.scope = scope;
|
||||
this.type = BindingTypeEnum.Invalid;
|
||||
this.constraint = function (request) { return true; };
|
||||
this.implementationType = null;
|
||||
this.cache = null;
|
||||
this.factory = null;
|
||||
this.provider = null;
|
||||
this.onActivation = null;
|
||||
this.dynamicValue = null;
|
||||
}
|
||||
Binding.prototype.clone = function () {
|
||||
var clone = new Binding(this.serviceIdentifier, this.scope);
|
||||
clone.activated = false;
|
||||
clone.implementationType = this.implementationType;
|
||||
clone.dynamicValue = this.dynamicValue;
|
||||
clone.scope = this.scope;
|
||||
clone.type = this.type;
|
||||
clone.factory = this.factory;
|
||||
clone.provider = this.provider;
|
||||
clone.constraint = this.constraint;
|
||||
clone.onActivation = this.onActivation;
|
||||
clone.cache = this.cache;
|
||||
return clone;
|
||||
};
|
||||
return Binding;
|
||||
}());
|
||||
export { Binding };
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
var BindingCount = {
|
||||
MultipleBindingsAvailable: 2,
|
||||
NoBindingsAvailable: 0,
|
||||
OnlyOneBindingAvailable: 1
|
||||
};
|
||||
export { BindingCount };
|
||||
Reference in new issue
Block a user