Class: RCrawler::Configuration
- Inherits:
-
Object
- Object
- RCrawler::Configuration
- Includes:
- Singleton
- Defined in:
- lib/rcrawler/configuration.rb
Constant Summary collapse
- VALID_OPTIONS_KEYS =
[ :threads, :timeout, :timeout_proc ].freeze
Instance Method Summary collapse
- #configure {|_self| ... } ⇒ Object
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
- #reset ⇒ Object
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
17 18 19 |
# File 'lib/rcrawler/configuration.rb', line 17 def initialize reset end |
Instance Method Details
#configure {|_self| ... } ⇒ Object
21 22 23 |
# File 'lib/rcrawler/configuration.rb', line 21 def configure yield self end |
#reset ⇒ Object
25 26 27 28 29 |
# File 'lib/rcrawler/configuration.rb', line 25 def reset self.threads = 8 self.timeout = 10 self.timeout_proc = :raise end |