Exemple #1
0
        public static void Run(ProgramOptions options)
        {
            foreach (string fileName in options.StatisticsFileNames)
            {
                new Statistics().Run(fileName);
            }

            if (options.InstallPerformanceCounters)
            {
                Db4oPerformanceCounters.ReInstall();
            }

            if (options.CheckDatabase)
            {
                Console.Write("\r\nChecking '{0}' : ", options.Target);
                ConsistencyChecker.Main(new string[] { options.Target });
            }

            if (options.ShowFileUsageStats)
            {
                FileUsageStatsCollector.Main(new string[] { options.Target, "true" });
            }

            if (NoInstrumentationStep(options))
            {
                return;
            }

            using (new CurrentDirectoryAssemblyResolver())
            {
                RunPipeline(options);
            }
        }
Exemple #2
0
        public static void ReInstall()
        {
            if (_installed)
            {
                return;
            }

            if (IsCurrentUserAnAdministrator())
            {
                Db4oPerformanceCounters.ReInstall();
                _installed = true;
            }
        }