269
|
1 using System;
|
|
2 using System.Xml.Serialization;
|
|
3 using Unity.Lifetime;
|
|
4 using Unity.Registration;
|
|
5
|
|
6 namespace Implab.ServiceHost.Unity {
|
|
7
|
|
8 [XmlRoot("register", Namespace = Schema.ContainerConfigurationNamespace)]
|
|
9 public class RegisterElement : AbstractRegistration {
|
|
10
|
|
11 /// <summary>
|
271
|
12 /// An optional type which is registered as a service in the container, must be assignable to <see cref="ProvidesType">.
|
269
|
13 /// </summary>
|
|
14 [XmlAttribute("type")]
|
272
|
15 public string ImplementationType { get; set; }
|
269
|
16
|
|
17
|
270
|
18 [XmlElement("constructor", typeof(ConstructorInjectionElement))]
|
|
19 [XmlElement("property", typeof(PropertyInjectionElement))]
|
|
20 [XmlElement("method", typeof(MethodInjectionElement))]
|
|
21 public AbstractInjectionElement[] Injectors { get; set; }
|
272
|
22
|
|
23 public override void Visit(ConfigurationContext context) {
|
|
24 context.Visit(this);
|
|
25 }
|
269
|
26 }
|
|
27
|
|
28 } |