class FilterRename::Filters::Replace
Public Class Methods
hint()
click to toggle source
# File lib/filter_rename/filters.rb, line 404 def self.hint; 'Replace the text matching REGEX with REPLACE'; end
params()
click to toggle source
# File lib/filter_rename/filters.rb, line 405 def self.params; 'REGEX,REPLACE'; end
Public Instance Methods
filter(params)
click to toggle source
Calls superclass method
FilterRename::FilterBase#filter
# File lib/filter_rename/filters.rb, line 407 def filter(params) regexp = Regexp.new(params[0], get_config(:ignore_case).to_boolean) super get_string.gsub(regexp, params[1]) end