method
initialize_variables
initialize_variables(attrs)
private
Hide source
# File lib/rss/rss.rb, line 651 def initialize_variables(attrs) normalized_attrs = {} attrs.each do |key, value| normalized_attrs[key.to_s] = value end self.class.need_initialize_variables.each do |variable_name| value = normalized_attrs[variable_name.to_s] if value __send__("#{variable_name}=", value) else instance_eval("@#{variable_name} = nil") end end initialize_have_children_elements @content = "" if self.class.have_content? end