Class: RSS::Maker::RSSBase
- Includes:
- TaxonomyTopicModel
- Defined in:
- lib/rss/maker/base.rb,
lib/rss/maker/taxonomy.rb
Direct Known Subclasses
Constant Summary
Constants inherited from Base
Base::NEED_INITIALIZE_VARIABLES, Base::OTHER_ELEMENTS
Instance Attribute Summary collapse
-
#encoding ⇒ Object
Returns the value of attribute encoding.
-
#feed_version ⇒ Object
(also: #rss_version)
readonly
Returns the value of attribute feed_version.
-
#standalone ⇒ Object
Returns the value of attribute standalone.
-
#version ⇒ Object
Returns the value of attribute version.
Attributes inherited from Base
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(feed_version) ⇒ RSSBase
constructor
A new instance of RSSBase.
- #make {|_self| ... } ⇒ Object
- #to_feed ⇒ Object
Methods included from TaxonomyTopicModel
append_features, install_taxo_topic
Methods inherited from Base
add_need_initialize_variable, add_other_element, def_array_element, def_classed_element, def_classed_element_without_accessor, def_classed_elements, def_csv_element, def_other_element, def_other_element_without_accessor, #have_required_values?, inherited, inherited_base, need_initialize_variables, other_elements, #variable_is_set?
Methods included from Utils::InheritedReader
#inherited_array_reader, #inherited_hash_reader, #inherited_reader
Constructor Details
#initialize(feed_version) ⇒ RSSBase
Returns a new instance of RSSBase.
428 429 430 431 432 433 434 435 436 |
# File 'lib/rss/maker/base.rb', line 428 def initialize(feed_version) super(self) @feed_type = nil @feed_subtype = nil @feed_version = feed_version @version = "1.0" @encoding = "UTF-8" @standalone = nil end |
Instance Attribute Details
#encoding ⇒ Object
Returns the value of attribute encoding.
426 427 428 |
# File 'lib/rss/maker/base.rb', line 426 def encoding @encoding end |
#feed_version ⇒ Object (readonly) Also known as: rss_version
Returns the value of attribute feed_version.
424 425 426 |
# File 'lib/rss/maker/base.rb', line 424 def feed_version @feed_version end |
#standalone ⇒ Object
Returns the value of attribute standalone.
426 427 428 |
# File 'lib/rss/maker/base.rb', line 426 def standalone @standalone end |
#version ⇒ Object
Returns the value of attribute version.
426 427 428 |
# File 'lib/rss/maker/base.rb', line 426 def version @version end |
Class Method Details
.make(*args, &block) ⇒ Object
402 403 404 |
# File 'lib/rss/maker/base.rb', line 402 def make(*args, &block) new(*args).make(&block) end |
Instance Method Details
#make {|_self| ... } ⇒ Object
438 439 440 441 |
# File 'lib/rss/maker/base.rb', line 438 def make yield(self) to_feed end |
#to_feed ⇒ Object
443 444 445 446 447 448 449 450 |
# File 'lib/rss/maker/base.rb', line 443 def to_feed feed = make_feed setup_xml_stylesheets(feed) setup_elements(feed) setup_other_elements(feed) feed.validate feed end |