Class: FeedAbstract::Items::Atom
- Inherits:
-
Array
- Object
- Array
- FeedAbstract::Items::Atom
- Defined in:
- lib/feed-abstract/items/atom.rb
Instance Attribute Summary collapse
-
#feed ⇒ Object
readonly
Returns the value of attribute feed.
-
#items ⇒ Object
readonly
Returns the value of attribute items.
Instance Method Summary collapse
-
#initialize(feed, channel) ⇒ Atom
constructor
A new instance of Atom.
Constructor Details
#initialize(feed, channel) ⇒ Atom
Returns a new instance of Atom.
10 11 12 13 14 15 16 17 |
# File 'lib/feed-abstract/items/atom.rb', line 10 def initialize(feed,channel) @feed = feed @channel = channel return [] if @feed.items.empty? @feed.items.each do|item| self << ::FeedAbstract::Item::Atom.new(item,channel) end end |
Instance Attribute Details
#feed ⇒ Object (readonly)
Returns the value of attribute feed.
8 9 10 |
# File 'lib/feed-abstract/items/atom.rb', line 8 def feed @feed end |
#items ⇒ Object (readonly)
Returns the value of attribute items.
8 9 10 |
# File 'lib/feed-abstract/items/atom.rb', line 8 def items @items end |