Class: Justicecz::Html::ResultLine

Inherits:
Object
  • Object
show all
Defined in:
lib/justicecz/html/result_line.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(result_line) ⇒ ResultLine

Returns a new instance of ResultLine.



4
5
6
7
# File 'lib/justicecz/html/result_line.rb', line 4

def initialize(result_line)
  @result_line = result_line
  @company = ::Justicecz::Entities::Company.new
end

Class Method Details

.line(result_line) ⇒ Object



9
10
11
# File 'lib/justicecz/html/result_line.rb', line 9

def self.line(result_line)
  new(result_line).line
end

Instance Method Details

#lineObject



13
14
15
16
17
# File 'lib/justicecz/html/result_line.rb', line 13

def line
  return nil if headers.empty?
  parse_line
  @company
end