Class: Atomizer::Collection
- Defined in:
- lib/atomizer/collection.rb
Instance Method Summary collapse
-
#initialize ⇒ Collection
constructor
A new instance of Collection.
- #to_xml(xml) ⇒ Object
Methods inherited from FeedItem
feed_attributes, feed_no_collection_group_tag, feed_no_collection_group_tag!, feed_tag_name
Methods included from Buildable
Constructor Details
#initialize ⇒ Collection
Returns a new instance of Collection.
5 6 7 8 |
# File 'lib/atomizer/collection.rb', line 5 def initialize @accepts = [] @categories = [] end |
Instance Method Details
#to_xml(xml) ⇒ Object
10 11 12 13 14 15 16 17 |
# File 'lib/atomizer/collection.rb', line 10 def to_xml(xml) xml.collection :href => href do xml['atom'].title title if title accepts.each do |accept| xml.accept accept end end end |