Class: JobsCrawler::Robots::AtooJob

Inherits:
Object
  • Object
show all
Defined in:
lib/jobs_crawler/robots/atoo_job.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(url) ⇒ AtooJob



5
6
7
8
# File 'lib/jobs_crawler/robots/atoo_job.rb', line 5

def initialize(url)
  @url    = url
  @engine = Mechanize.new
end

Instance Attribute Details

#urlObject (readonly)

Returns the value of attribute url.



3
4
5
# File 'lib/jobs_crawler/robots/atoo_job.rb', line 3

def url
  @url
end

Instance Method Details

#crawlObject



10
11
12
13
# File 'lib/jobs_crawler/robots/atoo_job.rb', line 10

def crawl
  set_html
  to_json
end