Mercurial > pub > ImplabNet
comparison Implab.ServiceHost/Unity/RegisterElement.cs @ 271:d4d437ec4483 v3
Working on Unity xml configuration
author | cin |
---|---|
date | Wed, 25 Apr 2018 19:23:35 +0300 |
parents | ade80d94dfb5 |
children | 9d1cca834b05 |
comparison
equal
deleted
inserted
replaced
270:ade80d94dfb5 | 271:d4d437ec4483 |
---|---|
7 | 7 |
8 [XmlRoot("register", Namespace = Schema.ContainerConfigurationNamespace)] | 8 [XmlRoot("register", Namespace = Schema.ContainerConfigurationNamespace)] |
9 public class RegisterElement : AbstractRegistration { | 9 public class RegisterElement : AbstractRegistration { |
10 | 10 |
11 /// <summary> | 11 /// <summary> |
12 /// An optional type specification for the service registration, | 12 /// An optional type which is registered as a service in the container, must be assignable to <see cref="ProvidesType">. |
13 /// must be assignable from the type specified by <see cref="ImplementedType"/> | |
14 /// </summary> | |
15 [XmlAttribute("provides")] | |
16 public string ProvidesType { get; set; } | |
17 | |
18 /// <summary> | |
19 /// The type which is registered as a service in the container. | |
20 /// </summary> | 13 /// </summary> |
21 [XmlAttribute("type")] | 14 [XmlAttribute("type")] |
22 public string ImplementedType { get; set; } | 15 public string ImplementedType { get; set; } |
23 | 16 |
24 [XmlElement("signleton", typeof(SimgletonLifetimeElement))] | |
25 [XmlElement("context", typeof(ContextLifetimeElement))] | |
26 [XmlElement("container", typeof(ContainerLifetimeElement))] | |
27 [XmlElement("hierarchy", typeof(HierarchicalLifetimeElement))] | |
28 public LifetimeElement Lifetime {get; set;} | |
29 | 17 |
30 [XmlElement("constructor", typeof(ConstructorInjectionElement))] | 18 [XmlElement("constructor", typeof(ConstructorInjectionElement))] |
31 [XmlElement("property", typeof(PropertyInjectionElement))] | 19 [XmlElement("property", typeof(PropertyInjectionElement))] |
32 [XmlElement("method", typeof(MethodInjectionElement))] | 20 [XmlElement("method", typeof(MethodInjectionElement))] |
33 public AbstractInjectionElement[] Injectors { get; set; } | 21 public AbstractInjectionElement[] Injectors { get; set; } |