Class: DiffNews::ZwanzigMinunten

Inherits:
Service
  • Object
show all
Defined in:
lib/news_service/20min.rb

Instance Attribute Summary

Attributes inherited from Service

#history

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Service

#base_url, create, #current_revision, #encoding, #normalize_text, #provider, register_service, services, store_class=, #strip_html

Constructor Details

#initialize(url) ⇒ ZwanzigMinunten

Returns a new instance of ZwanzigMinunten.



6
7
8
# File 'lib/news_service/20min.rb', line 6

def initialize url
  super url
end

Class Method Details

.base_urlObject



14
15
16
# File 'lib/news_service/20min.rb', line 14

def self.base_url
  'http://www.20min.ch/'
end

.providerObject



10
11
12
# File 'lib/news_service/20min.rb', line 10

def self.provider
  '20min.ch'
end

.valid_urlObject



18
19
20
# File 'lib/news_service/20min.rb', line 18

def self.valid_url
  /^https?:\/\/(www.)?20min.ch/
end