/// <summary>
        /// Gets the file Name
        /// </summary>
        /// <returns></returns>
        public string GetFileName()
        {
            var filePath = _pathProvider.Combine(_pathProvider.GetDirectoryPath(), _filePath);
            var fileNameWithExtenstion = _pathProvider.GetFileName(filePath);

            if (!Path.GetExtension(fileNameWithExtenstion).ToLower().Contains(Constants.AllowedFileExtensionsForLogging))
            {
                throw new FormatException(Constants.InvalidFileFormatException);
            }

            if (_frequency == 0)
            {
                return(_pathProvider.Combine(_pathProvider.GetDirectoryPath(), _filePath));
            }

            FormatAndStoreFileNameIfRequired(fileNameWithExtenstion);
            return(_providerFactory.GetPreviousFileName());
        }