class I18n::Tasks::Scanners::Files::CachingFileFinder
Finds the files in the specified search paths with support for exclusion / inclusion patterns. Wraps a {FileFinder} and caches the results.
@note This class is thread-safe. All methods are cached. @since 0.9.0
Public Class Methods
Source
# File lib/i18n/tasks/scanners/files/caching_file_finder.rb, line 14 def initialize(**args) super @cached_value = ::I18n::Tasks::Concurrent::CachedValue.new { uncached_find_files } end
@param (see FileFinder#initialize)
Calls superclass method
Public Instance Methods
Source
# File lib/i18n/tasks/scanners/files/caching_file_finder.rb, line 31 def find_files @cached_value.get end
@note This method is cached, it will only access the filesystem on the first invocation. @return (see FileFinder#find_files
)
Also aliased as: uncached_find_files
Traverse the paths and yield the matching ones.
@note This method is cached, it will only access the filesystem on the first invocation. @param (see FileFinder#traverse_files
) @yieldparam (see FileFinder#traverse_files
) @return (see FileFinder#traverse_files
)
Alias for: find_files