internal Component(Type type, ILiftTimeScope liftTimeScope, string name, IBindingTarget bingingTarget ) { this.target = type; this.name = name; this.bingingTarget = bingingTarget; this.liftTimeScope = liftTimeScope; }
public Component CreateComponent(Multimap <Type, Component> dependents) { if (liftTimeScope == null) { liftTimeScope = new TransientScope(); } InjectProperty[] propertyarray = propertys.ToArray(); InjectMethod[] methodsarray = methods.ToArray(); var component = new Component(target, liftTimeScope, name, new BindingTarget(source, propertyarray, methodsarray)); foreach (Type type in injects) { dependents.Add(type, component); } return(component); }
public void Singleton() { liftTimeScope = new SingletonScope(); }