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.
427 428 429 430 431 432 433 434 435 |
# File 'lib/rss/maker/base.rb', line 427 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.
425 426 427 |
# File 'lib/rss/maker/base.rb', line 425 def encoding @encoding end |
#feed_version ⇒ Object (readonly) Also known as: rss_version
Returns the value of attribute feed_version.
423 424 425 |
# File 'lib/rss/maker/base.rb', line 423 def feed_version @feed_version end |
#standalone ⇒ Object
Returns the value of attribute standalone.
425 426 427 |
# File 'lib/rss/maker/base.rb', line 425 def standalone @standalone end |
#version ⇒ Object
Returns the value of attribute version.
425 426 427 |
# File 'lib/rss/maker/base.rb', line 425 def version @version end |
Class Method Details
.make(*args, &block) ⇒ Object
401 402 403 |
# File 'lib/rss/maker/base.rb', line 401 def make(*args, &block) new(*args).make(&block) end |
Instance Method Details
#make {|_self| ... } ⇒ Object
437 438 439 440 |
# File 'lib/rss/maker/base.rb', line 437 def make yield(self) to_feed end |
#to_feed ⇒ Object
442 443 444 445 446 447 448 449 |
# File 'lib/rss/maker/base.rb', line 442 def to_feed feed = make_feed setup_xml_stylesheets(feed) setup_elements(feed) setup_other_elements(feed) feed.validate feed end |