Example #1
0
 public static List <ITableMapBuilder> GetTableMapBuilders() =>
 ReflectingRegistrationSource.GetCodebaseTypesAssignableTo <ITableMapBuilder>()
 .Where(t => t.IsClass && !t.IsAbstract && !t.ContainsGenericParameters)
 .Select(t => (ITableMapBuilder)Activator.CreateInstance(t))
 .ToList();
Example #2
0
 public static Dictionary <Type, ITableMap> GetTableMaps() =>
 ReflectingRegistrationSource.GetCodebaseTypesAssignableTo <ITableMap>()
 .Where(t => t.IsClass && !t.IsAbstract && !t.ContainsGenericParameters)
 .Select(t => (ITableMap)Activator.CreateInstance(t))
 .ToDictionary(x => x.ModelType);