Closed ChrisMissal closed 11 years ago
Given a custom section, I would like to obtain a set of types for the entire section. The usage should look like this:
dynamic config = new Configuration("myFoos"); IEnumerable<Foo> foos = config.BindAll<Foo>();
and
dynamic config = new Configuration("myFoos"); IEnumerable<Foo> foos = config.BindAll<Foo>((k, v) => new Foo { Key = k, Value = v });
Or something similar.
Created it to work like so:
Configuration config = new Configuration("userSection"); var users = config.BindPairs<User, int, string>(x => x.ID, x => x.Name);
Contrived example, but works for tests.
Given a custom section, I would like to obtain a set of types for the entire section. The usage should look like this:
and
Or something similar.