Class: TextExtractor::Directives::Rest

Inherits:
Directive
  • Object
show all
Defined in:
lib/text_extractor/directives/classes.rb

Overview

skip to end of line

Instance Attribute Summary

Attributes inherited from Directive

#state

Instance Method Summary collapse

Methods inherited from Directive

#initialize, #values

Constructor Details

This class inherits a constructor from TextExtractor::Directives::Directive

Instance Method Details

#callObject



92
93
94
95
96
97
98
# File 'lib/text_extractor/directives/classes.rb', line 92

def call
  state.current = if state.newline?
                    [state.current.chomp, '[^\\n]*\n']
                  else
                    [state.current, '[^\\n]*']
                  end
end