Class: Hootenanny::FeedStore::WebFeedStore
- Inherits:
-
Object
- Object
- Hootenanny::FeedStore::WebFeedStore
- Defined in:
- lib/hootenanny/feed_store/web_feed_store.rb
Constant Summary collapse
- CONTENT_TYPE_MAPPINGS =
{ 'application/rss+xml' => 'RSS', 'application/atom+xml' => 'Atom', 'application/json' => 'JSON', }
Instance Method Summary collapse
- #fetch(options = {}) ⇒ Object
-
#initialize(options = {}) ⇒ WebFeedStore
constructor
A new instance of WebFeedStore.
Constructor Details
#initialize(options = {}) ⇒ WebFeedStore
Returns a new instance of WebFeedStore.
13 14 |
# File 'lib/hootenanny/feed_store/web_feed_store.rb', line 13 def initialize( = {}) end |
Instance Method Details
#fetch(options = {}) ⇒ Object
16 17 18 19 20 21 |
# File 'lib/hootenanny/feed_store/web_feed_store.rb', line 16 def fetch( = {}) self.url = .fetch(:url) Hootenanny::Feed.infer(content, type: feed_serialization_type) end |