Class: FeedAbstract::Items::RDF

Inherits:
Array
  • Object
show all
Defined in:
lib/feed-abstract/items/rdf.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(feed, channel) ⇒ RDF

Returns a new instance of RDF.



8
9
10
11
12
13
14
15
# File 'lib/feed-abstract/items/rdf.rb', line 8

def initialize(feed,channel)
  @feed = feed
  @channel = channel
  return [] if @feed.items.empty?
  @feed.items.each do|item|
    self << ::FeedAbstract::Item::RDF.new(item,channel)
  end
end

Instance Attribute Details

#feedObject (readonly)

Returns the value of attribute feed.



6
7
8
# File 'lib/feed-abstract/items/rdf.rb', line 6

def feed
  @feed
end

#itemsObject (readonly)

Returns the value of attribute items.



6
7
8
# File 'lib/feed-abstract/items/rdf.rb', line 6

def items
  @items
end