Ejemplo n.º 1
0
        private IClassInfo Get(Type type)
        {
            if (!_classes.TryGetValue(type, out IClassInfo result))
            {
                result = new MarkUnitClass(_assemblyReader.LoadAssembly(new AssemblyWrapper(type.Assembly)), type);
            }

            return(result);
        }
Ejemplo n.º 2
0
        private void ReadAllAssembliesInDirectory()
        {
            Console.Write("read assemblies: ");
            foreach (var file in Directory.EnumerateFiles(Path).Where(MightBeAssembly))
            {
                try
                {
                    Console.Write(".");
                    _assembliesInDirectory.Add(_assemblyReader.LoadAssembly(file));
                }
                catch (Exception ex)
                {
                    Console.WriteLine("EXCEPTION Try Load " + file);
                    Console.WriteLine(ex.Message);
                }
            }

            Console.WriteLine();
        }