Esempio n. 1
0
        public DefaultTypeFinder(Assembly seedAssembly, IDataTypeFactory dataTypeFactory)
        {
            var typeFinderConduit = new TypeFinderConduit();

            var typesCache = new CachedTypesFinder(dataTypeFactory);
            ITypeFinder genericTypeFinder = new GenericTypeFinder(typesCache, typeFinderConduit, dataTypeFactory);
            ITypeFinder typeInAssemblyFinder = new TypeInAssemblyFinder(seedAssembly, typesCache, dataTypeFactory);
            ITypeFinder typeInReferencedAssemblyFinder = new TypeInReferencedAssemblyFinder(seedAssembly, typesCache,
                                                                                            typeFinder, dataTypeFactory);

            typeFinder =
                new TypeFinder(typesCache, genericTypeFinder, typeInAssemblyFinder, typeInReferencedAssemblyFinder);

            typeFinderConduit.SetTarget(typeFinder);
        }
Esempio n. 2
0
        public DefaultTypeFinder(Assembly seedAssembly, IDataTypeFactory dataTypeFactory)
        {
            var typeFinderConduit = new TypeFinderConduit();

            var         typesCache                     = new CachedTypesFinder(dataTypeFactory);
            ITypeFinder genericTypeFinder              = new GenericTypeFinder(typesCache, typeFinderConduit, dataTypeFactory);
            ITypeFinder typeInAssemblyFinder           = new TypeInAssemblyFinder(seedAssembly, typesCache, dataTypeFactory);
            ITypeFinder typeInReferencedAssemblyFinder = new TypeInReferencedAssemblyFinder(seedAssembly, typesCache,
                                                                                            typeFinder, dataTypeFactory);

            typeFinder =
                new TypeFinder(typesCache, genericTypeFinder, typeInAssemblyFinder, typeInReferencedAssemblyFinder);

            typeFinderConduit.SetTarget(typeFinder);
        }
Esempio n. 3
0
        public void SetUp()
        {
            var dataTypeFactory = new DataTypeFactory();
            var seedAssembly = GetType().Assembly;

            var typeFinderConduit = new TypeFinderConduit();

            var typesCache = new CachedTypesFinder(dataTypeFactory);
            ITypeFinder genericTypeFindeer = new GenericTypeFinder(typesCache, typeFinderConduit, dataTypeFactory);
            ITypeFinder typeInAssemblyFinder = new TypeInAssemblyFinder(seedAssembly, typesCache, dataTypeFactory);
            ITypeFinder typeInReferencedAssembliesFinder = new TypeInReferencedAssemblyFinder(seedAssembly, typesCache, typeFinder, dataTypeFactory);

            typeFinder = new TypeFinder(typesCache, genericTypeFindeer, typeInAssemblyFinder,
                                        typeInReferencedAssembliesFinder);
            typeFinderConduit.SetTarget(typeFinder);
        }
 protected override void SetUp()
 {
     dataTypeFactory = NewMock<IDataTypeFactory>();
     finder = new CachedTypesFinder(dataTypeFactory);
 }