##// END OF EJS Templates
Working on Unity container xml configuration
Working on Unity container xml configuration

File last commit:

r269:ff581cff7003 v3
r269:ff581cff7003 v3
Show More
Program.cs
48 lines | 922 B | text/x-csharp | CSharpLexer
using System;
using System.Diagnostics;
using Implab.Diagnostics;
using Implab.ServiceHost.Unity;
using Implab.Xml;
using Unity;
using Unity.Injection;
namespace Implab.Playground {
public class Foo {
public class Bar {
}
public int IntValue { get; set; }
public string StringValue { get; set; }
}
public class Container<T> {
public Container() {
}
public Container(T instance) {
Instance = instance;
}
public T Instance { get; set; }
}
public class Program {
static void Main(string[] args) {
var container = new UnityContainer();
var conf = SerializationHelpers.DeserializeFromFile<ContainerElement>("data/sample.xml");
Console.WriteLine($"Registrations: {conf.Registrations.Count}");
}
}
}