| Module | RSS::Maker::TaxonomyTopicModel |
| In: |
lib/rss/maker/taxonomy.rb
|
# File lib/rss/maker/taxonomy.rb, line 53
53: def self.append_features(klass)
54: super
55:
56: klass.add_need_initialize_variable("taxo_topics", "make_taxo_topics")
57: klass.add_other_element("taxo_topics")
58: klass.module_eval("attr_reader :taxo_topics\ndef make_taxo_topics\nself.class::TaxonomyTopics.new(@maker)\nend\n\ndef setup_taxo_topics(rss, current)\n@taxo_topics.to_rss(rss, current)\nend\n\ndef taxo_topic\n@taxo_topics[0] and @taxo_topics[0].value\nend\n\ndef taxo_topic=(new_value)\n@taxo_topic[0] = self.class::TaxonomyTopic.new(self)\n@taxo_topic[0].value = new_value\nend\n", __FILE__, __LINE__ + 1)
59: end
# File lib/rss/maker/taxonomy.rb, line 80
80: def self.install_taxo_topic(klass)
81: klass.module_eval("class TaxonomyTopics < TaxonomyTopicsBase\nclass TaxonomyTopic < TaxonomyTopicBase\nDublinCoreModel.install_dublin_core(self)\nTaxonomyTopicsModel.install_taxo_topics(self)\n\ndef to_rss(rss, current)\nif current.respond_to?(:taxo_topics)\ntopic = current.class::TaxonomyTopic.new(value)\ntopic.taxo_link = value\ntaxo_topics.to_rss(rss, topic) if taxo_topics\ncurrent.taxo_topics << topic\nsetup_other_elements(rss)\nend\nend\n\ndef current_element(rss)\nsuper.taxo_topics.last\nend\nend\nend\n", *Utils.get_file_and_line_from_caller(1))
82: end