lib/parse_structured_files/plain_text.rb
def parse(line, structure: @general_expresion)
      line = line.match(structure)
      raise "Error in the line parse" if line.nil?
      to_fieldset line.names.zip(line.captures)
    end
# Parse a line using the regexp
# @param line [String]
# @param structure [Regexp] store all in 'line' field by default
# @return [Fieldset]
Parse a line using the regexp
Parse a line using the regexp
def parse(line, structure: @general_expresion)
      line = line.match(structure)
      raise "Error in the line parse" if line.nil?
      to_fieldset line.names.zip(line.captures)
    end
def parse ( line , structure : @general_expresion ) line = line . match ( structure ) raise "Error in the line parse" if line . nil? to_fieldset line . names . zip ( line . captures ) end
Parse a line using the regexp
Parse a line using the regexp
None
Fieldset
line
structure
store all in 'line' field by default
store all in ' line ' field by default
None