Mercurial > pub > ImplabNet
comparison Implab.Playground/Program.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 |
---|---|
41 public class Program { | 41 public class Program { |
42 | 42 |
43 static void Main(string[] args) { | 43 static void Main(string[] args) { |
44 var container = new UnityContainer(); | 44 var container = new UnityContainer(); |
45 | 45 |
46 var ctx = new ConfigurationContext(container); | |
47 | |
46 var conf = SerializationHelpers.DeserializeFromFile<ContainerElement>("data/sample.xml"); | 48 var conf = SerializationHelpers.DeserializeFromFile<ContainerElement>("data/sample.xml"); |
49 | |
50 ctx.Visit(conf); | |
47 | 51 |
48 Console.WriteLine($"Registrations: {conf.Items.Count}"); | 52 Console.WriteLine($"Registrations: {conf.Items.Count}"); |
49 | 53 |
50 } | 54 } |
51 | 55 |