public void Initialize(bool useLogging = true, string folderPath = null, string fileNameFormat = null) { if (useLogging) { _logger = Logger.Create(nameof(DataCollector)); Logger.UpdateFilePath(folderPath ?? $"{AppDomain.CurrentDomain.BaseDirectory}/{TextConstants.LogDefaultFolder}", fileNameFormat ?? TextConstants.LogFormatFileName); _isLogging = true; } _logger?.Info("Initialize timer..."); _dataQueue.InitializeTimer(); }