Class: LinkChecker::Task

Inherits:
Object
  • Object
show all
Includes:
Callbacks
Defined in:
lib/ruby-link-checker/task.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Callbacks

#callbacks, #delegates, #method_missing, #on

Constructor Details

#initialize(checker, uri, method, original_uri, options = {}) ⇒ Task

Returns a new instance of Task.



7
8
9
10
11
12
13
14
# File 'lib/ruby-link-checker/task.rb', line 7

def initialize(checker, uri, method, original_uri, options = {})
  @checker = checker
  @logger = checker.logger
  @uri = uri
  @original_uri = original_uri || @uri
  @method = method
  @options = options
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class LinkChecker::Callbacks

Instance Attribute Details

#checkerObject (readonly)

Returns the value of attribute checker.



5
6
7
# File 'lib/ruby-link-checker/task.rb', line 5

def checker
  @checker
end

#loggerObject (readonly)

Returns the value of attribute logger.



5
6
7
# File 'lib/ruby-link-checker/task.rb', line 5

def logger
  @logger
end

#methodObject (readonly)

Returns the value of attribute method.



5
6
7
# File 'lib/ruby-link-checker/task.rb', line 5

def method
  @method
end

#optionsObject (readonly)

Returns the value of attribute options.



5
6
7
# File 'lib/ruby-link-checker/task.rb', line 5

def options
  @options
end

#original_uriObject (readonly)

Returns the value of attribute original_uri.



5
6
7
# File 'lib/ruby-link-checker/task.rb', line 5

def original_uri
  @original_uri
end

#uriObject (readonly)

Returns the value of attribute uri.



5
6
7
# File 'lib/ruby-link-checker/task.rb', line 5

def uri
  @uri
end

Instance Method Details

#run!Object

Raises:

  • (NotImplementedError)


16
17
18
# File 'lib/ruby-link-checker/task.rb', line 16

def run!
  raise NotImplementedError
end