Class: WebCrawler::View::Runner::WorkSpace

Inherits:
Object
  • Object
show all
Defined in:
lib/web_crawler/view/runner.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(meth, *args, &block) ⇒ Object



19
20
21
# File 'lib/web_crawler/view/runner.rb', line 19

def method_missing(meth, *args, &block)
  puts "\e[31m\e[1mError: method \"\e[0m\e[31m#{meth}\e[0m\e[31m\e[1m\" is missing\e[0m"
end

Instance Attribute Details

#responsesObject

array of responses



8
9
10
# File 'lib/web_crawler/view/runner.rb', line 8

def responses
  @responses
end

#resultsObject

Returns the value of attribute results.



9
10
11
# File 'lib/web_crawler/view/runner.rb', line 9

def results
  @results
end

Instance Method Details

#qObject



11
12
13
# File 'lib/web_crawler/view/runner.rb', line 11

def q
  exit
end

#returning(value) ⇒ Object



15
16
17
# File 'lib/web_crawler/view/runner.rb', line 15

def returning(value)
  self.results = value  
end