lib/csv/ld.rb
##
# Apply the a record to a pattern.
#
# @param [String] pattern
# @return [String] returns the result of substituting each field reference with associated values from record
Apply the a record to a pattern.
Apply the a record to a pattern .
def apply_pattern(pattern, record)
      header_map.each do |fr, i|
        pattern.gsub("{#{fr}}", record[i])
      end
      pattern
    end
def apply_pattern ( pattern , record ) header_map . each do | fr , i | pattern . gsub ( "{#{fr}}" , record [ i ] ) end pattern end
Apply the a record to a pattern.
Apply the a record to a pattern .
returns the result of substituting each field reference with associated values from record
returns the result of substituting each field reference with associated values from record
String
pattern
<not_specific>
record
<not_specific>
<not_specific>
None