Example #1
0
 EngineDisk()
 {
     this.engineConfiguration = EngineConfiguration.Instance;
     this.logRep = FactoryRepositoryLog.GetRepositoryLog();
     maxSentence = engineConfiguration.MaxSentence;
     maxResultList = engineConfiguration.MaxResultList;
     this.indexer = FactoryIndexer.GetIndexer();
 }
Example #2
0
 public PersonDomainService(
     IPersonRepository personRepository,
     IUnitOfWork unitOfWork,
     INotificationHandler <DomainNotification> messageHandler,
     IRepositoryLog <int> repositoryLog,
     ISmartNotification notification
     ) : base(unitOfWork, personRepository, repositoryLog, messageHandler)
 {
     _personRepository = personRepository;
     _notification     = notification;
 }
Example #3
0
        public ReportGenerator(string rootFolderPath, SignalReportProgress signalEvent, SignalReportDone workDone)
        {
            this.rootFolder = rootFolderPath;
            this.ht = new Hashtable();
            this.signalEvent = signalEvent;
            this.signalWorkDone = workDone;

            this.pathReportsFolder = ConfigurationManager.AppSettings["reportFolder"].ToString();
            this.repLog = FactoryRepositoryLog.GetRepositoryLog();
            this.fileSystemHelper = FactoryFileSystemHelper.GetFileSystemHelper();
        }
 public DomainServiceBase(
     TIUnitOfWork unitOfWork,
     IRepository <TEntity, TKey> repository,
     IRepositoryLog <TKey> repositoryLog,
     INotificationHandler <DomainNotification> messageHandler
     ) : base(unitOfWork, messageHandler)
 {
     _unitOfWork    = unitOfWork;
     _repository    = repository;
     _repositoryLog = repositoryLog;
 }
Example #5
0
        protected void Application_Start(object sender, EventArgs e)
        {
            this.eng = FactoryEngine.GetEngine();

            this.repLog = FactoryRepositoryLog.GetRepositoryLog();

            DateTime start;
            TimeSpan timeDif;
            Stopwatch sw;

            string smsTimeToLoad = "Load Engine".PadRight(15);
            string smsSearch = "Search".PadRight(15);
            string smsSearchTwoWords = "Search Two Words".PadRight(15);
            string smsMemoryUsage = "Memory".PadRight(15);


            start = DateTime.Now;
            sw = Stopwatch.StartNew();
            eng.Load();
            sw.Stop();
            timeDif = sw.Elapsed;

            Log entry = new Log();
            entry.TaskDescription = smsTimeToLoad;
            entry.StartDateTime = start;
            entry.ExecutionTime = timeDif;
            entry.LogParameters = new List<string>();
            entry.LogParameters.Add("totalIndexedDocs: " + eng.TotalDocumentQuantity.ToString());
            entry.LogParameters.Add("totalIndexedWords: " + eng.TotalWordQuantity.ToString());
            entry.LogParameters.Add("TypeGUI: WEB");
            repLog.Write(entry);

            //memory monitor
            Process currentProc = Process.GetCurrentProcess();

            long memoryUsed = currentProc.PrivateMemorySize64;

            entry = new Log();
            entry.TaskDescription = smsMemoryUsage;
            entry.StartDateTime = start;
            entry.ExecutionTime = timeDif;
            entry.LogParameters = new List<string>();
            entry.LogParameters.Add("TotalMemory: " + Useful.GetFormatedSizeString(memoryUsed));
            repLog.Write(entry);

        }
Example #6
0
 public RequestIdApiExecutor(RpcClient rpcClient, ILogger <ClientApiExecutor> logger, IRepositoryLog repositoryLog)
 {
     _rpcClient     = rpcClient;
     _logger        = logger;
     _repositoryLog = repositoryLog;
 }
 public FileSystemHelperZetaLongPath()
 {
     this.repLog = FactoryRepositoryLog.GetRepositoryLog();
 }
Example #8
0
        protected void Application_Start()
        {
            AreaRegistration.RegisterAllAreas();

            WebApiConfig.Register(GlobalConfiguration.Configuration);
            FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
            RouteConfig.RegisterRoutes(RouteTable.Routes);

            // Change current culture
            CultureInfo culture = CultureInfo.CreateSpecificCulture("pt-br");
            
            CultureInfo.DefaultThreadCurrentCulture = culture;
            CultureInfo.DefaultThreadCurrentUICulture = culture;

            Thread.CurrentThread.CurrentCulture = culture;
            Thread.CurrentThread.CurrentUICulture = culture;

            
            this.eng = FactoryEngine.GetEngine();

            this.repLog = FactoryRepositoryLog.GetRepositoryLog();

            DateTime start;
            TimeSpan timeDif;
            Stopwatch sw;

            string smsTimeToLoad = "Load Engine".PadRight(15);
            string smsSearch = "Search".PadRight(15);
            string smsSearchTwoWords = "Search Two Words".PadRight(15);
            string smsMemoryUsage = "Memory".PadRight(15);


            start = DateTime.Now;
            sw = Stopwatch.StartNew();
            eng.Load();
            sw.Stop();
            timeDif = sw.Elapsed;

            Log entry = new Log();
            entry.TaskDescription = smsTimeToLoad;
            entry.StartDateTime = start;
            entry.ExecutionTime = timeDif;
            entry.LogParameters = new List<string>();
            entry.LogParameters.Add("totalIndexedDocs: " + eng.TotalDocumentQuantity.ToString());
            entry.LogParameters.Add("totalIndexedWords: " + eng.TotalWordQuantity.ToString());
            entry.LogParameters.Add("TypeGUI: WEB");
            repLog.Write(entry);

            //memory monitor
            Process currentProc = Process.GetCurrentProcess();

            long memoryUsed = currentProc.PrivateMemorySize64;

            entry = new Log();
            entry.TaskDescription = smsMemoryUsage;
            entry.StartDateTime = start;
            entry.ExecutionTime = timeDif;
            entry.LogParameters = new List<string>();
            entry.LogParameters.Add("TotalMemory: " + Useful.GetFormatedSizeString(memoryUsed));
            repLog.Write(entry);
        }
Example #9
0
 public ServiceLog(IRepositoryLog repository)
 {
     _repository = repository;
 }
Example #10
0
 public FileSystemHelperDotNet()
 {
     this.repLog = FactoryRepositoryLog.GetRepositoryLog();
 }
Example #11
0
 public LogController(IMapper mapper, IRepositoryLog repo)
 {
     _mapper = mapper;
     _repo   = repo;
 }
Example #12
0
 public LogController(IRepository rep, IRepositoryLog repLog)
 {
     _rep    = rep;
     _repLog = repLog;
 }